Skip to content

Commit

Permalink
Merge pull request #1 from gregory-halverson/main
Browse files Browse the repository at this point in the history
initial release
  • Loading branch information
gregory-halverson authored Dec 5, 2024
2 parents 7554aa3 + e7c8b84 commit 4f58e91
Show file tree
Hide file tree
Showing 12 changed files with 1,028 additions and 2 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.

name: Upload Python Package

on:
release:
types: [published]

permissions:
contents: read

jobs:
deploy:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build
- name: Build package
run: python -m build
- name: Publish package
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
61 changes: 61 additions & 0 deletions Concept ID.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
"import VIIRS_tiled_granules\n",
"from VNP09GA_002 import VNP09GA_002_DOI"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"https://cmr.earthdata.nasa.gov/search/collections.json?doi=10.5067/VIIRS/VNP09GA.002\n",
"C2631841556-LPCLOUD\n"
]
}
],
"source": [
"concept_ID = VIIRS_tiled_granules.concept_ID_from_DOI(VNP09GA_002_DOI)\n",
"print(concept_ID)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "VNP09GA-002",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.10"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
31 changes: 29 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,29 @@
# VNP09GA
VIIRS/NPP Surface Reflectance Daily L2G Global 1 km and 500 m SIN Grid Search and Download Utility
# VIIRS/NPP Surface Reflectance Daily L2G Global 1 km and 500 m SIN Grid Search and Download Utility

This tool uses the `earthaccess` library to search and download VNP09GA collection 2 surface reflectance remote sensing data products from the Visible Infrared Imaging Radiometer Suite (VIIRS).

[Gregory H. Halverson](https://github.com/gregory-halverson-jpl) (they/them)<br>
[gregory.h.halverson@jpl.nasa.gov](mailto:gregory.h.halverson@jpl.nasa.gov)<br>
NASA Jet Propulsion Laboratory 329G

## Installation

Install the `VNP09GA-002` package with a dash in the name from PyPi using pip:

```
pip install VNP09GA-002
```

## Usage

Import the `VNP09GA_002` package with an underscore in the name:

```
import VNP09GA_002
```

See the [example notebook](Searching%20VNP09GA.002%20with%20earthaccess.ipynb) for usage.

## References

NASA Land Processes Distributed Active Archive Center (LP DAAC). 2021. VIIRS/NPP Surface Reflectance Daily L2G Global 1 km and 500 m SIN Grid V002. NASA EOSDIS Land Processes DAAC. doi:[10.5067/VIIRS/VNP09GA.002](https://doi.org/10.5067/VIIRS/VNP09GA.002).
189 changes: 189 additions & 0 deletions Searching VNP09GA.002 with earthaccess.ipynb

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions VNP09GA_002/VNP09GA_002.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
from .constants import *
from .VNP09GA_granule import *
from .retrieve_granule import *
from .search_granules import *
Loading

0 comments on commit 4f58e91

Please sign in to comment.