Skip to content

Commit

Permalink
✅ Document and test data catalog loading functionality
Browse files Browse the repository at this point in the history
Ensure that the ATLAS intake catalog is able to be loaded, and secretly document it's usage a little bit. Make the Github Actions test pass by busting the poetry cache through bumping json5 from 0.9.4 to 0.9.5.
  • Loading branch information
weiji14 committed May 29, 2020
1 parent 02904bb commit 3c3d021
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 4 deletions.
1 change: 1 addition & 0 deletions atl06_play.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1043,6 +1043,7 @@
"\n",
"# open the local intake data catalog file containing ICESat-2 stuff\n",
"# data download will depend on having a .netrc file in home folder\n",
"# dataset = intake.cat.atlas_cat.icesat2atl06.to_dask().unify_chunks()\n",
"dataset = deepicedrain.catalog.icesat2atl06.to_dask().unify_chunks()\n",
"dataset"
]
Expand Down
1 change: 1 addition & 0 deletions atl06_play.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@

# open the local intake data catalog file containing ICESat-2 stuff
# data download will depend on having a .netrc file in home folder
# dataset = intake.cat.atlas_cat.icesat2atl06.to_dask().unify_chunks()
dataset = deepicedrain.catalog.icesat2atl06.to_dask().unify_chunks()
dataset

Expand Down
14 changes: 13 additions & 1 deletion deepicedrain/tests/test_deepicedrain.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
from deepicedrain import __version__
import intake

from deepicedrain import __version__, catalog


def test_version():
assert __version__ == "0.1.0"


def test_deepicedrain_catalog():
"""
Test that the intake ATLAS data catalog can be loaded via both
`deepicedrain.catalog` and `intake.cat.atlas_cat`
"""
catalog_entries = ["icesat2atlasdownloader", "icesat2atl06", "test_data"]
assert list(catalog) == catalog_entries
assert list(intake.cat.atlas_cat) == catalog_entries
9 changes: 6 additions & 3 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3c3d021

Please sign in to comment.