-
-
Notifications
You must be signed in to change notification settings - Fork 47
✨ Implement two-qubit gate decomposition pass #1206
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
Draft
taminob
wants to merge
163
commits into
main
Choose a base branch
from
taminob/mlir-two-qubit-gate-decomposition-pass
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
163 commits
Select commit
Hold shift + click to select a range
20404bc
snapshot
taminob 8fd23f6
copied rust code
taminob 5e806f6
🎨 pre-commit fixes
pre-commit-ci[bot] 70082d8
snapshot
taminob debe427
snapshot
taminob b86844b
snapshot
taminob e4dec47
minor additions
taminob 9ce8ac3
add pass to Passes.td
taminob f45107b
snapshot
taminob 81e6230
compiling snapshot
taminob 588db20
tmp
taminob 84fa825
switch to long double
taminob 3dd1266
testing a.cpp
taminob 3c214ad
add zgemm for testing, start euler decomposition implementation
taminob 62aa918
non-working but finished snapshot
taminob eec099c
fix out-of-bounds issues
taminob b1a4286
test using Armadillo
taminob cee23a7
minor fix
taminob 5550adc
tmp
taminob b541500
work on gate application
taminob 0b80624
use laughing-umbrella implementation for decompose_two_qubit_product_…
taminob 299d6f1
add more eigen decomposition implementations
taminob 96b39ad
work on applySeries()
taminob 3947566
Revert "use laughing-umbrella implementation for decompose_two_qubit_…
taminob ab188ae
fix transpose_conjugate
taminob 410fadd
add test
taminob 05885a1
actually kind of working snapshot?
taminob c87b02a
fix test case
taminob 619d0d6
minor fix
taminob a998ef7
fix test case
taminob 71420a2
add new test, fix tests
taminob bd8cdbd
iniital complexSeries test
taminob 85b03c2
use Eigen for multiply() and determinant()
taminob 0de0b43
fix gate matrix multiplication
taminob cc9f1be
add simple (too simple) series complexity
taminob 13721df
fix insertion when operations which are not part of the series are in…
taminob 6305604
add gate matrices
taminob dd130b9
sequence complexity()
taminob fb742d8
print debugging :)
taminob e6840d4
longer complex test to pass sequence complexity check
taminob 08e1991
use CXGate() definition for decomposer
taminob 0e6ff8e
add cnot test other direction
taminob 5814ade
tmp (to be deleted)
taminob 70d604e
re-write using Eigen
taminob a5dead7
delete pulse-optimizer code (KEEP for future; should be re-added at s…
taminob 5aeb866
use designated initializer lists
taminob 0714745
fix warnings, rename all variables
taminob 579b6e8
test normalized magic basis, allow complex eigenvector decomposition
taminob 7ca5341
finally figured some stuff out
taminob e1548d2
try out lauging-umbrella weyl-chamber
taminob 9dfd453
try to implement weylchamber.c1c2c3 algorithm
taminob e78b4f3
on_gates two-qubit product decompose
taminob cf9d649
minor additions
taminob c02bfa6
try ordering all four eigenvectors
taminob 3a800c6
undo ordering of all columns
taminob c155100
implement algorithm based on quantumflow.canonical_decomposition
taminob b6ff17f
sanity checks and stuff
taminob 83c089e
add original implementation again which seems to kind of work?
taminob a94195f
generate openqasm code of generated sequence
taminob ab57b7d
some more small fixes, maybe breakthrough?
taminob af6f411
rework getTwoQubitSeries logic
taminob 8a9447b
generate openqasm code of found series
taminob e4b68d1
fix new getTwoQubitSeries logic
taminob 1eea4af
working except global phase?
taminob bb4b796
fix global phase issues
taminob 837363f
first working snapshot
taminob 2582c66
very minor cleanup
taminob 8ec690b
add more sanity checks for unitary
taminob e26a374
find and fix minor formula mistake
taminob bc1475e
test update
taminob 4048bf6
make calculations exact without approximation
taminob cff036c
respect gphase of circuit and fix series collection bug
taminob 21701e8
change global phase to local phase
taminob 85c1f86
revert to global phase, fix controlled gate qubit order
taminob 9c0ecb4
fix first couple of tests
taminob 00986dd
start working on basis set and remove dead code
taminob bcaf798
decompose for all bases, choose best
taminob 83868c0
add checks for most tests
taminob b16bc9a
TMP, needs to be removed; allow OpenQASM export with round-trip pass
taminob 8cdce44
add single-qubit backtracking
taminob e919bcd
fix atol issues
taminob 1f91271
add more euler bases to pattern
taminob d4f1b49
minor cleanup (renaming, comments, disable printing)
taminob 5620b9e
Revert "TMP, needs to be removed; allow OpenQASM export with round-tr…
taminob 82ba25d
remove armadillo in cmake
taminob 3d1dc8a
more cleanup
taminob 1eeedba
fix (?) tests
taminob 3afb374
fix final test
taminob 17b02c5
another minor cleanup
taminob ca9c9f1
clean sanity check prints up
taminob 0174a3d
properly add Eigen lib to cmake
taminob 3c70713
remove unnecessary correction
taminob 9f645a0
🎨 pre-commit fixes
pre-commit-ci[bot] b8f6b0b
fix eigen compilation issues
taminob 5cd8ca4
more cleanup
taminob 412a829
clean up weyl decomposition creation
taminob 6f04dbb
remove openqasm code generation
taminob eac38de
fix includes and use SmallVector instead of std::vector
taminob 4ea3120
fix or silence linter
taminob 0cf2292
incorporate coderabbitai feedback
taminob b4d419c
remove global phase accumulation
taminob 75672af
fix :math: latex formatting
taminob fe08c78
minor comment fixes
taminob 5128d83
replace CHECK-DAG by CHECK again
taminob 9194ae9
add comments to weyl decomposition
taminob ac4fb41
extract TwoQubitWeylDecomposition::getTrace()
taminob 56a2990
transform basis decomposer into actual class with private members
taminob 76ca4d0
attempt to fix CI test
taminob ec7f8c3
add supercontrolled check
taminob 49a769a
extract decomposition into headers
taminob 910384e
slight improvement to weyl decomposition for testing purposes
taminob 4c42850
add unittest for weyl decomposition
taminob 3453d2c
fix linter issues
taminob 7f0d1f6
add tests for basis decomposer
taminob e904dc1
fix linter issues
taminob c586338
clang-tidy: Add IgnoreHeader for include cleaner for Eigen
taminob f2efbcb
remove exact values from MLIR test
taminob 78daaba
fix mlir test/linter issues
taminob 741660e
remove std::numbers because not supported by all compilers in CI
taminob 9a6c691
remove unused Helpers.h from src dir
taminob ad8da23
remove auto* because of windows build
taminob 1e89778
try to fix windows ARM ci
taminob 854d9a0
pass matrices by reference
taminob 25b377d
allow non-optimal vectorization
taminob cd8ae96
🎨 pre-commit fixes
pre-commit-ci[bot] 2f634f5
try to fix
taminob f9b033d
integrate single-qubit decomposition
taminob aaab4b8
add tests for single-qubit decomposition
taminob fa78cbb
add unittests for euler decomposition
taminob d103e7a
fix linter issues
taminob 7fc31ae
fix include cleaner issues
taminob 43e9d31
add test parametrizations for other specializations
taminob 95424ee
add more matrix definitions
taminob a5c54e6
handle barrier gates in series collection
taminob aa3212d
🎨 pre-commit fixes
pre-commit-ci[bot] 474a5d9
fix include cleaner issues
taminob 21e9b7b
remove unused globalPhase from TwoQubitSeries
taminob 6815b26
fix barrier handling at start of series
taminob 202fa7f
simplify weyl specialization test parameters
taminob 49a60a7
remove dynamic_casts due to RTTI issue
taminob 8fc3b53
Revert "remove dynamic_casts due to RTTI issue"
taminob 68890af
move GateDecompositionPass to new QCO dialect
taminob 9a7006b
add GateDecompositionPass to compiler pipeline
taminob 935ad7d
🎨 pre-commit fixes
pre-commit-ci[bot] d296638
add UnitaryMatrixType to operation and add Eigen dependency to dialect
taminob a8dbfcb
first non-working attempt
taminob e9da9b0
second non-working attempt
taminob 5b325a5
compiling approach
taminob b3161cc
formatting
taminob 01886fb
avoid use of implementation-dependent argument names
taminob 30198a9
finally got template function working
taminob 1c7dd1d
add to compiler pipeline and add (failing) test case
taminob a8fbec2
make unitary function const, remove HasMatrixDefinition bool template…
taminob f9f7f04
start working on ctrl matrix
taminob d8d7b19
use new unitary matrix functions in GateDecompositionPattern
taminob ce79ed2
add debug prints
taminob 6c965ed
🎨 pre-commit fixes
pre-commit-ci[bot] 1588388
add helpers for CtrlOp matrix
taminob 00491d7
add matrix definition to all operations
taminob 69ebd05
fixes for unitary matrix definition
taminob df22236
fixes for gate decomposition pattern
taminob 31f4a02
fix formatting in MatrixUtils.h
taminob 9e2e0e6
(dirty) fix for CtrlOp in gate decomposition pattern; runs, but SSA e…
taminob File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.