Skip to main content

Automatic Registration Estimation Based on ArUco Markers

PyPI - Python Version PyPI GitHub Workflow Status license

About

This project automatically computes the correct scale and registration of 3D reconstructions generated with COLMAP by placing one or more ArUco markers in the scene. This module does not perform the reconstruction task itself so a colmap installation isn't needed.

Installation

This repository is tested on Python 3.6+ and can be installed from PyPI:

pip install aruco-estimator

Note: The PyPI release is currently out of date and broken as of 2025-03-22. For the latest stable version, install directly from source:

pip install git+https://github.com/meyerls/aruco-estimator

Usage

Test Data

Download and extract the test dataset:

wget -O door.zip "https://faubox.rrze.uni-erlangen.de/dl/fiUNWMmsaEAavXHfjqxfyXU9/door.zip"
unzip door.zip

Registration

Test the registration functionality with the example project:

aruco-estimator register ./door --target-id 7 --dict-type 4 --show --aruco-size 0.15

Scripting

from aruco_estimator.sfm.colmap import COLMAPProject
from aruco_estimator.utils import get_normalization_transform
import cv2
project = COLMAPProject('./door')

target_id = 7
aruco_size = .15
aruco_results = project.detect_markers(dict_type=cv2.aruco.DICT_4X4_50)

# Get 3D corners for normalization
target_corners_3d = aruco_results[target_id]
print(target_corners_3d) 

# Calculate 4x4 transform with scaling so tag is at the origin 
transform = get_normalization_transform(target_corners_3d, aruco_size)

# Apply normalization to the project
print("Normalizing poses and 3D points...")
project.transform(transform)
project.save("./transformed_output/")

print(f"Target ArUco ID: {target_id}")

Known Limitations

  • Dense cloud visualization and modification is currently broken
  • Only SIMPLE_RADIAL and PINHOLE camera models are supported
  • Aruco boards are not uniquely supported
  • Pose estimation is not robust to false detections; ransac would be beneficial
  • Only COLMAP .bin and .txt models are supported

Roadmap

  • Update README with multi tag examples
  • Improved pose estimation robustness
  • Implement the merge by tag tool
  • Support for additional camera models
  • Dense cloud visualization fixes
  • Geo-referencing of ArUco markers with Earth coordinate system using GPS or RT

Troubleshooting

OpenCV ArUco Module Issues

If cv2 doesn't detect the ArUco marker module, try reinstalling OpenCV:

pip uninstall opencv-python opencv-python-headless
pip install opencv-python opencv-contrib-python

Acknowledgements

References

[1] Erich, F., Bourreau, B., Neural Scanning: Rendering and determining geometry of household objects using Neural Radiance Fields. Link. 2022

Citation

If this work helps with your research, please cite:

@inproceedings{meyer2023cherrypicker,
  title={CherryPicker: Semantic skeletonization and topological reconstruction of cherry trees},
  author={Meyer, Lukas and Gilson, Andreas and Scholz, Oliver and Stamminger, Marc},
  booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  pages={6244--6253},
  year={2023}
}

Release files for aruco-estimator 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aruco-estimator 1.2.0
File Size Uploaded
aruco_estimator-1.2.0.tar.gz 13.3 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for aruco-estimator 1.2.0
File Interpreter ABI Platform
aruco_estimator-1.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 13.3 MB

Release files / aruco_estimator-1.2.0.tar.gz

Download URL aruco_estimator-1.2.0.tar.gz
Size 13.3 MB
Tags Source
SHA-256 checksum
How to use checksums
7f25ed05442c1c9c7024e8f7da8d8013e392c86270f177d67c39d93cd139397e
BLAKE2b-256 checksum
How to use checksums
42c0587887383aff6fc423d05f46550d960b17ab2eed132f16f9ebeca02dfb75
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.9

Release files / aruco_estimator-1.2.0-py3-none-any.whl

Download URL aruco_estimator-1.2.0-py3-none-any.whl
Size 29.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
60703446f142542c11d9c18163c91a3aec96e920c15db7e4e8ea73e3e828ddc0
BLAKE2b-256 checksum
How to use checksums
7b0b0f5425313afc8e0bb39c6af9075498d4cd5edee4dd0d33a27675d9f7527a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.9

Release history Release notifications | RSS feed

This release

1.2.0 This release

2 release files

1.1.10

2 release files

1.1.8

2 release files

1.1.7

2 release files

1.1.6

2 release files

1.1.5

2 release files

1.1.4

2 release files

1.1.3

2 release files

1.1.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page