Skip to main content

Python geodetic coordinate conversions written in rust

Project description

rustmap3d

License Python PyPI Ruff

Simple, fast, and ergonomic geodetic coordinate conversions


Installation

# add to an existing project
uv add rustmap3d
# pip install it directly
uv pip install rustmap3d

# pip install without uv
pip install rustmap3d

Examples

import rustmap3d


# wgs84 geodetic conversions
lla = rustmap3d.ecef2lla(x, y, z)
ecef = rustmap3d.lla2ecef(lat, lon, alt)
...

# local conversions
ecef_uvw = rustmap3d.enu2ecef_uvw(e, n, u, lat_ref, lon_ref)
ecef = rustmap3d.enu2ecef(e, n, u, lat_ref, lon_ref)
ecef_uvw = rustmap3d.ned2ecef_uvw(n, e, d, lat_ref, lon_ref)
ecef = rustmap3d.ned2ecef(n, e, d, lat_ref, lon_ref)
# enu, ned, aer
...  

# local rotations
enu_quat = rustmap3d.enu2ecef_quat(lat, lon)
enu_dcm = rustmap3d.enu2ecef_dcm(lat, lon) 
# enu, ned

# Conversions
dd = rustmap3d.dms2dd("25:22:44.738N")  #> 25.37909389
dms = rustmap3d.dd2dms(25.37909389, is_lat=true) #> "25:22:44.738N"
lat, lon = rustmap3d.ll2dms(25.37909389, -138.7895679)  #> "25:22:44.738N", "138:47:22.444W"
...  

# distance functions
lat, lon = rustmap3d.vincenty_direct(lat_deg, lon_deg, range_m, bearing_deg)
range_m, bearing_ab, bearing_ba = rustmap3d.vincenty_inverse(lat_a, lon_a, lat_b, lon_b)

Comparison with similar packages

  • 🚀🚀 Blazingly fast - written in rust (see benchmarks)
  • Zero dependencies
  • Dead simple api modeled after pymap3d and matlab
  • Exposes rotations (both quaternions and 3x3 matrices)

Benchmarks

Compared to pymap3d

Note: This is comparing single calls of python floats, not vectorized numpy performance. Vectorized batched conversions will be implemented in the future

  • ~50x faster for lla2ecef
  • ~400x faster for ecef2lla

# Run benchmarks
uv run pytest --benchmark-histogram="./docs/benchmarks" bench/

Build From Source

Uses standard maturin build process

uv run maturin build -r   # build a whl
uv run maturin dev -r     # build a dev package similar to -e

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

rustmap3d-0.2.3-cp314-cp314-win_amd64.whl (782.6 kB view details)

Uploaded CPython 3.14Windows x86-64

