Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[New Feature]: Provide Jupyter Notebook code snippet from feature search #552

Open
fcalef opened this issue Jun 12, 2024 · 0 comments
Open
Labels
enhancement For making an existing feature better

Comments

@fcalef
Copy link
Collaborator

fcalef commented Jun 12, 2024

Checked for duplicates

Yes - I've already checked

Alternatives considered

Yes - and alternatives don't suffice

Related problems

After looking for data, e.g. EMIT (https://earth.jpl.nasa.gov/emit/data/data-portal/coverage-and-forecasts/), I can click on an image footprint and find a link to the L1 or L2 data on EarthData archived data or use the Info tool to click on an image footprint and find metadata I can use to open an image granule in a Jupyter Notebook, but not a more way to open the discovered data in a Jupyter Notebook or an easy way to transfer the necessary metadata into notebook friendly code.

Describe the feature request

When I have a feature(s) in MMGIS that I've selected, an option for "Open in a Jupyter Notebook" or "Code for Notebooks" appears that I can click on to either a) open the selection in a Jupyter Notebook or b) open the whole 2D map in a Jupyter Notebook with the selection or c) provide a code snippet that I could paste into a Jupyter Notebook to access the selected dataset.

Code snippet example:

import xarray as xr

auth = earthaccess.login()

#The search result from MMGIS in Notebook form
results = earthaccess.search_data(
    doi="10.3334/ORNLDAAC/2056"
    bounding_box=(-100,20,-90,40_.
    temporal=(2010,2020)
)

ds = xr.open_mfdataset(earthaccess.open(results)```
@fcalef fcalef added the enhancement For making an existing feature better label Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement For making an existing feature better
Projects
Status: No status
Development

No branches or pull requests

1 participant