Skip to content

Make FOF tolerance variables configurable (--fof-tolerance-vars) - #125

Draft
huppd wants to merge 1 commit into
mainfrom
enable_fof_tol_variables
Draft

huppd wants to merge 1 commit into
mainfrom
enable_fof_tol_variables

Conversation

@huppd

@huppd huppd commented Nov 18, 2026

Copy link
Copy Markdown
Collaborator

Until now, only veri_data got a tolerance in FOF checks. All other observation variables (e.g. e_o, plevel) had to match exactly.

  • tolerance and fof-compare have a new option, --fof-tolerance-vars (default veri_data). The tolerance CSV now has one column per variable.
  • check reads the variable list from the CSV columns and leaves those variables out of the exact comparison. check and select_members need no new option.
  • These are rejected with an error:
    • sort keys (lat, lon, dlat, dlon, statid, varno, level, time_nomi)
    • variables that are also in --rules
    • variables that aren't in the file
  • QC fields (state/flags/check) still go through --rules.
  • Old tolerance files with a single unnamed or tolerance column still work and are applied to veri_data, with a warning.
  • Fix: a --rules violation in the reports was lost when the observations were clean. It is now reported as a failure.
  • Tests: new tests/engine/test_fof_tolerance_vars.py covers tolerance → check, old tolerance files, fof-compare and the error cases, plus unit tests for the new check. The README has a short section on the option.

🤖 Generated with Claude Code

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant