Skip to content

DOCS: Instantiate a data contribution document and tutorial#68

Merged
msteckle merged 11 commits into
mainfrom
add-data-doc
Mar 4, 2026
Merged

DOCS: Instantiate a data contribution document and tutorial#68
msteckle merged 11 commits into
mainfrom
add-data-doc

Conversation

@msteckle

@msteckle msteckle commented Mar 3, 2026

Copy link
Copy Markdown
Collaborator

Step-by-step walkthrough of how to contribute ILAMB-ready data. Non-interactive code snippets for now, but in the future that would be fun. I walk through the formatting of CLASS-1-1 as an example.

@msteckle msteckle requested review from Copilot and nocollier March 3, 2026 21:21
@msteckle msteckle self-assigned this Mar 3, 2026
@msteckle msteckle added the documentation Improvements or additions to documentation label Mar 3, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new end-to-end documentation page explaining how to format and contribute ILAMB-ready (obs4MIPs/CF-style) reference datasets, using CLASS-1-1 as the worked example.

Changes:

  • Introduces a new “How to contribute data” tutorial covering expected NetCDF structure and formatting workflow.
  • Includes a walkthrough of key formatting steps (download, renaming, time/space coords & bounds, var/global attrs, export).
  • Adds an ODS 2.6 global-attributes “cheatsheet” section for contributors.
Comments suppressed due to low confidence (5)

docs/how-to-contribute-data.md:192

  • Typo: 'tifs' should be 'tiffs' (or 'GeoTIFFs').
import xarray as xr  # xarray is great for working with multi-dimensional tifs/tables/NetCDFs

docs/how-to-contribute-data.md:209

  • Wording: 'htmls' is unclear here; consider 'URLs' or 'HTTP URLs'.
This particular dataset is stored on a thredds server, which you can access directly using htmls. We have a built-in function called `download_from_html()` that is handy here. You just need to provide the URL and a path to the file you want to save the data to. The function will check if the file already exists, and if it doesn't, it will download the data and save it to the specified path. We have other built-in downloading functions, such as `download_from_zenodo()`. We have also installed [earthaccess](https://earthaccess.readthedocs.io/en/latest/) into the Python environment, so you can easily search and download data from NASA Earthdata servers. All of our built-in functions are stored in `ilamb3_data/ilamb3_data/`, so you can check there to see if we have a function that works for your data source. If not, you can write your own function and add it to the library for others to use!

docs/how-to-contribute-data.md:122

  • Missing space after comma.
Follow this tutorial if you would like to format a dataset to be ILAMB-ready. We have all the built-in tools you need to make an ILAMB-legible reference dataset that also conveniently adheres to community standards. First, you will need to create a GitHub account, and then you will need to fork our repository. To do so,visit https://github.com/rubisco-sfa/ilamb3-data and click “Fork,” or optionally install the [GitHub command line tool](https://cli.github.com/), and then run the following in your terminal:

docs/how-to-contribute-data.md:281

  • Typo in 'coordinates'.
You should see that the time coordiantes are `dtype('<M8[ns]')`, which means that they are in nanosecond datetime format. Xarray has a `.dt` accessor that allows you to easily manipulate datetime objects like this. So, let's turn out datetime coordinates into `cf.datetime` objects so we can use our built-in functions: 

docs/how-to-contribute-data.md:282

  • Wording/typo: should be 'our datetime coordinates', not 'out datetime coordinates'.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/how-to-contribute-data.md Outdated
Comment thread docs/how-to-contribute-data.md Outdated
Comment thread docs/how-to-contribute-data.md Outdated
Comment thread docs/how-to-contribute-data.md
Comment thread docs/how-to-contribute-data.md Outdated
Comment thread docs/how-to-contribute-data.md Outdated
Comment thread docs/how-to-contribute-data.md

@nocollier nocollier left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is really great! A couple minor comments.

Comment thread docs/how-to-contribute-data.md Outdated
Comment thread docs/how-to-contribute-data.md Outdated
@msteckle msteckle merged commit 9368ba3 into main Mar 4, 2026
1 check passed
@msteckle msteckle deleted the add-data-doc branch March 4, 2026 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants