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.3.0.tar.gz (14.7 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.3.0-py3-none-any.whl (15.4 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: gportal-0.3.0.tar.gz
  • Upload date:
  • Size: 14.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.10.6 Linux/5.15.0-1035-azure

File hashes

Hashes for gportal-0.3.0.tar.gz
Algorithm Hash digest
SHA256 aab48e2381b2b04254efc8393ec0af10949d6868817ceb3e34ab327f71c58839
MD5 9fb21c9ceae04e00cdb33869301b1ea5
BLAKE2b-256 b18487f7c1ebd6aef724c3314534102f045a44561d3f742e691404ec52e8197c

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for gportal-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 55621062a019808113126bb684d80480ff3c69f2a93c6ec6ea2e2070b70a8a8f
MD5 2f17a26ef72777604be2159c59d1456c
BLAKE2b-256 55b70c7ea414359df2019413d7fbfbcad259d381ba9af9ed1bda7fa61fbe15fb

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