No project description provided
Project description
PyGsiElev
This is a tiny Python package that can get the elevation of specified coordinates, using the open DEM data distributed from GSI.
Prepare data
-
Download DEM data from GSI's download service. The service is free of charge, but user registration is required.
-
Place the downloaded zip files together in a directory of your choice.
How to use
Install pygsielev package using pip.
$ pip install pygsielev
Import pygsielev.ElevationExtractor class and instanciate with data_dir.
Then, call get_elevation() of the object with longitude and latitude.
>>> from pygsielev import ElevationExtractor
>>> engine = ElevationExtractor(data_dir="data/")
>>> print(engine.get_elevation(lon=138.727299, lat=35.360785))
(3774.9, 'その他')
It returns a tuple contains (elevation, surface type).
Note: When the data_dir paramater is omitted, the environmental variable
GSIELEV_DATADIR will be used to get the data directory.
Operating environment
This package works with Python 3.9 or later. It uses only the standard library.
Contributing
Pull requests are welcome.
Author
Takeshi Sagara sagara@info-proto.com
License
This package can be used under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pygsielev-0.1.1.tar.gz.
File metadata
- Download URL: pygsielev-0.1.1.tar.gz
- Upload date:
- Size: 5.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.10.12 Linux/5.15.167.4-microsoft-standard-WSL2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc60c04bea7b749a9134a23624abc45cf31c495bb81294f4f16b7135f7ce565b
|
|
| MD5 |
acd76d21bc31c74a887ea7202601005d
|
|
| BLAKE2b-256 |
e67074134f2b18197dd77a6417a28e213bfb5271ef5ca5cd9053720d52caf06e
|
File details
Details for the file pygsielev-0.1.1-py3-none-any.whl.
File metadata
- Download URL: pygsielev-0.1.1-py3-none-any.whl
- Upload date:
- Size: 6.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.10.12 Linux/5.15.167.4-microsoft-standard-WSL2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b0fb3b91e3c7d659e05c108578ba62883a32ea884775c4743193610686fecbde
|
|
| MD5 |
2b3f76ab418269c0894bc9b64f91406f
|
|
| BLAKE2b-256 |
bf440248c41907f4485638fe410bf2aae997360048f8d03e6765cb64b520c8b7
|