Skip to content

A script to update CDF metadata and to create new CDFs from templates - #22

Open
DCarSunDr wants to merge 9 commits into
mainfrom
t_9
Open

A script to update CDF metadata and to create new CDFs from templates#22
DCarSunDr wants to merge 9 commits into
mainfrom
t_9

Conversation

@DCarSunDr

@DCarSunDr DCarSunDr commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Added a "cdf_updater" script to take a dictionary of update actions and to apply them to a target CDF file. This file could also be a mastercdf file. Also allows user to create new file using an existing mastercdf as a template by applying updates to a copy of the mastercdf template.

Loads contents of existing CDF/mastercdf template into a dictionary structure, applies updates specified by input argument to this CDF dictionary, and then writes new CDF file from the updated CDF dictionary. If target CDF already exists, moves it to temporary processing directory while copy of CDF contents are being updated and while new CDF is being written. Once the updates are complete, "cdf_updater" attempts to validate the update by comparing contents of updated CDF dictionary to a CDF dictionary loaded from the newly written CDF file. If any errors are encountered, or if the new CDF fails the validation check, the script moves the old CDF file from the temporary processing directory back to its original directory, if the old CDF already existed.

The script also attempts to enforce CDF variable data datatypes, default Pad values, and THEMIS standard fill values.

Also added a script to retrieve SNKQ and LRV data from alternate remote sources where they are available at the 1 minute time cadence

DCarSunDr added 9 commits July 7, 2026 20:03
…the web query constructor into a separate script. Cleaned up some unused parts of variometer retrieval script.
… script to process ascii files into GMAG CDFs
…ting scripts. cli versions are still needed, and mastercdfs currently just accept the default fillval and pad values.
…et to nan variant if data is floating type. Ignores differences in cdf info attribute list if they contain the same elements (attribute scope pairs) and are reordered.
@DCarSunDr DCarSunDr self-assigned this Aug 14, 2026
@DCarSunDr DCarSunDr added the enhancement New feature or request label Aug 14, 2026
@DCarSunDr

Copy link
Copy Markdown
Contributor Author

On second thought, I think I still want to add a check in the alternate retrieval script to record if a stations data failed retrieval for a given date. It should have a cli script as well, so that we can use it as a SOC process.

So we might want to hold off on the merge until I add these things.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant