Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

CircleCI Sonarcloud Status Sonarcloud Status Sonarcloud Status Sonarcloud Status Sonarcloud Status Sonarcloud Status Sonarcloud Status

Navigation

This module provides units of measurement and associated functions required for navigating.

Applications

There are many use-cases for this module including the original reason for developing it - Search and Rescue. It's also useful if you are developing a GPS application, or anything that needs to work with Latitude, Longitude, Routes and Waypoints.

Units

The following navigation units are provided:

  • Speed

  • Distance

  • Time

  • CompassBearing

  • Coordinate (Latitude/Longitude)

  • Waypoint

  • Leg

  • Route

Install

$pip install pynavigation

Example

from pynavigation.units import Speed
from pynavigation.units import Distance
from pynavigation.units import SpeedDistanceTime
from pynavigation.units import CompassBearing
from pynavigation.units import Coordinate
from pynavigation.units import Waypoint

# Basic Units
speed = Speed(10)
distance = Distance(100)
sdt = SpeedDistanceTime(speed=speed, distance=distance)
bearing = CompassBearing(83)

# Positioning Units
latitude = Coordinate(56, 12, 34, "N")
longitude = Coordinate(2, 54, 19, "W")
waypoint = Waypoint(latitude, longitude)

# Routing Units
leg = Leg(sdt, waypoint, bearing)
legs = [leg]

route = Route(legs)

# Example methods

knots = speed.in_knots
time = sdt.time
latitude_in_decimal_format = latitude.as_decimal
longitude_from_decimal = Coordinate.from_decimal(-2.76543)

end_wpt = leg.end_waypoint
number_of_legs = route.number_of_legs
starting_point = route.start_waypoint


for leg in range(number_of_legs):
    current_leg = route.current_leg(leg)
    next_leg = route.next_leg(leg)
    previous_leg = route.previous_leg(leg)

Contributing

See the Contributing Guide

Release files for pynavigation 0.1.0b0

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

Source distribution (sdist)

Source distribution for pynavigation 0.1.0b0
File Size Uploaded
pynavigation-0.1.0b0.tar.gz 5.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pynavigation 0.1.0b0
File Interpreter ABI Platform
pynavigation-0.1.0b0-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 12.3 kB

Release files / pynavigation-0.1.0b0.tar.gz

Download URL pynavigation-0.1.0b0.tar.gz
Size 5.9 kB
Tags Source
SHA-256 checksum
How to use checksums
f43fee6cdec9aad216e22c964519956a851875cb539a14a680d44d5ad8760ce9
BLAKE2b-256 checksum
How to use checksums
8a743835db96cfe9da8a95504640277afa352cbee74167d6eca1ed80207b74ec
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.29.1 CPython/3.6.2

Release files / pynavigation-0.1.0b0-py2.py3-none-any.whl

Download URL pynavigation-0.1.0b0-py2.py3-none-any.whl
Size 6.4 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
202f0a925769181ccee25cd60bff488713e0587cdd1e69630867fd7c8a3e8ef0
BLAKE2b-256 checksum
How to use checksums
c01852aa84fefcd927073843a6e57afaeea5a4ecc65d7df413d7095d1383d3a8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.29.1 CPython/3.6.2

Release history Release notifications | RSS feed

This release

0.1.0b0 This release

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