Kerchunk success using original CNAPS NetCDF3-64bit-offset files! #2
rsignell
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
CNAPS fans,
Remember when I said that kerchunk wouldn't work for the original CNAPS NetCDF files because they were NetCDF3 64-bit offset files instead of NetCDF4? Well they do work, thanks to a bit of help from @martindurant!
It's particularly cool, too, because normally you can't even read a NetCDF3 64-bit offset file from object storage. So the strategy is:
NetCDF3toZarrmethod withversion=2, like so:NetCDF3ToZarr(f,inline_threshold=300, version=2)combined.jsonfile (that points to the local references)kerchunk.utilsfunctionrename_target_filesto create a combined reference filecombined_s3.jsonthat points to data on S3 object storage instead of local files.combined_s3.jsonreferences!Here's proof that it works -- a snapshot from the CNAPS Explorer notebook using this new Intake entry:

Beta Was this translation helpful? Give feedback.
All reactions