pymavlog
A lightweight python library to parse log files from ArduPilot vehicles based on the MavLink protocol. It is built on top of pymavlink and uses NumPy under the hood to vectorize messages.
Installation
Installation with pip:
pip install pymavlog
or via Poetry
poetry add pymavlog
Development
Install the package in editable mode:
pip install -e .
Pymavlog is built using Poetry, so make sure to have it in your local development environment
pip install poetry
Lastly, install the pre-commit hooks
pip install pre-commit
pre-commit install
Testing
poetry run pytest tests --cov pymavlog
or
make tests
Usage
Mavlink log files are parsed using MavLog, which iterates through the logged messages and saves them in-memory as NumPy arrays. You can parse a file like:
from pymavlog import MavLog
filepath = "foo/bar.bin"
mavlog = MavLog("foo/bar.bin")
mavlog.parse()
and access the messages like:
imu_messages = mavlog.get("IMU")
and do some calculations, for example calculating the average value:
avg_gyr_x = imu_messages["GyrX"].mean()
alternatively, you can access a specific attribute like:
gyr_y = mavlog["IMU"]["Gyrx"]
Pymavlog also supports telemetry log files. You can read a tlog file .tlog in a similar way as binary log files, like:
from pymavlog import MavTLog
filepath = "foo/bar.tlog"
tlog = MavTLog("foo/bar.tlog")
tlog.parse()
Metadata
Release files for pymavlog 0.4.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pymavlog-0.4.2.tar.gz | 5.2 kB | Without provenance | Details for pymavlog-0.4.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pymavlog-0.4.2-py3-none-any.whl | Python 3 | none | any | Details for pymavlog-0.4.2-py3-none-any.whl |
Total release size: 11.2 kB
Release files / pymavlog-0.4.2.tar.gz
| Download URL | pymavlog-0.4.2.tar.gz |
|---|---|
| Size | 5.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
afff4e3642ab814f462cdcd05de08eb4c472c2b61d9c0dfab040b2b0141cc25a
|
|
BLAKE2b-256 checksum How to use checksums |
2a1261b15d91be42e30103623c0ec9ccb34dc9a368d0ae2afff50d50c0d0ac0e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.9.6 readme-renderer/42.0 requests/2.31.0 requests-toolbelt/1.0.0 urllib3/2.0.4 tqdm/4.66.1 importlib-metadata/6.8.0 keyring/24.2.0 rfc3986/2.0.0 colorama/0.4.6 CPython/3.8.18
|
Release files / pymavlog-0.4.2-py3-none-any.whl
| Download URL | pymavlog-0.4.2-py3-none-any.whl |
|---|---|
| Size | 6.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7311de0ec7f8cc5ac670a4e9fce8fca3a52719fe8b476282fa5f8d7f41f2c426
|
|
BLAKE2b-256 checksum How to use checksums |
13603cd6d946842d0c0da0913715bf86f3503a2011f11e8893ceda9b90fc2324
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.9.6 readme-renderer/42.0 requests/2.31.0 requests-toolbelt/1.0.0 urllib3/2.0.4 tqdm/4.66.1 importlib-metadata/6.8.0 keyring/24.2.0 rfc3986/2.0.0 colorama/0.4.6 CPython/3.8.18
|
Security for pymavlog 0.4.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.