How to use the pymap3d.aer2enu function in pymap3d

To help you get started, we’ve selected a few pymap3d examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github scivision / pymap3d / tests / test_ned.py View on Github external
def test_ecef_ned():
    enu = pm.aer2enu(*aer0)
    ned = (enu[1], enu[0], -enu[2])
    xyz = pm.aer2ecef(*aer0, *lla0)

    n, e, d = pm.ecef2ned(*xyz, *lla0)
    assert n == approx(ned[0])
    assert e == approx(ned[1])
    assert d == approx(ned[2])

    assert pm.ned2ecef(*ned, *lla0) == approx(xyz)
github scivision / pymap3d / tests / test_aer.py View on Github external
def test_aer_enu(aer, enu):
    assert pm.aer2enu(*aer) == approx(enu)

    raer = (radians(aer[0]), radians(aer[1]), aer[2])
    assert pm.aer2enu(*raer, deg=False) == approx(enu)

    with pytest.raises(ValueError):
        pm.aer2enu(aer[0], aer[1], -1)

    assert pm.enu2aer(*enu) == approx(aer)
    assert pm.enu2aer(*enu, deg=False) == approx(raer)
github scivision / pymap3d / tests / test_aer.py View on Github external
def test_aer_enu(aer, enu):
    assert pm.aer2enu(*aer) == approx(enu)

    raer = (radians(aer[0]), radians(aer[1]), aer[2])
    assert pm.aer2enu(*raer, deg=False) == approx(enu)

    with pytest.raises(ValueError):
        pm.aer2enu(aer[0], aer[1], -1)

    assert pm.enu2aer(*enu) == approx(aer)
    assert pm.enu2aer(*enu, deg=False) == approx(raer)