-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
✨ Added an SiDB simulation file writer #176
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #176 +/- ##
==========================================
+ Coverage 94.24% 94.31% +0.07%
==========================================
Files 77 79 +2
Lines 7091 7165 +74
==========================================
+ Hits 6683 6758 +75
+ Misses 408 407 -1
... and 2 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
clang-tidy review says "All clean, LGTM! 👍" |
… one provided by `sidb_charge_state.hpp`
Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com>
…e-sqd-sim-results
Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
clang-tidy review says "All clean, LGTM! 👍" |
clang-tidy review says "All clean, LGTM! 👍" |
clang-tidy review says "All clean, LGTM! 👍" |
clang-tidy review says "All clean, LGTM! 👍" |
clang-tidy review says "All clean, LGTM! 👍" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com>
clang-tidy review says "All clean, LGTM! 👍" |
clang-tidy review says "All clean, LGTM! 👍" |
* ✨ header for temperature simulation * ✨ header for temperature simulation * ✅ occupation function with tests * 🚧 "critical temperature function" is implemented. Test also added. * 🚧 CT of "bestagon gates" can be simulated correctly * ✅ tests updated * ✅ tests updated * ✅ tests updated * 🎨 map replaced by vector * 📝 docu for new functions * 📝 docu for new functions * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🚀 * ⬆️ submodules upgraded * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 small cahnges * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 replaced std::rand(), caused problem at temperature implementation * 🎨 small changes here and there * 🎨 reformat code * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 renaming function * ✨ flag added to decide between gate and random layout * ✨ flag added to decide between gate and random layout * ✨ flag added to decide between gate and random layout * ✨ min_energy added in occupation_probability.hpp * 🎨 Reformatted and cleaned up code * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 Slight revision for consistency * 🎨 renaming * ⬆️ Bump libs/Catch2 from `50bf00e` to `9a2a4ea` (#182) * 🎨 reformat code * redefinition of sidb_nm_position (#186) * ⬆️ Bump libs/Catch2 from `6783411` to `1f881ab` (#27) Bumps [libs/Catch2](https://github.com/catchorg/Catch2) from `6783411` to `1f881ab`. - [Release notes](https://github.com/catchorg/Catch2/releases) - [Commits](catchorg/Catch2@6783411...1f881ab) --- updated-dependencies: - dependency-name: libs/Catch2 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * ⬆️ Bump libs/parallel-hashmap from `7883cb6` to `d2bed96` (#33) Bumps [libs/parallel-hashmap](https://github.com/greg7mdp/parallel-hashmap) from `7883cb6` to `d2bed96`. - [Release notes](https://github.com/greg7mdp/parallel-hashmap/releases) - [Commits](greg7mdp/parallel-hashmap@7883cb6...d2bed96) --- updated-dependencies: - dependency-name: libs/parallel-hashmap dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * 🎨 return value of ``sidb_nm_position`` changed from meter to nanometer for consistency. * 🎨 renaming. --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Drewniok <jan.drewniok.reseaqrch@gmail.com> * 👷 Use the GitHub token of the checked-out repo instead of the own for the `add-and-commit` action after clang-format has been run * 🎨 Changed the unit of the lambda-tf physical parameter from meter to nanometer (#188) * 🎨 Unit of `lambda_tf` is changed from meter to nanometer. * 🎨 `epsilon_r` is unit-less. * ✨ Added a function to round a number to `n` decimal places (#189) * ✨ small function to round numbers to ``n`` decimal places. * ✅ test added. * 🎨 implemented Marcel's suggestions. * 🎨 make use of new function in ``energy_distribution``. * ✨ Added an SiDB simulation file writer (#176) * ✨ Added a new unified return type for SiDB simulation * ✨ Added a file writer for SQD simulation runs parsable by SiQAD * 📝 Added and fixed docstrings * 📝 Added RST documentation * 📝 Removed superfluous newlines * 🎨 Incorporated clang-tidy's recommendations * 🎨 Rewrote `any_to_string` to be more performant and extensible * 🐛 Replaced the usage of the custom charge to string function with the one provided by `sidb_charge_state.hpp` * ✅ Added a test case for positive SiDBs * ✅ Added test cases for `any_to_string` * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🐛 Added `inline` to `any_to_string` in order to avoid ODR problems * ✅ Fixed the test case * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 👽 Convert nm to Angstrom * 👽 Round distances and energy values to 6 decimal points * ✅ Added additional tests to cover more lines * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> --------- Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> Co-authored-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 larger architectural changes. * 🎨 reformat code and documentation. * 🎨 small changes in exhaustive_ground_state_simulation.hpp due to unit changes from ``main`` branch. * 📝 added docu. * ⬆️ Bump ZedThree/clang-tidy-review from 0.12.2 to 0.13.0 (#193) * ⬆️ Bump libs/Catch2 from `9a2a4ea` to `10596b2` (#191) Bumps [libs/Catch2](https://github.com/catchorg/Catch2) from `9a2a4ea` to `10596b2`. - [Release notes](https://github.com/catchorg/Catch2/releases) - [Commits](catchorg/Catch2@9a2a4ea...10596b2) --- updated-dependencies: - dependency-name: libs/Catch2 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * ⬆️ Bump libs/parallel-hashmap from `d2bed96` to `7807157` (#192) Bumps [libs/parallel-hashmap](https://github.com/greg7mdp/parallel-hashmap) from `d2bed96` to `7807157`. - [Release notes](https://github.com/greg7mdp/parallel-hashmap/releases) - [Commits](greg7mdp/parallel-hashmap@d2bed96...7807157) --- updated-dependencies: - dependency-name: libs/parallel-hashmap dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * ✅ Ensured a reproducible SiDB order for test reproducibility (#194) * ✅ Ensured a reproducible SiDB order for test reproducibility * 💚 Ordered surfaces as well --------- Co-authored-by: Jan Drewniok <97012901+Drewniok@users.noreply.github.com> * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * ⬆️ Bump DoozyX/clang-format-lint-action from 0.15 to 0.16 (#196) Bumps [DoozyX/clang-format-lint-action](https://github.com/DoozyX/clang-format-lint-action) from 0.15 to 0.16. - [Release notes](https://github.com/DoozyX/clang-format-lint-action/releases) - [Commits](DoozyX/clang-format-lint-action@v0.15...v0.16) --- updated-dependencies: - dependency-name: DoozyX/clang-format-lint-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * 🎨 changes after review. * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 changes after review. * 🎨 use data type for energy distribution. * 🎨 additional ``else`` to try to fix windows build issue. * ✨ Make ClangFormat aware of different line ending types and enforce `LF` (#177) * 🎨 Added a flag to the ClangFormat config to enforce LF line endings (as of version 16) * 🎨 Re-applied ClangFormat to the project * ⬆️ Switched to ClangFormat 16 * 📝 add links for RST. * 📝 add links for RST. * 📝 add named anchor. * 📝 use ``-`` instead of ``_``. * 🐛 add missing ``$`` in docstring. * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 copy enum class to try to solve window build issue. * 🎨 tiny change in docu. * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🔥 remove file from git. * ✅ add additional test. * 🐛 add ``recompute_energy`` and test which failed before. * 🎨 change to scoped enumerator. * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 use enum struct. * 🔥 remove ``enum class``due to windows CI issue. * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 replace reference. * ✨ code to generate unique random layouts. * ✨ Temperature-aware simulation can be conducted with ``exgs`` or ``quicksim``. All simulation engines use ``sidb_simulation_result`` now to collect results. * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 rename struct member. * 🎨 activate automatic state count detection. * ⬆️ Bump libs/parallel-hashmap from `7807157` to `9f09034` (#199) * 🎨 Ensured SiQAD compatibility of SiDB simulation result writer (#197) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * 🎨 fix ``state count`` to three. Two is not supported by SiQAD yet. * 🎨 reformat code. --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Marcel Walter <marcel.walter@tum.de> * 🎨 update after review (main change: replace stats_pointer as input for simulators). * 🎨 ClangFormat changes Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> * 🎨 introduce impl_class for quickexact. * 🎨 remove ``const``keyword. * 🎨 add ``const``keyword. * 🎨 split in several smaller functions. * 🎨 rename some functions. * 📝 add docu. * ✨ automatic base number detection can be turned ``on`` and ``off``. * 📝 add more documentation. * 🔥 remove files to shift it to separate PR. * 🎨 change order of ``const``keyword and type. * 📝 add RST. * 📝 add documentation. * 💚 add ``const`` keyword. * 🎨 smaller changes to try to fix test issue. * ✅ small change to avoid windows issue. * 📝 add documentation. --------- Signed-off-by: ClangFormat <ClangFormat@users.noreply.github.com> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: Drewniok <jan.drewniok.reseaqrch@gmail.com> Co-authored-by: ClangFormat <ClangFormat@users.noreply.github.com> Co-authored-by: Marcel Walter <marcel.walter@tum.de> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Description
This PR adds a new file writer that can write SiDB simulation results to XML files that are parsable by SiQAD. To this end, a new data type
sidb_simulation_result
is introduced that can serve as a unified return type across SiDB simulation algorithms.Checklist: