Skip to content
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

SymbolicHamiltonian refactor #1548

Merged
merged 34 commits into from
Feb 12, 2025
Merged
Show file tree
Hide file tree
Changes from 31 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
dcbb156
feat: removed terms and dense setter
BrunoLiegiBastonLiegi Dec 18, 2024
d49ce6c
feat: adapting hamiltonian
BrunoLiegiBastonLiegi Dec 18, 2024
49ea30b
feat: patching hamiltonian/models to build starting from forms
BrunoLiegiBastonLiegi Dec 18, 2024
083ebba
fix: some fixes for tests
BrunoLiegiBastonLiegi Dec 18, 2024
0689938
fix: some further fixes
BrunoLiegiBastonLiegi Dec 18, 2024
6fb5270
fix: fixing the form of some H models
BrunoLiegiBastonLiegi Dec 19, 2024
f86c084
Merge branch 'master' into remove_hamiltonian_terms_setter
BrunoLiegiBastonLiegi Dec 19, 2024
eceb413
fix: some fixes to _compose
BrunoLiegiBastonLiegi Dec 19, 2024
f80f402
fix: add missing _check_backend
BrunoLiegiBastonLiegi Dec 19, 2024
74bc480
feat: using indices in _dense_from_terms + check that form is sympy
BrunoLiegiBastonLiegi Dec 19, 2024
6cc8435
feat: made dense_from_terms backend aware + some comments
BrunoLiegiBastonLiegi Dec 19, 2024
977d8b5
feat: added backend to symbols + refactor maxcut
BrunoLiegiBastonLiegi Jan 10, 2025
febf76b
fix: removed cache files
BrunoLiegiBastonLiegi Jan 10, 2025
ac0d9aa
feat: made symbolicterm backend aware
BrunoLiegiBastonLiegi Jan 10, 2025
86dc4b7
fix: fix to symb ham terms
BrunoLiegiBastonLiegi Jan 10, 2025
0f5f66e
feat: replaced loop with einsum in sym term matrix
BrunoLiegiBastonLiegi Jan 10, 2025
318cae3
feat: removed unnecessary cast
BrunoLiegiBastonLiegi Jan 12, 2025
e461f96
fix: adding backend here and there
BrunoLiegiBastonLiegi Jan 13, 2025
80bf3f7
feat: symbolic term forces the backend of its symbols
BrunoLiegiBastonLiegi Jan 13, 2025
1b34d33
fix: removed calcterms/calcdense tests
BrunoLiegiBastonLiegi Jan 13, 2025
4d8c9c1
fix: minor adjustments
BrunoLiegiBastonLiegi Jan 13, 2025
ff26b76
feat: minor optimizations: reintroduced reduce and using cache
BrunoLiegiBastonLiegi Jan 14, 2025
feb98a1
fix: minor fix
BrunoLiegiBastonLiegi Jan 14, 2025
29a010e
fix: restored tol for tsp test
BrunoLiegiBastonLiegi Jan 14, 2025
5dc3159
fix: replaced another einsum
BrunoLiegiBastonLiegi Jan 14, 2025
1216b5a
feat: added a more comprehensice test for to dense
BrunoLiegiBastonLiegi Jan 14, 2025
6d7648a
Merge branch 'master' into remove_hamiltonian_terms_setter
BrunoLiegiBastonLiegi Feb 5, 2025
8087c58
build: using qibojit branch
BrunoLiegiBastonLiegi Feb 6, 2025
e80c0c7
feat: some fixes
BrunoLiegiBastonLiegi Feb 6, 2025
73d2686
Update src/qibo/hamiltonians/hamiltonians.py
BrunoLiegiBastonLiegi Feb 6, 2025
415d98a
Merge branch 'master' into remove_hamiltonian_terms_setter
BrunoLiegiBastonLiegi Feb 7, 2025
617788e
fix: apply suggestions
BrunoLiegiBastonLiegi Feb 12, 2025
bf50e99
fix: changed qibojit dep + reverted a previous change
BrunoLiegiBastonLiegi Feb 12, 2025
3544ebe
fix: removed commented einsum implementations
BrunoLiegiBastonLiegi Feb 12, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 12 additions & 17 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ ipython = "^8.10.0"
qulacs = { version = "^0.6.4", markers = "(sys_platform == 'darwin' and python_version > '3.9') or sys_platform != 'darwin'" }
seaborn = "^0.13.2"
ipykernel = "^6.29.4"
qibojit = { git = "https://github.com/qiboteam/qibojit.git"}
qibojit = { git = "https://github.com/qiboteam/qibojit.git", branch = "cupy_identity_matrix"}

[tool.poetry.group.tests]
optional = true
Expand All @@ -70,7 +70,7 @@ pytest-cov = "^4.0.0"
pylint = "3.1.0"
matplotlib = "^3.7.0"
torch = "^2.1.1,<2.4"
qibojit = { git = "https://github.com/qiboteam/qibojit.git"}
qibojit = { git = "https://github.com/qiboteam/qibojit.git", branch = "cupy_identity_matrix"}
qibotn = { git = "https://github.com/qiboteam/qibotn.git" }
qiboml = { git = "https://github.com/qiboteam/qiboml.git" }
stim = "^1.12.0"
Expand All @@ -91,7 +91,7 @@ optional = true
[tool.poetry.group.cuda11.dependencies]
cupy-cuda11x = "^13.1.0"
cuquantum-python-cu11 = "^23.3.0"
qibojit = { git = "https://github.com/qiboteam/qibojit.git" }
qibojit = { git = "https://github.com/qiboteam/qibojit.git", branch = "cupy_identity_matrix" }
qibotn = { git = "https://github.com/qiboteam/qibotn.git" }


Expand All @@ -101,7 +101,7 @@ optional = true
[tool.poetry.group.cuda12.dependencies]
cupy-cuda12x = "^13.1.0"
cuquantum-python-cu12 = "^23.3.0"
qibojit = { git = "https://github.com/qiboteam/qibojit.git"}
qibojit = { git = "https://github.com/qiboteam/qibojit.git", branch = "cupy_identity_matrix"}
qibotn = { git = "https://github.com/qiboteam/qibotn.git" }

[tool.poetry.extras]
Expand Down
6 changes: 1 addition & 5 deletions src/qibo/hamiltonians/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,2 @@
from qibo.hamiltonians.hamiltonians import (
Hamiltonian,
SymbolicHamiltonian,
TrotterHamiltonian,
)
from qibo.hamiltonians.hamiltonians import Hamiltonian, SymbolicHamiltonian
from qibo.hamiltonians.models import TFIM, XXX, XXZ, Heisenberg, MaxCut, X, Y, Z
Loading