rustmap3d-0.2.3-cp314-cp314-manylinux_2_35_x86_64.whl (307.7 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.35+ x86-64

rustmap3d-0.2.3-cp314-cp314-manylinux_2_35_aarch64.whl (285.3 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.35+ ARM64

rustmap3d-0.2.3-cp314-cp314-manylinux_2_31_x86_64.whl (307.8 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.31+ x86-64

rustmap3d-0.2.3-cp314-cp314-macosx_11_0_arm64.whl (266.9 kB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

rustmap3d-0.2.3-cp313-cp313-win_amd64.whl (783.1 kB view details)

Uploaded CPython 3.13Windows x86-64

rustmap3d-0.2.3-cp313-cp313-manylinux_2_35_x86_64.whl (307.9 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.35+ x86-64

rustmap3d-0.2.3-cp313-cp313-manylinux_2_35_aarch64.whl (285.3 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.35+ ARM64

rustmap3d-0.2.3-cp313-cp313-manylinux_2_31_x86_64.whl (308.0 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.31+ x86-64

rustmap3d-0.2.3-cp313-cp313-macosx_11_0_arm64.whl (267.3 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

rustmap3d-0.2.3-cp312-cp312-win_amd64.whl (784.2 kB view details)

Uploaded CPython 3.12Windows x86-64

rustmap3d-0.2.3-cp312-cp312-manylinux_2_35_x86_64.whl (308.0 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.35+ x86-64

rustmap3d-0.2.3-cp312-cp312-manylinux_2_35_aarch64.whl (285.4 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.35+ ARM64

rustmap3d-0.2.3-cp312-cp312-manylinux_2_31_x86_64.whl (308.0 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.31+ x86-64

rustmap3d-0.2.3-cp312-cp312-macosx_11_0_arm64.whl (267.5 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

rustmap3d-0.2.3-cp311-cp311-win_amd64.whl (786.6 kB view details)

Uploaded CPython 3.11Windows x86-64

rustmap3d-0.2.3-cp311-cp311-manylinux_2_35_x86_64.whl (309.9 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.35+ x86-64

rustmap3d-0.2.3-cp311-cp311-manylinux_2_35_aarch64.whl (287.5 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.35+ ARM64

rustmap3d-0.2.3-cp311-cp311-manylinux_2_31_x86_64.whl (310.1 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.31+ x86-64

rustmap3d-0.2.3-cp311-cp311-macosx_11_0_arm64.whl (269.5 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

rustmap3d-0.2.3-cp310-cp310-win_amd64.whl (786.4 kB view details)

Uploaded CPython 3.10Windows x86-64

rustmap3d-0.2.3-cp310-cp310-manylinux_2_35_x86_64.whl (309.8 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.35+ x86-64

rustmap3d-0.2.3-cp310-cp310-manylinux_2_35_aarch64.whl (287.3 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.35+ ARM64

rustmap3d-0.2.3-cp310-cp310-macosx_11_0_arm64.whl (269.4 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file rustmap3d-0.2.3-cp314-cp314-win_amd64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 a9f9a44b0bb80e18f1a78bd9eb0fa01867fa6b966799379f119efb05806a41d7
MD5 2bef941e3fde747444dc23d51c6b4546
BLAKE2b-256 78a0db9ef6204c171f8fbf51d261811af9ed4c30f8a2d083acef35df272dafd5

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp314-cp314-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp314-cp314-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 f10d3dc9c6565076e44684b5b9f79b940e73f7172500f8453f1f09f58a1824e9
MD5 f8bf0c5762e035b26daac4f5022874a1
BLAKE2b-256 9d87acb63ca71bc957106942e947e0bbee3f64f369c13db87e0783dd5a2c68c0

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp314-cp314-manylinux_2_35_aarch64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp314-cp314-manylinux_2_35_aarch64.whl
Algorithm Hash digest
SHA256 bc0c47d6ac0abb8c4ca569c4bb1e5f7a284532f59346e133eb827a86b1044916
MD5 0239bc336ec2f854520f17c21b4a7c2c
BLAKE2b-256 cbfc0db8f4fa16bc4ebdc269e36a93df4e1307266c62b58253aebc5233c5e75e

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp314-cp314-manylinux_2_31_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp314-cp314-manylinux_2_31_x86_64.whl
Algorithm Hash digest
SHA256 5d9e56f13a7a98aa000cd7d333020897b3785936bcd0edbdaa421398416602f7
MD5 f36b06104adc98fb0e3eafa387655cff
BLAKE2b-256 5ee3f6c143d9eed324169a3b670568f1cedb3c01011e0da73f554e675e4edee4

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 935d17dbb3a70506859762b0ab6c18cb1fca92f37468c0ea6152aacb23a2d899
MD5 b97975e1d1051638981e5c3657834237
BLAKE2b-256 64fc13db6fe9d89b138e4f3b42d41beda4353e03fd7126a0783d7c7396a046a5

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 8bfd88a1afc33d8ad210d62f519ce32054851d9fa7586b69f727e42510e7dbb0
MD5 6aa259a0665c9d5d4223ec9b84273421
BLAKE2b-256 d7bf9aa54ae93184a45bde538923242bea5d2f57d2934bc0d9418bea8a623ba3

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp313-cp313-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp313-cp313-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 ed0f8790c8c15c47f15e41e0068bc813cbf6f7284eb26c05dfc99f407666bf1b
MD5 965a0ac6ec161b381f40f6a885c8a97b
BLAKE2b-256 6d2a80c29430bdd76a19e2fd5242119d67696fcb08a2b25a84dbe0d5f9c32499

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp313-cp313-manylinux_2_35_aarch64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp313-cp313-manylinux_2_35_aarch64.whl
Algorithm Hash digest
SHA256 5dfcd402f108cb755d9453a2702604d608f5e247ca14dd6668385d44a45a9b84
MD5 0049c1f97fd03ed20b74bf9d64db9d8a
BLAKE2b-256 1db22eb08b3a03a201526f3254156a307093f8b358344d097d0c66dec9b36221

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp313-cp313-manylinux_2_31_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp313-cp313-manylinux_2_31_x86_64.whl
Algorithm Hash digest
SHA256 e87d2d3077e414ca816094d76647075d76f759ebe9cbe28a54cfdedabc5c3224
MD5 931721133601e0d1f159371482db05bf
BLAKE2b-256 abb33ac69ddc1c3a00ed5a538bccc972049f5007075f051664e5c8a848f66bf8

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f71686fe6ed6c036f0c59e8988009845d5475aea38601945d85476e1f97ce1b5
MD5 c277a206364e838c424fc4ae359964e7
BLAKE2b-256 0456fdf16f9a27521657712c1d4019bfe84af67242fd8681bbe7e41de5dd6db7

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 b25fb39263e130b5bc5ff893a8f2e62f5c71cd78fac59d407bf3a53ffd2bf22e
MD5 96d3f5d53cf06a6291f4a6a96ad80ef4
BLAKE2b-256 6c48eb1279efcf066fa8e77fae64873a649c8ea113b66a6a1ea36eff5411d32d

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp312-cp312-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp312-cp312-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 7500323204ec254e5a6d32555e03697f954e1855f5eb3d52b7697bef1dcad63b
MD5 51353089be6061138e0cfa9818d1fdaf
BLAKE2b-256 30a0deb75e6ccfc26e1772f46e37261741967e3ee90d5b4b2c75e493a89a5b1c

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp312-cp312-manylinux_2_35_aarch64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp312-cp312-manylinux_2_35_aarch64.whl
Algorithm Hash digest
SHA256 259a98ecc36c7038ee982ac46b17e8f13414ede76cd875beb62f444bbac87180
MD5 81cda9676e66dda6ad2d3c49deff9404
BLAKE2b-256 fa8c8ac3719a32b93806232535326df7c92304567e4ae2a0a3dd5781e101e5a4

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp312-cp312-manylinux_2_31_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp312-cp312-manylinux_2_31_x86_64.whl
Algorithm Hash digest
SHA256 a56f04010fca2800c131bb800f47f87774ee74146ba93946de55710d7a6f05ae
MD5 bd13c4be3309ba241236037d63ffc9be
BLAKE2b-256 5a4c4a8ab7d49d942598dc5db833f00f0f4ff1e8e48b9a5c4e48beb845033dc0

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 de7fae2c4d5f13f7b0bde5aa04859e0652cb52e5142a471022cb169bd1eea11f
MD5 f184ba533c038190bda57eef321af73e
BLAKE2b-256 0cc0d79eb1ec22221f9ceff58c667a6a1437383a4f378ae5ad6f3440c67aee60

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 3633c970be67b727c250b1f4a506b00c0c5e5271344de7fcac56dfa039d2d8ee
MD5 ede0dd5bfb975f24ee70d7c80ee01ccd
BLAKE2b-256 9e8fc5bd095df80b4c60db2c717482c7724e4148a098fed778b427018e2c285a

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp311-cp311-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp311-cp311-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 9fb74f5625562042872173bc35ed501d5ce609936276c3932aecb8122d678aae
MD5 eb9424a5607667dae47eef4753ab5bf1
BLAKE2b-256 1ad66c0de10a651ba71d1bb8ec709c777cd3c6e175d93679a060bc8d19595fdc

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp311-cp311-manylinux_2_35_aarch64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp311-cp311-manylinux_2_35_aarch64.whl
Algorithm Hash digest
SHA256 05afb818e2c11f23a47c2473d4355246689b6b0704936b5082034cb26754764f
MD5 4050ac25c33b46a252c5c6421cd1c61b
BLAKE2b-256 2ea616764e18b3f287980dac7ac4f344f17fc8bbca3419deaf5d29ecbd536f1b

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp311-cp311-manylinux_2_31_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp311-cp311-manylinux_2_31_x86_64.whl
Algorithm Hash digest
SHA256 30efba9e24f6b0324a9abec2e7be3c4305b4d7e98509e5c3b484925582c2733e
MD5 bf4abb3cb1b89f5b17dd11b2fb2f3be9
BLAKE2b-256 c615d0e0ce0921078c672ea677fa86b65b87f74d11da0edde3311f5239ce4c3f

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 8ef92a6a04294cbfbea14daa8a2b9cbc8f89d83916dbe3d56637e8e640dce6fa
MD5 5298161eb2b1ffd7200e55c10bb64c28
BLAKE2b-256 9bef8fe7f1b1822929bfba5e65c00564f746a174e2badac4e65c0a61df543fdc

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 dda0abbf512bc0572aa83b8a95b9d9c512b0b19aad887855e3b919ad207d998f
MD5 05be717b2d11f1f679cfd794e65b5d0b
BLAKE2b-256 df4d9ae39337d68c61928304fa5dbc8a5182378ae5ef2eb4e90b8f0ae7310ff3

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp310-cp310-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp310-cp310-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 6d8739dd36bd37354ef8818a12075c99b69022df4d494d85fa8714538371d3df
MD5 841e7c8630474ab604739569864d31be
BLAKE2b-256 4543a9911836ac3641ab8819dca7505737970e6e8be75cbb30238963a3da0a25

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp310-cp310-manylinux_2_35_aarch64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp310-cp310-manylinux_2_35_aarch64.whl
Algorithm Hash digest
SHA256 07c7544948194ea1eadea3cfcf26628091fbafe831932d9bafb47b5e13aef68e
MD5 4ce4fc580d4eaf15d02e10797a07b3a7
BLAKE2b-256 1007c2afa28729724ce7d8343dd8d4e2701ec472d5a719480ea3b19e6bc4cf38

See more details on using hashes here.

File details

Details for the file rustmap3d-0.2.3-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rustmap3d-0.2.3-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 18ff6da5929cb211b6660416366513ffc5b6839ab7e91d952d841fd02e7e75b3
MD5 da26864739371dfecd00ff2d1a4e46fc
BLAKE2b-256 915e9eb1225bee78d4a03f0652886382ae04b2e39f46a924c82c1984cf8cc767

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page