Skip to content

Commit

Permalink
Merge pull request #53 from nasa/ghg_tutorial
Browse files Browse the repository at this point in the history
After workshop notebook updates and web-book prep
  • Loading branch information
amfriesz authored Mar 27, 2024
2 parents d12e4b5 + 24bd73b commit 5528030
Show file tree
Hide file tree
Showing 12 changed files with 121 additions and 348 deletions.
11 changes: 11 additions & 0 deletions CHANGE_LOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
_________________________________________________________________________

## 2024-03-22

> ### Added
>
> - `geojson` with plume bounding box for `Visualizing Methane Plume Timeseries` notebook
> ### Changed
>
> - Updates to instructions in `Visualizing Methane Plume Timeseries` notebook
> - Remove horizontal lines from notebooks for web-book creation
## 2024-03-13

> ### Added
Expand Down
7 changes: 7 additions & 0 deletions data/methane_tutorial/plume_bbox.geojson
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "FeatureCollection",
"crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } },
"features": [
{ "type": "Feature", "properties": { "name": "plume_bbox" }, "geometry": { "type": "Polygon", "coordinates": [ [ [ 36.1075296, 31.8092048 ], [ 36.2805017, 31.8092048 ], [ 36.2805017, 32.1274953 ], [ 36.1075296, 32.1274953 ], [ 36.1075296, 31.8092048 ] ] ] } }
]
}
16 changes: 2 additions & 14 deletions python/how-tos/How_to_Convert_to_ENVI.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
"source": [
"# How To: Convert EMIT .nc to .envi\n",
"\n",
"---\n",
"\n",
"There are currently 2 similar methods to convert the EMIT netCDF4 files to `.envi` format. Note these only support L1B Radiance, L1B Obs, L2A Reflectance, L2A Reflectance Uncertainty, or L2A Mask to .envi. They do not yet support the L2B Mineral or L2B Mineral Uncertainty products.\n",
"1. The `write_envi` function in EMIT tools. This function is still being developed but will currently:\n",
" - Write a GLT output to use for orthocorrection later \n",
Expand All @@ -23,17 +21,13 @@
"\n",
"**Learning Objectives**\n",
"+ How to use the `write_envi` function from `emit_tools` module to convert an EMIT netCDF4 to a `.envi` file.\n",
"+ How to use the `reformat.py` function from the `emit-utils` repository to convert an EMIT netCDF4 to a `.envi` file.\n",
"\n",
"---"
"+ How to use the `reformat.py` function from the `emit-utils` repository to convert an EMIT netCDF4 to a `.envi` file."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Setup\n",
"\n",
"Import packages"
Expand Down Expand Up @@ -150,8 +144,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Method 1: Using `write_envi` from the `emit_tools` module.\n",
"\n",
"Import the necessary packages for this method. "
Expand Down Expand Up @@ -756,8 +748,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Method 2: Using reformat.py from emit-utils\n",
"\n",
"### 2.1 Clone and Install emit-utils\n",
Expand Down Expand Up @@ -886,8 +876,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Contact Info: \n",
"\n",
"Email: [email protected] \n",
Expand Down Expand Up @@ -916,7 +904,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.4"
"version": "3.10.13"
},
"vscode": {
"interpreter": {
Expand Down
12 changes: 2 additions & 10 deletions python/how-tos/How_to_Direct_S3_Access.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
"\n",
"**Learning Objectives** \n",
"+ How to use Direct S3 Access to EMIT Data\n",
"+ How to add this functionality to any notebook from this repository\n",
"\n",
"---"
"+ How to add this functionality to any notebook from this repository"
]
},
{
Expand Down Expand Up @@ -63,8 +61,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Overview of s3 Access\n",
"\n",
"NASA Earthdata Cloud data in S3 can be directly accessed via temporary credentials; this access is limited to requests made within the US West (Oregon) (code: us-west-2) AWS region. Direct S3 access is achieved by passing NASA supplied temporary credentials (token) to AWS so we can interact with S3 objects from applicable Earthdata Cloud buckets. Your NASA Earthdata login credentials can easily be managed using the `earthaccess` library. We can create the necessary `.netrc` file that stores the Earthdata Login credentials locally with the following code cell. Enter your username and password if prompted, these will be used to sign into NASA Earthdata and retrieve the necessary temporary credentials allowing you to utilize s3 access."
Expand Down Expand Up @@ -246,8 +242,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"--- \n",
"\n",
"## S3 Access for any Notebook in this Repository\n",
"\n",
"Add the two code blocks below to any how-to or tutorial notebook, by replacing the block that sets the local filepath(s) as `fp` with the two blocks below. The first block imports the additional packages required and retrieves temporary s3 credentials. The second uses `s3fs` to open the desired s3 URL and create an object readable by `xarray`."
Expand Down Expand Up @@ -299,8 +293,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Contact Info: \n",
"\n",
"Email: [email protected] \n",
Expand Down Expand Up @@ -329,7 +321,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.16"
"version": "3.10.13"
},
"vscode": {
"interpreter": {
Expand Down
4 changes: 0 additions & 4 deletions python/how-tos/How_to_Extract_Area.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"Import the required Python libraries."
]
},
Expand Down Expand Up @@ -248,8 +246,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Contact Info: \n",
"\n",
"Email: [email protected] \n",
Expand Down
4 changes: 0 additions & 4 deletions python/how-tos/How_to_Extract_Points.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"Import the required Python libraries."
]
},
Expand Down Expand Up @@ -297,8 +295,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Contact Info: \n",
"\n",
"Email: [email protected] \n",
Expand Down
9 changes: 2 additions & 7 deletions python/how-tos/How_to_Orthorectify.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
"source": [
"# How To: Orthorectify EMIT Data\n",
"\n",
"---\n",
">**Warning: This notebook uses a lot of memory**\n",
">**Warning: This notebook uses a lot of memory, if using 2i2c, you will need a 29.7 GB, 3.75 CPU instance.**\n",
"\n",
"EMIT Data is provided in non-orthorectified format to reduce data size. The `location` group contains latitude and longitude values of each pixel as well as a geometric lookup table (GLT) that can be used to orthocorrect the imagery. The GLT is an array that provides relative downtrack and crosstrack reference locations from the raw scene to facilitate fast projection of the dataset.\n",
"\n",
Expand All @@ -31,8 +30,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## 1. Using emit_xarray to Orthorectify\n",
"\n",
"Import the required Python libraries."
Expand Down Expand Up @@ -447,8 +444,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"---\n",
"\n",
"## Contact Info: \n",
"\n",
"Email: [email protected] \n",
Expand Down Expand Up @@ -477,7 +472,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.4"
"version": "3.10.13"
},
"vscode": {
"interpreter": {
Expand Down
Loading

0 comments on commit 5528030

Please sign in to comment.