Skip to content

CData: address write_value issue in _parameters.csv - #2336

Merged
rmcdermo merged 1 commit into
firemodels:masterfrom
rmcdermo:master
Jul 21, 2026
Merged

CData: address write_value issue in _parameters.csv#2336
rmcdermo merged 1 commit into
firemodels:masterfrom
rmcdermo:master

Conversation

@rmcdermo

Copy link
Copy Markdown
Contributor

This fixes the CData behavior reported in Discussion #2331 where Simple_parameters.csv was created with the expected headers and case names, but the randomized parameter values were blank.

Root cause: the CData parameter-output path had been disconnected in commit 7264729eb (CData: fixed error in write and removed unused code). In that change, the calls to write_value in create_case were commented out. Because those calls were no longer active, the write_value routine later appeared unused and was removed. The result was that CData still created the parameter CSV header row with add_header, but never copied each generated case’s sampled values into the row before flush_parameters_buffer.

The fix restores that missing path:

  • Restored the type-bound write_value routine for value_wrapper_type.
  • Re-enabled the write_value calls after each random fire and field is randomized in create_case.
  • Kept the newer FIRE_DO_RAND behavior that avoids randomizing unassociated fire-generator points, so the previous CData crash fix remains intact.
  • Changed CData’s initial input read to call read_input_file(.false.), so preprocessing does not create empty base-case CFAST output files such as Simple_vents.csv while running cdata Simple.in -P.

After this change, running:

cdata Simple.in -P

@rmcdermo
rmcdermo merged commit 340f57b into firemodels:master Jul 21, 2026
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