Closed vloncar closed 1 year ago
@vloncar should we try to generalize the tests a bit as part of this PR? Or do it later?
https://github.com/vloncar/hls4ml/pull/51#issuecomment-1475376160
I made this PR as a little bonus that would make the notebook-based workflows (and tutorials) more appealing, I didn't think of it being a PR that introduces testing for reporting feature. You added a basic test that IMO suffices, but if you want to do more, I'd be happy to review and merge it.
Description
As a cherry on top for a new release, I propose we make the printing of reports nicer for the user. Yes, this is a result of boredom because I didn't go skiing this weekend, but also because I don't like the ugly screenshots of text reports that many people place on their slides. I guess we can expand this in the future to be a bit more interactive and include the per-layer reports.
Note that the hidden among the style changes is a fix for parsing cosim reports. This previously failed on the accelerator backend.
To try it out, run something like
Hint: Run it in jupyter and as a script to see the difference, I won't spoil the fun here :wink:
Type of change
Tests
The notebook part is not really testable with the current setup, and the text-based reports can only be tested for sanity (if the function fails or not), so I didn't add any tests.
Checklist
pre-commit
on the files I edited or added.