Skip to content

Report a failed verification as two .mat files - #348

Merged
sjoelund merged 1 commit into
masterfrom
new-reference-comparison
Sep 9, 2026
Merged

Report a failed verification as two .mat files#348
sjoelund merged 1 commit into
masterfrom
new-reference-comparison

Conversation

@sjoelund

@sjoelund sjoelund commented Sep 2, 2026

Copy link
Copy Markdown
Member

A failed comparison used to produce a CSV and a dygraph HTML page per differing variable, plus an index page: diffSimulationResults wrote the CSVs itself, testmodel.py the HTML, and every double became text on the way. It now writes two files, the result and the reference reduced to the differing variables with filterSimulationResults, and the report links them to the OMPlot page of the OpenModelica playground, which runs the same tube comparison in the browser and plots every variable on demand:

https://playground.openmodelica.org/latest/omplot/?result=…&reference=…

The page needs absolute URLs, so library.html.tpl resolves the two relative paths at load time; without JavaScript the link is the result file itself. diffSimulationResults is called with an empty prefix, which (since the matching omc change) writes no per-variable CSV. Filtering a CSV reference needs an omc with that change as well; an older one logs the failure to the .err and the report has no reference file for that model.

The files server has to allow cross-origin reads (Access-Control- Allow-Origin) for the page to fetch them.

Assisted-by: Claude Fable 5.1

@sjoelund

sjoelund commented Sep 2, 2026

Copy link
Copy Markdown
Member Author

This is a draft PR because it requires a newer OMC to perform the reference comparison

A failed comparison used to produce a CSV and a dygraph HTML page per
differing variable, plus an index page: `diffSimulationResults` wrote
the CSVs itself, testmodel.py the HTML, and every double became text on
the way. It now writes two files, the result and the reference reduced
to the differing variables with `filterSimulationResults`, and the
report links them to the OMPlot page of the OpenModelica playground,
which runs the same tube comparison in the browser and plots every
variable on demand:

    https://playground.openmodelica.org/latest/omplot/?result=…&reference=…

The page needs absolute URLs, so library.html.tpl resolves the two
relative paths at load time; without JavaScript the link is the result
file itself. `diffSimulationResults` is called with an empty prefix,
which (since the matching omc change) writes no per-variable CSV.
Filtering a CSV reference needs an omc with that change as well; an
older one logs the failure to the .err and the report has no
reference file for that model.

The files server has to allow cross-origin reads (Access-Control-
Allow-Origin) for the page to fetch them.

The docker images were updated to pull in the nightly omc since it
is needed for the small API changes to `filterSimulationResults`.

Assisted-by: Claude Fable 5.1
@sjoelund
sjoelund force-pushed the new-reference-comparison branch from b190901 to ce78849 Compare September 9, 2026 05:51
@sjoelund
sjoelund marked this pull request as ready for review September 9, 2026 05:51
@sjoelund
sjoelund merged commit 5e78576 into master Sep 9, 2026
7 checks passed
@sjoelund
sjoelund deleted the new-reference-comparison branch September 9, 2026 06:59
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