gportal-python
Unofficial python client for G-Portal Catalogue Service and SFTP.
This package is distributed under the MIT License, but the data that can be retrieved through this package is provided under G-Portal Terms of Use. Please make sure to review them before using the G-Portal data.
Installation
$ pip install gportal
Quickstart
import gportal
# Get the dictionary of the G-Portal dataset.
# It corresponds to the "spacecraft/sensor" search tree of the Web UI.
datasets = gportal.datasets()
# Build a search query.
res = gportal.search(
dataset_ids=datasets["GCOM-C/SGLI"]["LEVEL2"]["Land area"]["L2-LST"],
start_time="2023-03-25T00:00:00",
end_time="2023-03-25T23:59:59",
bbox=[130, 30, 140, 40],
params={
# You can add more parameters.
# See Appendix 7 of G-Portal User's Manual for more details:
# https://gportal.jaxa.jp/gpr/assets/mng_upload/COMMON/upload/GPortalUserManual_en.pdf
},
)
print("Matched:", res.matched())
# Get the resulting products.
products = res.products()
# Download the product files via SFTP.
gportal.username = "sankichi92"
gportal.password = "**********" # If env var GPORTAL_PASSWORD is set, the value is used.
gportal.download(products, local_dir="path/to/download/dir")
Documentation
https://gportal.readthedocs.io/
Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/sankichi92/gportal-python. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct.
Development
This project uses Poetry.
Install dependencies
$ poetry install
Run the test suite
$ poetry run pytest
Start the docs server
$ poetry run mkdocs serve
Release a new version
- Bump the version in
pyproject.tomlbypoetry versionand commit it. - Create a git tag for the new version.
- Push it to GitHub, and then the
publish-packageworkflow starts.
Metadata
Release files for gportal 0.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| gportal-0.4.0.tar.gz | 17.6 kB | Without provenance | Details for gportal-0.4.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gportal-0.4.0-py3-none-any.whl | Python 3 | none | any | Details for gportal-0.4.0-py3-none-any.whl |
Total release size: 36.4 kB
Release files / gportal-0.4.0.tar.gz
| Download URL | gportal-0.4.0.tar.gz |
|---|---|
| Size | 17.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e6ef5b3cb801ccc2a4d27c00d9cbb0a0f3e8a1c74d72f153cfa5ba8f2df31d39
|
|
BLAKE2b-256 checksum How to use checksums |
b520e89e973fe69b8fffa87053ca15e15433118f06eeaeebb713c43d08725a2f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.2 CPython/3.10.6 Linux/5.15.0-1037-azure
|
Release files / gportal-0.4.0-py3-none-any.whl
| Download URL | gportal-0.4.0-py3-none-any.whl |
|---|---|
| Size | 18.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bcfe26ff92b9923428629a8a761c20ea9784b1e10312d3332af57d45a731dd6b
|
|
BLAKE2b-256 checksum How to use checksums |
0787a35883e2804398628c41d282f6c20c64aef34d8c184a9ffb5963b26cd9d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.2 CPython/3.10.6 Linux/5.15.0-1037-azure
|
Security for gportal 0.4.0
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.