Add SaveBackground task and ingest_background_cf suite for GEOS-CF JDI backgrounds#802
Add SaveBackground task and ingest_background_cf suite for GEOS-CF JDI backgrounds#802ftgoktas wants to merge 35 commits into
Conversation
mranst
left a comment
There was a problem hiding this comment.
One small comment, but looks good. I was able to test the dry run
|
quick comment: |
I agree, just pushed a commit renaming the relevant file/folder names. |
|
Some comments:
Sorry, long list 😟 |
Done! See https://github.com/JCSDA-internal/r2d2-client/issues/112
That got me too 😄, @mer-a-o confirmed the
Switched to
Done, added as a
Agreed, we can discuss and open up a follow up PR.
🫡 |
| # -------------------------------------------------------------------------------------------------- | ||
|
|
||
| @dataclass | ||
| class store_as_symlink(TaskQuestion): |
There was a problem hiding this comment.
Thanks! One quick comment as I'm working on my marine ingest PR. Can you make this key get used for ingest_obs as well?
|
Should we rename |
|
I suggest using "ingest" for suite and then "save" for tasks, |
|
Hmm, I consider
Does that make sense? this means ingest_obs task would be renamed store_obs.. maybe another PR. Also FYI Furkan, the documentation sidebar was messed up and I addressed that in my merged PR. |
Adds a
SaveBackgroundtask and stores GEOS-CF JDI background files into R2D2 as symlinks. The task loops over 24 hourly steps (PT0H–PT23H), resolves each file's path via strftime on a configurable background_source_path template, checks the file exists, and callsr2d2.store(..., store_as_symlink=...). The model is read fromself.__model__. Also names the suite folder suites/r2d2_ingest/ since the suite now covers both observations and backgrounds.How to test:
swell create ingest_jdi_cfdry_runin experiment.yamlfalseto actually store files, or keeptrueto preview which files you will be storing.swell launch ...Note on R2D2
store_as_symlink: After creating the symlink,file_util._set_permissionscallsos.chmodwhich follows the symlink to the source file and throwsPermissionErrorsince we don't own it. The symlink and DB entry are both created before the chmod. We catch and verify the symlink before continuing. I think this is a bug in the R2D2 client (_set_permissionsshould be skipped whenstore_as_symlink=True) and should be fixed there. Created an issue about this here: https://github.com/JCSDA-internal/r2d2-client/issues/112Closes #788