Skip to content

Saving gauge data in test.py #101

@rjleveque

Description

@rjleveque

I think there's a potential problem with the way regression tests using gauges are done.

When save == True, test.check_gauges reads in the gauge data from Fortran but then writes it out again with the Python code at line
https://github.com/clawpack/clawutil/blob/acf3fc4/src/python/clawutil/test.py#L338

This has a different format (see clawpack/pyclaw#542). To run the regression test it is the latter file that is read in and then values summed to compare with the sum of the Fortran gauge output from the latest run. These might differ just due to the different precision in the Python write.

At any rate, IMHO it would be better to just copy over the gauge file from the Fortran output into the regression_data directory when save == True. This would facilitate comparing this file to the gauge output from a new run if the test fails and one is trying to debug.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions