Skip to main content

Client for JAXA G-Portal Catalogue Service and SFTP

Project description

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/

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

  1. Bump the version in pyproject.toml by poetry version and commit it.
  2. Create a git tag for the new version.
  3. Push it to GitHub, and then the publish-package workflow starts.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gportal-0.2.0.tar.gz (14.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gportal-0.2.0-py3-none-any.whl (15.0 kB view details)

Uploaded Python 3

File details

Details for the file gportal-0.2.0.tar.gz.

File metadata

  • Download URL: gportal-0.2.0.tar.gz
  • Upload date:
  • Size: 14.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.1 CPython/3.10.6 Linux/5.15.0-1034-azure

File hashes

Hashes for gportal-0.2.0.tar.gz
Algorithm Hash digest
SHA256 7dc15e32e1fd690a18025b44f609214d41b5e63589b746708a7c803d9cf7123a
MD5 d49ec81f94c985578b01deb445e1d6d4
BLAKE2b-256 dbbb0b619aef784e29a9a8ced701ddad2c0a5dfd069f6ee2ddb230ebeda698bf

See more details on using hashes here.

File details

Details for the file gportal-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: gportal-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 15.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.1 CPython/3.10.6 Linux/5.15.0-1034-azure

File hashes

Hashes for gportal-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5e59034223759d9c45bc65972da56ffea7f7a05a44702148bc031659dd015d7c
MD5 9d7da4e4e7615d9251bb2a7951cf8f49
BLAKE2b-256 21c660e3d363e8823a34c7ce55dbd06d1d018c3f1ede5e7e88dc7b739b3ed7ba

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page