A Python library to parse Valetudo map data returning a PIL Image object.
Project description
Python-package-valetudo-map-parser
What is it:
❗This is an unofficial project and is not created, maintained, or in any sense linked to valetudo.cloud
A Python library that converts Valetudo vacuum JSON map data into PIL (Python Imaging Library) images. This package is primarily developed for and used in the MQTT Vacuum Camera project.
Features:
- Processes map data from Valetudo-compatible robot vacuums
- Supports both Hypfer and Rand256 vacuum data formats
- Renders comprehensive map visualizations including:
- Walls and obstacles
- Robot position and cleaning path
- Room segments and boundaries
- Cleaning zones
- Virtual restrictions
- LiDAR data
- Mop mode path rendering (Hypfer only)
- Provides auto-cropping and dynamic zooming
- Supports image rotation and aspect ratio management
- Enables custom color schemes
- Handles multilingual labels
- Implements thread-safe data sharing
Installation:
pip install valetudo_map_parser
Requirements:
- Python 3.13 or higher
- Dependencies:
- Pillow (PIL) for image processing
- NumPy for array operations
- MvcRender Specific C implementation of drawings
Usage:
The library is configured using a dictionary format. See our sample code for implementation examples.
Key functionalities:
- Decodes raw data from Rand256 format
- Processes JSON data from compatible vacuums
- Returns Pillow PNG images
- Provides calibration and room property extraction
- Supports asynchronous operations
Development Status:
Current version: 0.2.4b3
- Full functionality available in versions >= 0.2.0
- Actively maintained and enhanced
- Uses Poetry for dependency management
- Implements comprehensive testing
- Enforces code quality through ruff, isort, and pylint (10.00/10)
Recent Updates (v0.2.4):
- Fixed Critical Calibration Bug: Calibration points now correctly update when map rotation changes
- Fixed Rotation Change Handling: Prevents errors when changing rotation with saved floor data
- Multi-Floor Support: Enhanced floor data management with add/update/remove methods
- Mop Path Customization: Configurable mop path width, color, and transparency (Hypfer vacuums)
- Dock State Display: Shows dock operations (e.g., "mop cleaning") in status text
- Improved Compatibility: Python 3.12+ support for Home Assistant integration
- Performance: Optimized image generation (~450ms average)
- Code Quality: Refactored for better maintainability and reduced complexity
Contributing:
Contributions are welcome! You can help by:
- Submitting code improvements
- Enhancing documentation
- Reporting issues
- Suggesting new features
Disclaimer:
This project is provided "as is" without warranty of any kind. Users assume all risks associated with its use.
License:
Apache-2.0
For more information about Valetudo, visit valetudo.cloud Integration with Home Assistant: MQTT Vacuum Camera
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file valetudo_map_parser-0.2.4b5.tar.gz.
File metadata
- Download URL: valetudo_map_parser-0.2.4b5.tar.gz
- Upload date:
- Size: 22.9 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0f91e5d8b804592259d26f97dbe0ecff5171cbc6ad27bcfc1ffe6d68890e97c9
|
|
| MD5 |
764418e59fc55a6450bda154cf78735f
|
|
| BLAKE2b-256 |
0f40fc8a8b19ac612ef0232310988012f9a43c53cd265f68478605060d2d255d
|
Provenance
The following attestation bundles were made for valetudo_map_parser-0.2.4b5.tar.gz:
Publisher:
release.yaml on sca075/Python-package-valetudo-map-parser
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
valetudo_map_parser-0.2.4b5.tar.gz -
Subject digest:
0f91e5d8b804592259d26f97dbe0ecff5171cbc6ad27bcfc1ffe6d68890e97c9 - Sigstore transparency entry: 928394481
- Sigstore integration time:
-
Permalink:
sca075/Python-package-valetudo-map-parser@9e364a6ead334703b2293e85b9487cce06839562 -
Branch / Tag:
refs/tags/v0.2.4b5 - Owner: https://github.com/sca075
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yaml@9e364a6ead334703b2293e85b9487cce06839562 -
Trigger Event:
release
-
Statement type:
File details
Details for the file valetudo_map_parser-0.2.4b5-py3-none-any.whl.
File metadata
- Download URL: valetudo_map_parser-0.2.4b5-py3-none-any.whl
- Upload date:
- Size: 23.0 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8b3cfcba180e232683f0cf2f2cd14402331883e6c3c835333086e24a815105c5
|
|
| MD5 |
396fd27add48cfb451c8ddde45f47949
|
|
| BLAKE2b-256 |
5c4587244f307fea0c243393d22ead5f0e0a4bd327b34e76b652c45ec619dee6
|
Provenance
The following attestation bundles were made for valetudo_map_parser-0.2.4b5-py3-none-any.whl:
Publisher:
release.yaml on sca075/Python-package-valetudo-map-parser
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
valetudo_map_parser-0.2.4b5-py3-none-any.whl -
Subject digest:
8b3cfcba180e232683f0cf2f2cd14402331883e6c3c835333086e24a815105c5 - Sigstore transparency entry: 928394482
- Sigstore integration time:
-
Permalink:
sca075/Python-package-valetudo-map-parser@9e364a6ead334703b2293e85b9487cce06839562 -
Branch / Tag:
refs/tags/v0.2.4b5 - Owner: https://github.com/sca075
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yaml@9e364a6ead334703b2293e85b9487cce06839562 -
Trigger Event:
release
-
Statement type: