GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Blog
  • Docs
  • Log in
  • Register
  • Getting help
  • Installing packages
  • Uploading packages
  • Packaging user guide
  • Infrastructure dashboard
  • Statistics
  • Logos & trademarks
  • Our sponsors
  • Bugs and feedback
  • Contribute on GitHub

This view

  • Original page
  • New address

GeezerVison is showing pypi.org — python-srtm

python-srtm 0.6.0

pip install python-srtm

NASA SRTM altitude data parsing in Python

Provides an API onto SRTM .hgt or .hgt.zip files.

Requires Python 3.8, may work with Python 3.6 & 3.7.

Installation

pip install python-srtm

export SRTM1_DIR=/path/to/srtm1/
export SRTM3_DIR=/path/to/srtm3/

Use

You can access either SRTM1 or SRTM3 data. SRTM 1, for example:

# SRTM1 - 30m resolution
>>> from srtm import Srtm1HeightMapCollection
>>> srtm1_data = Srtm1HeightMapCollection()
>>> srtm1_data.get_altitude(latitude=40.123, longitude=-7.456)
615
>>> Srtm1HeightMapCollection().get_elevation_profile(40.123, -7.456, 40.129, -7.460)
[615, 620, 618, 620, 616, 603, 593, 582, 575, 579, 580, 589, 589, 581, 565, 553, 545, 541, 534, 533, 529, 520, 514]

Or SRTM3:

# SRTM3 - 90m resolution
>>> from srtm import Srtm3HeightMapCollection
>>> srtm3_data = Srtm3HeightMapCollection()
>>> srtm3_data.get_altitude(latitude=40.123, longitude=-7.456)
608
>>> Srtm3HeightMapCollection().get_elevation_profile(40.123, -7.456, 40.129, -7.460)
[626, 616, 585, 593, 577, 548, 528, 514]

Profiling

import cProfile
cProfile.run('function_to_profile()', filename='output.cprof')
brew install qcachegrind
pip install pyprof2calltree
pyprof2calltree -k -i /pythonprofiling/profiler/first_iteration.cprof

Release process

For internal reference:

# Run the tests
pytest

export VERSION="VERSION HERE"

# Version bump
poetry version $VERSION

# Ensure poetry.lock is up to date
poetry lock

# Commit
git add .
git commit -m "Releasing version $VERSION"

# Tagging and branching
git tag "v$VERSION"
git branch "v$VERSION"
git push origin \
    refs/tags/"v$VERSION" \
    refs/heads/"v$VERSION" \
    master

poetry publish --build

Project links

  • Homepage
  • Repository

Key dates

PyPI data
Data sourced directly from PyPI's database.
  • Released: Nov 6, 2024
Latest release

1 maintainer

PyPI data
Data sourced directly from PyPI's database.
Avatar for adamcharnock from gravatar.com adamcharnock

Credits

Author: Adam Charnock

License

MIT License (MIT)

Requires

Python <4.0, >=3.8

Tags

nasa geospatial altitude elevation-profile

Classifiers

  • License
    • OSI Approved :: MIT License
  • Programming Language
    • Python :: 3
    • Python :: 3.8
    • Python :: 3.9
    • Python :: 3.10
    • Python :: 3.11
    • Python :: 3.12

Metadata

Project links

  • Homepage
  • Repository

Key dates

PyPI data
Data sourced directly from PyPI's database.
  • Released: Nov 6, 2024
Latest release

1 maintainer

PyPI data
Data sourced directly from PyPI's database.
Avatar for adamcharnock from gravatar.com adamcharnock

Credits

Author: Adam Charnock

License

MIT License (MIT)

Requires

Python <4.0, >=3.8

Tags

nasa geospatial altitude elevation-profile

Classifiers

  • License
    • OSI Approved :: MIT License
  • Programming Language
    • Python :: 3
    • Python :: 3.8
    • Python :: 3.9
    • Python :: 3.10
    • Python :: 3.11
    • Python :: 3.12

Release files for python-srtm 0.6.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 python-srtm 0.6.0
File Size Uploaded Provenance Actions
python_srtm-0.6.0.tar.gz 8.1 kB Nov 6, 2024 Without provenance Details for python_srtm-0.6.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for python-srtm 0.6.0
File Interpreter ABI Platform Actions Reset
python_srtm-0.6.0-py3-none-any.whl 9.0 kB Nov 6, 2024 Without provenance Python 3 none any Details for python_srtm-0.6.0-py3-none-any.whl

Total release size: 17.1 kB

Release files / python_srtm-0.6.0.tar.gz

Download URL python_srtm-0.6.0.tar.gz
Size 8.1 kB
Tags Source
SHA-256 checksum
How to use checksums
778a2f172c394295f934bf6ad5228a13de3575ee78ced965a7e05c88f5312b2b
BLAKE2b-256 checksum
How to use checksums
545715689e6a4eac07edd4187f57d2b467ede3e408f0bbd9ae31c002b2aabece
Upload date Nov 6, 2024
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.3 CPython/3.12.6 Darwin/24.1.0

Release files / python_srtm-0.6.0-py3-none-any.whl

Download URL python_srtm-0.6.0-py3-none-any.whl
Size 9.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
27e584ab4f0ca2103b0d6aff52e3e4cc7b70d9ed2787ff4c0c7025329b1e11ff
BLAKE2b-256 checksum
How to use checksums
1d938a573174a8c45a634a01d3d1602952ef033ae898b02fdadc6e01fbc95c54
Upload date Nov 6, 2024
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.3 CPython/3.12.6 Darwin/24.1.0

Security for python-srtm 0.6.0

Report project as malware

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.6.0 This release

Nov 6, 2024 2 release files No provenance

0.5.0

Apr 30, 2021 2 release files No provenance

0.4.0

Mar 15, 2021 2 release files No provenance

0.3.0

Apr 21, 2020 2 release files No provenance

0.2.0

Apr 12, 2020 2 release files No provenance

0.1.0

Apr 12, 2020 2 release files No provenance

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.