qml-essentials 0.3.0__tar.gz → 0.3.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/workflows/docs-publish.yml +11 -17
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/workflows/docs.yml +12 -18
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/workflows/publish.yml +13 -13
- qml_essentials-0.3.3/.github/workflows/quality-publish.yml +23 -0
- qml_essentials-0.3.3/.github/workflows/quality.yml +24 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/workflows/test-on-pr.yml +7 -8
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/workflows/test-on-publish.yml +7 -8
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/CITATION.cff +4 -2
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/PKG-INFO +4 -3
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/ansaetze.md +1 -1
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/coefficients.md +38 -2
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/entanglement.md +40 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/pyproject.toml +5 -4
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/ansaetze.py +16 -13
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/coefficients.py +142 -67
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/entanglement.py +76 -3
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/model.py +4 -2
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/topologies.py +41 -1
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/conftest.py +4 -1
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_ansaetze.py +98 -3
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_coefficients.py +402 -4
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_entanglement.py +0 -2
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_expressiblity.py +0 -2
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_math_model.py +0 -3
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_model.py +42 -1
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_random_sampling.py +0 -2
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_states.py +0 -3
- qml_essentials-0.3.3/uv.lock +2652 -0
- qml_essentials-0.3.0/.github/workflows/quality-publish.yml +0 -24
- qml_essentials-0.3.0/.github/workflows/quality.yml +0 -25
- qml_essentials-0.3.0/uv.lock +0 -1968
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/CODEOWNERS +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/ISSUE_TEMPLATE/code-health.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/dependabot.yml +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.github/workflows/dependabot-approve.yml +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.gitignore +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/.pre-commit-config.yaml +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/CONTRIBUTING.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/LICENSE +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/README.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/algebra.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/ansaetze.ipynb +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/coefficients.ipynb +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/diagrams.drawio +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/expressibility.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/bloch-sphere.svg +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuit_tikz_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuit_tikz_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_10_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_10_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_13_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_13_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_14_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_14_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_15_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_15_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_16_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_16_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_17_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_17_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_18_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_18_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_19_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_19_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_1_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_1_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_20_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_20_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_2_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_2_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_3_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_3_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_4_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_4_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_5_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_5_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_6_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_6_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_7_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_7_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_8_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_8_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_9_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Circuit_9_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/GHZ_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/GHZ_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Hardware_Efficient_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Hardware_Efficient_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/No_Ansatz_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/No_Ansatz_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/No_Entangling_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/No_Entangling_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Strongly_Entangling_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_4q/Strongly_Entangling_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_10_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_10_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_13_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_13_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_14_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_14_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_15_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_15_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_16_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_16_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_17_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_17_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_18_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_18_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_19_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_19_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_1_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_1_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_20_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_20_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_2_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_2_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_3_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_3_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_4_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_4_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_5_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_5_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_6_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_6_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_7_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_7_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_8_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_8_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_9_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Circuit_9_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/GHZ_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/GHZ_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Hardware_Efficient_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Hardware_Efficient_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/No_Ansatz_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/No_Ansatz_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/No_Entangling_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/No_Entangling_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Strongly_Entangling_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_5q/Strongly_Entangling_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_10_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_10_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_13_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_13_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_14_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_14_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_15_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_15_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_16_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_16_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_17_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_17_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_18_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_18_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_19_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_19_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_1_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_1_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_20_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_20_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_2_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_2_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_3_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_3_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_4_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_4_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_5_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_5_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_6_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_6_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_7_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_7_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_8_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_8_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_9_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Circuit_9_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/GHZ_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/GHZ_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Hardware_Efficient_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Hardware_Efficient_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/No_Ansatz_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/No_Ansatz_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/No_Entangling_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/No_Entangling_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Strongly_Entangling_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/circuits_6q/Strongly_Entangling_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/code.svg +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/fourier_fingerprint_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/fourier_fingerprint_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/fourier_series_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/fourier_series_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/fourier_series_tf_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/fourier_series_tf_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/histogram.svg +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/invert_images.sh +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_2d_psd_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_2d_psd_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_spectr_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_spectr_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_spectr_os_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_spectr_os_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_spectr_ours_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_fct_spectr_ours_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_psd_an_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_psd_an_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_psd_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/model_psd_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/rel-entropy.svg +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/trained_series_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/trained_series_dataset_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/trained_series_dataset_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/trained_series_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/trained_series_tf_dark.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/figures/trained_series_tf_light.png +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/generate_circuits.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/index.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/javascripts/mathjax.js +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/logo.svg +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/metrics.ipynb +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/noise.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/pulses.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/random_sampling.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/references.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/style.css +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/training.ipynb +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/training.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/usage.ipynb +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/docs/usage.md +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/mkdocs.yml +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/__init__.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/algebra.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/expressibility.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/pauli.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/random_sampling.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/states.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/qml_essentials/trainability.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/__init__.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_algebra.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_matchgate_migration.py +0 -0
- {qml_essentials-0.3.0 → qml_essentials-0.3.3}/tests/test_pauli_circuit.py +0 -0
|
@@ -9,21 +9,18 @@ permissions:
|
|
|
9
9
|
contents: write
|
|
10
10
|
pages: write
|
|
11
11
|
id-token: write
|
|
12
|
+
env:
|
|
13
|
+
UV_PYTHON: "3.13"
|
|
12
14
|
jobs:
|
|
13
15
|
test:
|
|
14
16
|
runs-on: self-hosted
|
|
15
17
|
if: ${{ github.ref != 'refs/heads/main' }}
|
|
16
18
|
steps:
|
|
17
19
|
- uses: actions/checkout@v7
|
|
18
|
-
- name:
|
|
19
|
-
|
|
20
|
-
- name: Set up Python 3.13
|
|
21
|
-
uses: actions/setup-python@v7
|
|
22
|
-
with:
|
|
23
|
-
python-version: "3.13"
|
|
24
|
-
# cache: "uv"
|
|
20
|
+
- name: Set up uv
|
|
21
|
+
uses: astral-sh/setup-uv@v7
|
|
25
22
|
- name: Install dependencies
|
|
26
|
-
run:
|
|
23
|
+
run: uv sync --group docs
|
|
27
24
|
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
|
|
28
25
|
# - name: Setting up Cache
|
|
29
26
|
# uses: actions/cache@v4
|
|
@@ -33,7 +30,7 @@ jobs:
|
|
|
33
30
|
# restore-keys: |
|
|
34
31
|
# mkdocs-material-
|
|
35
32
|
- name: Build Docs
|
|
36
|
-
run:
|
|
33
|
+
run: uv run zensical build --strict
|
|
37
34
|
deploy:
|
|
38
35
|
runs-on: self-hosted
|
|
39
36
|
if: ${{ github.ref == 'refs/heads/main' }}
|
|
@@ -47,13 +44,10 @@ jobs:
|
|
|
47
44
|
run: |
|
|
48
45
|
git config user.name github-actions[bot]
|
|
49
46
|
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
|
|
50
|
-
- name: Set up
|
|
51
|
-
uses:
|
|
52
|
-
with:
|
|
53
|
-
python-version: "3.13"
|
|
54
|
-
# cache: "uv"
|
|
47
|
+
- name: Set up uv
|
|
48
|
+
uses: astral-sh/setup-uv@v7
|
|
55
49
|
- name: Install dependencies
|
|
56
|
-
run:
|
|
50
|
+
run: uv sync --group docs
|
|
57
51
|
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
|
|
58
52
|
# - name: Setting up Cache
|
|
59
53
|
# uses: actions/cache@v4
|
|
@@ -63,13 +57,13 @@ jobs:
|
|
|
63
57
|
# restore-keys: |
|
|
64
58
|
# mkdocs-material-
|
|
65
59
|
- name: Download a single artifact
|
|
66
|
-
uses: actions/download-artifact@
|
|
60
|
+
uses: actions/download-artifact@v8
|
|
67
61
|
with:
|
|
68
62
|
name: coverage-report
|
|
69
63
|
run-id: ${{ inputs.test-run-id }}
|
|
70
64
|
path: docs/coverage/
|
|
71
65
|
- name: Build Docs
|
|
72
|
-
run:
|
|
66
|
+
run: uv run zensical build --strict --clean
|
|
73
67
|
- uses: actions/upload-pages-artifact@v5
|
|
74
68
|
with:
|
|
75
69
|
path: site
|
|
@@ -9,21 +9,18 @@ on:
|
|
|
9
9
|
type: string
|
|
10
10
|
permissions:
|
|
11
11
|
contents: write
|
|
12
|
+
env:
|
|
13
|
+
UV_PYTHON: "3.13"
|
|
12
14
|
jobs:
|
|
13
15
|
test:
|
|
14
16
|
runs-on: self-hosted
|
|
15
17
|
if: ${{ github.ref != 'refs/heads/main' }}
|
|
16
18
|
steps:
|
|
17
19
|
- uses: actions/checkout@v7
|
|
18
|
-
- name:
|
|
19
|
-
|
|
20
|
-
- name: Set up Python 3.13
|
|
21
|
-
uses: actions/setup-python@v7
|
|
22
|
-
with:
|
|
23
|
-
python-version: "3.13"
|
|
24
|
-
# cache: "uv"
|
|
20
|
+
- name: Set up uv
|
|
21
|
+
uses: astral-sh/setup-uv@v7
|
|
25
22
|
- name: Install dependencies
|
|
26
|
-
run:
|
|
23
|
+
run: uv sync --group docs
|
|
27
24
|
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
|
|
28
25
|
# - name: Setting up Cache
|
|
29
26
|
# uses: actions/cache@v4
|
|
@@ -33,7 +30,7 @@ jobs:
|
|
|
33
30
|
# restore-keys: |
|
|
34
31
|
# mkdocs-material-
|
|
35
32
|
- name: Build Docs
|
|
36
|
-
run:
|
|
33
|
+
run: uv run zensical build --strict
|
|
37
34
|
deploy:
|
|
38
35
|
runs-on: self-hosted
|
|
39
36
|
if: ${{ github.ref == 'refs/heads/main' }}
|
|
@@ -43,13 +40,10 @@ jobs:
|
|
|
43
40
|
run: |
|
|
44
41
|
git config user.name github-actions[bot]
|
|
45
42
|
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
|
|
46
|
-
- name: Set up
|
|
47
|
-
uses:
|
|
48
|
-
with:
|
|
49
|
-
python-version: "3.13"
|
|
50
|
-
# cache: "uv"
|
|
43
|
+
- name: Set up uv
|
|
44
|
+
uses: astral-sh/setup-uv@v7
|
|
51
45
|
- name: Install dependencies
|
|
52
|
-
run:
|
|
46
|
+
run: uv sync --group docs
|
|
53
47
|
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
|
|
54
48
|
# - name: Setting up Cache
|
|
55
49
|
# uses: actions/cache@v4
|
|
@@ -59,12 +53,12 @@ jobs:
|
|
|
59
53
|
# restore-keys: |
|
|
60
54
|
# mkdocs-material-
|
|
61
55
|
- name: Download a single artifact
|
|
62
|
-
uses: actions/download-artifact@
|
|
56
|
+
uses: actions/download-artifact@v8
|
|
63
57
|
with:
|
|
64
58
|
name: coverage-report
|
|
65
59
|
run-id: ${{ inputs.test-run-id }}
|
|
66
60
|
path: docs/coverage/
|
|
67
61
|
- name: Build Docs
|
|
68
|
-
run:
|
|
62
|
+
run: uv run zensical build --strict
|
|
69
63
|
- name: Deploy
|
|
70
|
-
run:
|
|
64
|
+
run: uv run zensical gh-deploy --force
|
|
@@ -6,6 +6,8 @@ permissions:
|
|
|
6
6
|
contents: write
|
|
7
7
|
pages: write
|
|
8
8
|
id-token: write
|
|
9
|
+
env:
|
|
10
|
+
UV_PYTHON: "3.13"
|
|
9
11
|
jobs:
|
|
10
12
|
test-publish:
|
|
11
13
|
name: Trigger Expensive Tests
|
|
@@ -29,44 +31,42 @@ jobs:
|
|
|
29
31
|
with:
|
|
30
32
|
fetch-tags: true
|
|
31
33
|
ssh-key: ${{ secrets.DEPLOY_KEY }}
|
|
32
|
-
- name: Set up
|
|
33
|
-
uses:
|
|
34
|
-
with:
|
|
35
|
-
python-version: "3.13"
|
|
36
|
-
# cache: "uv"
|
|
34
|
+
- name: Set up uv
|
|
35
|
+
uses: astral-sh/setup-uv@v7
|
|
37
36
|
- name: Compare tag and version
|
|
38
37
|
run: |
|
|
39
38
|
git fetch --tags
|
|
40
|
-
if [ "$(git tag | sort -
|
|
39
|
+
if [ "$(git tag | sort -V | tail -1)" = "$(uv version --short)" ]; then
|
|
41
40
|
echo "The tag and the version are the same, nothing to do."
|
|
42
41
|
echo "DORELEASE=false" >> $GITHUB_ENV
|
|
43
42
|
else
|
|
44
|
-
echo "The tag ($(git tag | sort -
|
|
43
|
+
echo "The tag ($(git tag | sort -V | tail -1)) and the version ($(uv version --short)) differ, trigging a release."
|
|
45
44
|
echo "DORELEASE=true" >> $GITHUB_ENV
|
|
46
45
|
fi
|
|
47
46
|
- name: Update Citation
|
|
48
47
|
if: env.DORELEASE == 'true'
|
|
49
48
|
run: |
|
|
50
|
-
sed -i "/^cff/! s/version:\s\S*/version: $(
|
|
49
|
+
sed -i "/^cff/! s/version:\s\S*/version: $(uv version --short)/" CITATION.cff
|
|
51
50
|
sed -i "s/date-released:\s\S*/date-released: $(date +'%Y-%m-%d')/" CITATION.cff
|
|
52
51
|
git config user.name github-actions[bot]
|
|
53
52
|
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
|
|
54
53
|
git commit -am "Update Citation"
|
|
54
|
+
git pull --rebase
|
|
55
55
|
git push
|
|
56
56
|
env:
|
|
57
57
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
58
58
|
- name: Create Release & Tag
|
|
59
59
|
if: env.DORELEASE == 'true'
|
|
60
60
|
run: |
|
|
61
|
-
gh release create "$(
|
|
61
|
+
gh release create "$(uv version --short)" \
|
|
62
62
|
--repo="$GITHUB_REPOSITORY" \
|
|
63
|
-
--title="${GITHUB_REPOSITORY#*/} $(
|
|
63
|
+
--title="${GITHUB_REPOSITORY#*/} $(uv version --short)" \
|
|
64
64
|
--generate-notes
|
|
65
65
|
env:
|
|
66
66
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
67
67
|
- name: Publish to PyPI
|
|
68
68
|
if: env.DORELEASE == 'true'
|
|
69
69
|
run: |
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
70
|
+
uv sync --group dev
|
|
71
|
+
uv build
|
|
72
|
+
uv publish --token ${{ secrets.PYPI_API_TOKEN }}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
name: Quality on Publish
|
|
2
|
+
on:
|
|
3
|
+
workflow_call:
|
|
4
|
+
permissions:
|
|
5
|
+
contents: read
|
|
6
|
+
env:
|
|
7
|
+
UV_PYTHON: "3.13"
|
|
8
|
+
jobs:
|
|
9
|
+
quality:
|
|
10
|
+
runs-on: self-hosted
|
|
11
|
+
if: ${{ (github.actor != 'dependabot[bot]') }}
|
|
12
|
+
steps:
|
|
13
|
+
- uses: actions/checkout@v7
|
|
14
|
+
- name: Set up uv
|
|
15
|
+
uses: astral-sh/setup-uv@v7
|
|
16
|
+
- name: Install dependencies
|
|
17
|
+
run: uv sync --group dev
|
|
18
|
+
- name: Lint with ruff
|
|
19
|
+
run: |
|
|
20
|
+
uv run ruff check qml_essentials
|
|
21
|
+
uv run ruff check tests
|
|
22
|
+
- name: Running license check
|
|
23
|
+
run: uv run licensecheck --zero --license mit
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
name: Quality
|
|
2
|
+
on:
|
|
3
|
+
pull_request:
|
|
4
|
+
branches: ["main"]
|
|
5
|
+
permissions:
|
|
6
|
+
contents: read
|
|
7
|
+
env:
|
|
8
|
+
UV_PYTHON: "3.13"
|
|
9
|
+
jobs:
|
|
10
|
+
quality:
|
|
11
|
+
runs-on: self-hosted
|
|
12
|
+
if: ${{ (github.actor != 'dependabot[bot]') }}
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v7
|
|
15
|
+
- name: Set up uv
|
|
16
|
+
uses: astral-sh/setup-uv@v7
|
|
17
|
+
- name: Install dependencies
|
|
18
|
+
run: uv sync --group dev
|
|
19
|
+
- name: Lint with ruff
|
|
20
|
+
run: |
|
|
21
|
+
uv run ruff check qml_essentials
|
|
22
|
+
uv run ruff check tests
|
|
23
|
+
- name: Running license check
|
|
24
|
+
run: uv run licensecheck --zero --license mit
|
|
@@ -9,19 +9,18 @@ permissions:
|
|
|
9
9
|
concurrency:
|
|
10
10
|
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
|
|
11
11
|
cancel-in-progress: true
|
|
12
|
+
env:
|
|
13
|
+
UV_PYTHON: "3.13"
|
|
12
14
|
jobs:
|
|
13
15
|
test-all:
|
|
14
16
|
runs-on: self-hosted
|
|
15
17
|
steps:
|
|
16
18
|
- uses: actions/checkout@v7
|
|
17
|
-
- name: Set up
|
|
18
|
-
uses:
|
|
19
|
-
with:
|
|
20
|
-
python-version: "3.13"
|
|
21
|
-
# cache: "uv"
|
|
19
|
+
- name: Set up uv
|
|
20
|
+
uses: astral-sh/setup-uv@v7
|
|
22
21
|
- name: Install dependencies
|
|
23
|
-
run:
|
|
22
|
+
run: uv sync --group dev
|
|
24
23
|
- name: Test with pytest (no benchmark)
|
|
25
|
-
run:
|
|
24
|
+
run: uv run pytest --cov=qml_essentials --dist load -n 2 -m "not benchmark" -v
|
|
26
25
|
- name: Test with pytest (benchmark)
|
|
27
|
-
run:
|
|
26
|
+
run: uv run pytest --cov=qml_essentials -m "benchmark"
|
|
@@ -3,23 +3,22 @@ on:
|
|
|
3
3
|
workflow_call:
|
|
4
4
|
permissions:
|
|
5
5
|
contents: write
|
|
6
|
+
env:
|
|
7
|
+
UV_PYTHON: "3.13"
|
|
6
8
|
jobs:
|
|
7
9
|
test-all:
|
|
8
10
|
runs-on: self-hosted
|
|
9
11
|
if: ${{ (github.actor != 'github-actions[bot]') }}
|
|
10
12
|
steps:
|
|
11
13
|
- uses: actions/checkout@v7
|
|
12
|
-
- name: Set up
|
|
13
|
-
uses:
|
|
14
|
-
with:
|
|
15
|
-
python-version: "3.13"
|
|
16
|
-
# cache: "uv"
|
|
14
|
+
- name: Set up uv
|
|
15
|
+
uses: astral-sh/setup-uv@v7
|
|
17
16
|
- name: Install dependencies
|
|
18
|
-
run:
|
|
17
|
+
run: uv sync --group dev
|
|
19
18
|
- name: Test with pytest (no benchmark)
|
|
20
|
-
run:
|
|
19
|
+
run: uv run pytest --cov=qml_essentials --cov-report html --dist load -n 0 -m "not benchmark"
|
|
21
20
|
- name: Share coverage report
|
|
22
|
-
uses: actions/upload-artifact@
|
|
21
|
+
uses: actions/upload-artifact@v7
|
|
23
22
|
with:
|
|
24
23
|
name: coverage-report
|
|
25
24
|
path: htmlcov/
|
|
@@ -21,11 +21,13 @@ authors:
|
|
|
21
21
|
- family-names: "Wahl"
|
|
22
22
|
given-names: "Johannes"
|
|
23
23
|
title: "QML Essentials"
|
|
24
|
-
version: 0.3.
|
|
25
|
-
date-released: 2026-
|
|
24
|
+
version: 0.3.3
|
|
25
|
+
date-released: 2026-11-26
|
|
26
26
|
repository-code: "https://github.com/cirKITers/qml-essentials"
|
|
27
27
|
url: "https://cirkiters.github.io/qml-essentials"
|
|
28
28
|
license: MIT
|
|
29
29
|
identifiers:
|
|
30
30
|
- type: doi
|
|
31
31
|
value: 10.1109/QSW67625.2025.00035
|
|
32
|
+
- type: doi
|
|
33
|
+
value: 10.1109/QSW72780.2026.00017
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: qml-essentials
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.3
|
|
4
4
|
Summary: A toolbox to make working with QML models easier.
|
|
5
5
|
Project-URL: Homepage, https://cirkiters.github.io/qml-essentials/
|
|
6
6
|
Project-URL: Repository, https://github.com/cirKITers/qml-essentials
|
|
@@ -18,9 +18,10 @@ Classifier: Programming Language :: Python :: 3
|
|
|
18
18
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
19
19
|
Classifier: Programming Language :: Python :: 3.12
|
|
20
20
|
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
21
22
|
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
22
|
-
Requires-Python: <3.
|
|
23
|
-
Requires-Dist: jaqsi>=0.1.
|
|
23
|
+
Requires-Python: <3.15,>=3.12
|
|
24
|
+
Requires-Dist: jaqsi>=0.1.2
|
|
24
25
|
Requires-Dist: jax>=0.9.0.1
|
|
25
26
|
Requires-Dist: jaxlib>=0.9.0.1
|
|
26
27
|
Requires-Dist: numpy>=2.0.0
|
|
@@ -20,7 +20,7 @@ To get an overview of all the available Ansaetze, checkout the [references](http
|
|
|
20
20
|
## Custom Ansatz
|
|
21
21
|
|
|
22
22
|
For building the different Ansatzes, we use topology patterns defined in `qml_essentials.topologies`.
|
|
23
|
-
|
|
23
|
+
Five patterns are available: `Topology.stairs` (a configurable chain of entangling gates), `Topology.bricks` (a brick-wall pattern), `Topology.all_to_all` (every ordered qubit pair), `Topology.all_pairs` (every unordered qubit pair) and `Topology.graph` (an explicit edge list).
|
|
24
24
|
Several built-in circuits rely on them, e.g. Circuit_5 uses `all_to_all` and Circuit_7 uses `bricks`.
|
|
25
25
|
You can find a list of all the available topologies in the [references](https://cirkiters.github.io/qml-essentials/references/) as well.
|
|
26
26
|
|
|
@@ -87,7 +87,7 @@ You might have noticed that we choose our sampling frequency `fs` in such a way,
|
|
|
87
87
|
Also the number of samples `x` are just enough to sufficiently represent our function.
|
|
88
88
|
In such a simplified scenario, this is fine, but there are cases, where we want to have more information both in the time and frequency domain.
|
|
89
89
|
Therefore, two additional arguments exist in the `get_spectrum` method:
|
|
90
|
-
- `mfs`: The multiplier for the highest frequency. Increasing this will increase the width of the spectrum
|
|
90
|
+
- `mfs`: The multiplier for the highest frequency. Increasing this will increase the width of the spectrum, either globally or per input feature (see below)
|
|
91
91
|
- `mts`: The multiplier for the number of time samples. Increasing this will increase the resolution of the time domain and therefore "add" frequencies in between our original frequencies.
|
|
92
92
|
- `trim`: Whether to remove the Nyquist frequency if spectrum is even. This will result in a symmetric spectrum
|
|
93
93
|
|
|
@@ -285,9 +285,45 @@ Using a logarithmic color bar, one obtains the following 2D-spectrum:
|
|
|
285
285
|
|
|
286
286
|
Note that "X1" refers to the "RX" encoding and "X2" to the "RY" encoding.
|
|
287
287
|
|
|
288
|
-
In the multidimensional case,
|
|
288
|
+
In the multidimensional case, `freqs` is a list with one frequency vector per input feature, independent of `shift`.
|
|
289
289
|
This is an important detail, as due to the `data_reupload` argument, it is possible to have a different number of frequencies for each input dimension.
|
|
290
290
|
|
|
291
|
+
### Ragged frequency grids
|
|
292
|
+
|
|
293
|
+
In the multidimensional case, the per-axis degrees, and therefore the per-axis frequency grids, do not have to match: due to the `data_reupload` argument, each input feature can be encoded on a different number of wires, which is the generic case rather than an edge case.
|
|
294
|
+
|
|
295
|
+
The full pipeline, i.e. `Coefficients.get_spectrum` as well as `FCC.get_fcc` and `FCC.get_fourier_fingerprint`, supports these *ragged* frequency grids:
|
|
296
|
+
|
|
297
|
+
```python
|
|
298
|
+
model = Model(
|
|
299
|
+
n_qubits=2,
|
|
300
|
+
n_layers=2,
|
|
301
|
+
circuit_type="Circuit_19",
|
|
302
|
+
encoding=["RX", "RY"],
|
|
303
|
+
data_reupload=[
|
|
304
|
+
[[True, True], [False, True]],
|
|
305
|
+
[[False, True], [True, True]],
|
|
306
|
+
],
|
|
307
|
+
)
|
|
308
|
+
# model.degree == (5, 9)
|
|
309
|
+
|
|
310
|
+
coeffs, freqs = Coefficients.get_spectrum(model)
|
|
311
|
+
# coeffs reshapes to one axis per input feature; freqs holds one
|
|
312
|
+
# frequency vector per axis with different lengths
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
The coefficients follow the ij/C-order convention: one axis per input feature with the first feature being the slowest, and the per-coefficient frequency tuples use the same order.
|
|
316
|
+
|
|
317
|
+
Oversampling can also be applied per axis, by passing `mfs` either as a single factor (applied to every feature) or as one factor per feature:
|
|
318
|
+
|
|
319
|
+
```python
|
|
320
|
+
coeffs, freqs = Coefficients.get_spectrum(model, mfs=[1, 2])
|
|
321
|
+
# grid of shape (5, 18)
|
|
322
|
+
```
|
|
323
|
+
|
|
324
|
+
A list with the wrong length raises a `ValueError`.
|
|
325
|
+
Similarly, `trim` removes the Nyquist entry of each even-length axis at that axis's own position.
|
|
326
|
+
|
|
291
327
|
## Fourier Coefficient Correlation (FCC)
|
|
292
328
|
|
|
293
329
|
The FCC, as introduced in [Fourier Fingerprints of Ansatzes in Quantum Machine Learning](https://doi.org/10.48550/arXiv.2508.20868), is a metric that aims to predict the expected performance of an arbitrary Ansatz based on the the correlation between its Fourier modes.
|
|
@@ -44,6 +44,46 @@ ent_cap = Entanglement.bell_measurements(
|
|
|
44
44
|
)
|
|
45
45
|
```
|
|
46
46
|
|
|
47
|
+
## Mean Negativity
|
|
48
|
+
|
|
49
|
+
For pure and mixed states, `mean_negativity` averages the negativity across each qubit-versus-rest partition and normalizes the result to $[0,1]$:
|
|
50
|
+
|
|
51
|
+
$$
|
|
52
|
+
\overline{\mathcal{N}}(\rho)=\frac{2}{n}\sum_{k=0}^{n-1}\mathcal{N}_k(\rho),
|
|
53
|
+
\qquad
|
|
54
|
+
\mathcal{N}_k(\rho)=\frac{\|\rho^{T_k}\|_1-1}{2}.
|
|
55
|
+
$$
|
|
56
|
+
|
|
57
|
+
Here $T_k$ denotes the partial transpose on qubit $k$. Each negativity is the sum of the absolute values of the negative eigenvalues of $\rho^{T_k}$, following [Vidal and Werner](https://arxiv.org/abs/quant-ph/0102117).
|
|
58
|
+
|
|
59
|
+
```python
|
|
60
|
+
ent_cap = Entanglement.mean_negativity(
|
|
61
|
+
model, n_samples=1000, random_key=jax.random.key(1000), noise_params={"BitFlip": 0.1}
|
|
62
|
+
)
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
You can compute the mean logarithmic negativity instead by setting `log=True`:
|
|
66
|
+
|
|
67
|
+
```python
|
|
68
|
+
ent_cap = Entanglement.mean_negativity(model, n_samples=None, log=True)
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
$$
|
|
72
|
+
\overline{E}_{\mathcal{N}}(\rho)=\frac{1}{n}\sum_{k=0}^{n-1}\log_2(1+2\mathcal{N}_k(\rho)).
|
|
73
|
+
$$
|
|
74
|
+
|
|
75
|
+
The logarithm is applied to each partition of each output state before averaging.
|
|
76
|
+
Note that this generally differs from taking $\log_2(1+\overline{\mathcal{N}})$ after averaging (hence this flag).
|
|
77
|
+
|
|
78
|
+
The method averages the metric over the output states, rather than evaluating their averaged density matrix.
|
|
79
|
+
Set `n_samples=None` or a nonpositive value to use the current parameters.
|
|
80
|
+
If `scale` is set to `True`, the sample count is multiplied by $2^n$.
|
|
81
|
+
|
|
82
|
+
Fully separable states give zero, while Bell and GHZ states give one.
|
|
83
|
+
Note that, this metric differs from Meyer-Wallach even for pure states as zero does not exclude entanglement with positive partial transpose (PPT), according to the [Separability Criterion for Density Matrices](https://doi.org/10.1103/PhysRevLett.77.1413).
|
|
84
|
+
In contrast, a positive value, does not establish genuine multipartite entanglement.
|
|
85
|
+
|
|
86
|
+
This metric allows to be used in a noisy and noiseless setting.
|
|
47
87
|
## Relative Entropy
|
|
48
88
|
|
|
49
89
|
While calculating entanglement using the Meyer-Wallach or Bell-Measurements method works great for noiseless circuits, it won't result in the correct values when being used together with incoherent noise.
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "qml-essentials"
|
|
3
|
-
version = "0.3.
|
|
3
|
+
version = "0.3.3"
|
|
4
4
|
description = "A toolbox to make working with QML models easier."
|
|
5
5
|
authors = [
|
|
6
6
|
{ name = "Melvin Strobl", email = "melvin.strobl@kit.edu" },
|
|
7
7
|
{ name = "Maja Franz", email = "maja.franz@oth-regensburg.de" },
|
|
8
8
|
]
|
|
9
|
-
requires-python = ">=3.12,<3.
|
|
9
|
+
requires-python = ">=3.12,<3.15"
|
|
10
10
|
readme = "README.md"
|
|
11
11
|
license = "MIT"
|
|
12
12
|
maintainers = [{ name = "Melvin Strobl", email = "melvin.strobl@kit.edu" }]
|
|
@@ -14,9 +14,9 @@ keywords = [
|
|
|
14
14
|
"quantum",
|
|
15
15
|
"quantum machine learning",
|
|
16
16
|
"qml",
|
|
17
|
-
]
|
|
17
|
+
]
|
|
18
18
|
dependencies = [
|
|
19
|
-
"jaqsi>=0.1.
|
|
19
|
+
"jaqsi>=0.1.2",
|
|
20
20
|
"jax>=0.9.0.1",
|
|
21
21
|
"jaxlib>=0.9.0.1",
|
|
22
22
|
"numpy>=2.0.0",
|
|
@@ -30,6 +30,7 @@ classifiers = [
|
|
|
30
30
|
"Programming Language :: Python :: 3",
|
|
31
31
|
"Programming Language :: Python :: 3.12",
|
|
32
32
|
"Programming Language :: Python :: 3.13",
|
|
33
|
+
"Programming Language :: Python :: 3.14",
|
|
33
34
|
"Programming Language :: Python :: 3 :: Only",
|
|
34
35
|
"Topic :: Scientific/Engineering :: Physics",
|
|
35
36
|
]
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
from abc import ABC, abstractmethod
|
|
2
|
+
import functools
|
|
2
3
|
from typing import Any, Optional, List, Union, Callable, Tuple
|
|
3
4
|
import jax.numpy as np
|
|
4
5
|
import logging
|
|
@@ -1000,6 +1001,18 @@ def GolombEncoding(
|
|
|
1000
1001
|
UnitaryGates.Noise(wires_list, noise_params)
|
|
1001
1002
|
|
|
1002
1003
|
|
|
1004
|
+
# Encoding wrappers live at module level,
|
|
1005
|
+
# so that a model holding them can be pickled.
|
|
1006
|
+
def _scaled_encoding(inputs, wires, *, enc, base, **kwargs):
|
|
1007
|
+
"""Apply `enc` with the input scaled by ``base**wires``."""
|
|
1008
|
+
return enc(inputs * (base**wires), wires, **kwargs)
|
|
1009
|
+
|
|
1010
|
+
|
|
1011
|
+
def _golomb_encoding(inputs, wires, **kwargs):
|
|
1012
|
+
# `wires` here is a list of all qubit indices, set by _iec
|
|
1013
|
+
GolombEncoding(w=inputs, wires=wires, **kwargs)
|
|
1014
|
+
|
|
1015
|
+
|
|
1003
1016
|
class Encoding:
|
|
1004
1017
|
def __init__(
|
|
1005
1018
|
self, strategy: str, gates: Union[str, Callable, List[Union[str, Callable]]]
|
|
@@ -1199,10 +1212,7 @@ class Encoding:
|
|
|
1199
1212
|
The wrapped encoding function.
|
|
1200
1213
|
"""
|
|
1201
1214
|
|
|
1202
|
-
|
|
1203
|
-
return enc(inputs * (2**wires), wires, **kwargs)
|
|
1204
|
-
|
|
1205
|
-
return _enc
|
|
1215
|
+
return functools.partial(_scaled_encoding, enc=enc, base=2)
|
|
1206
1216
|
|
|
1207
1217
|
def ternary(self, enc):
|
|
1208
1218
|
"""
|
|
@@ -1224,10 +1234,7 @@ class Encoding:
|
|
|
1224
1234
|
The wrapped encoding function.
|
|
1225
1235
|
"""
|
|
1226
1236
|
|
|
1227
|
-
|
|
1228
|
-
return enc(inputs * (3**wires), wires, **kwargs)
|
|
1229
|
-
|
|
1230
|
-
return _enc
|
|
1237
|
+
return functools.partial(_scaled_encoding, enc=enc, base=3)
|
|
1231
1238
|
|
|
1232
1239
|
@property
|
|
1233
1240
|
def is_golomb(self):
|
|
@@ -1262,8 +1269,4 @@ class Encoding:
|
|
|
1262
1269
|
functions but that applies :func:`GolombEncoding`.
|
|
1263
1270
|
"""
|
|
1264
1271
|
|
|
1265
|
-
|
|
1266
|
-
# `wires` here is a list of all qubit indices, set by _iec
|
|
1267
|
-
GolombEncoding(w=inputs, wires=wires, **kwargs)
|
|
1268
|
-
|
|
1269
|
-
return _enc
|
|
1272
|
+
return _golomb_encoding
|