-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* switch to extensions from Requires * require julia 1.9 * bump version * update README and improve complexity printing
- Loading branch information
Showing
9 changed files
with
142 additions
and
148 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
@misc{Liu2022, | ||
doi = {10.48550/ARXIV.2205.03718}, | ||
url = {https://arxiv.org/abs/2205.03718}, | ||
author = {Liu, Jin-Guo and Gao, Xun and Cain, Madelyn and Lukin, Mikhail D. and Wang, Sheng-Tao}, | ||
keywords = {Statistical Mechanics (cond-mat.stat-mech), FOS: Physical sciences, FOS: Physical sciences}, | ||
title = {Computing solution space properties of combinatorial optimization problems via generic tensor networks}, | ||
publisher = {arXiv}, | ||
year = {2022}, | ||
copyright = {Creative Commons Attribution 4.0 International} | ||
} | ||
@misc{Pan2021, | ||
title={Simulating the Sycamore quantum supremacy circuits}, | ||
author={Feng Pan and Pan Zhang}, | ||
year={2021}, | ||
eprint={2103.03074}, | ||
archivePrefix={arXiv}, | ||
primaryClass={quant-ph} | ||
} | ||
@Article{10.21468/SciPostPhys.7.5.060, | ||
title={{Fast counting with tensor networks}}, | ||
author={Stefanos Kourtis and Claudio Chamon and Eduardo R. Mucciolo and Andrei E. Ruckenstein}, | ||
journal={SciPost Phys.}, | ||
volume={7}, | ||
issue={5}, | ||
pages={60}, | ||
year={2019}, | ||
publisher={SciPost}, | ||
doi={10.21468/SciPostPhys.7.5.060}, | ||
url={https://scipost.org/10.21468/SciPostPhys.7.5.060}, | ||
} | ||
@article{Gray2021, | ||
title={Hyper-optimized tensor network contraction}, | ||
volume={5}, | ||
ISSN={2521-327X}, | ||
url={http://dx.doi.org/10.22331/q-2021-03-15-410}, | ||
DOI={10.22331/q-2021-03-15-410}, | ||
journal={Quantum}, | ||
publisher={Verein zur Forderung des Open Access Publizierens in den Quantenwissenschaften}, | ||
author={Gray, Johnnie and Kourtis, Stefanos}, | ||
year={2021}, | ||
month={Mar}, | ||
pages={410} | ||
} | ||
@misc{kalachev2021recursive, | ||
title={Recursive Multi-Tensor Contraction for XEB Verification of Quantum Circuits}, | ||
author={Gleb Kalachev and Pavel Panteleev and Man-Hong Yung}, | ||
year={2021}, | ||
eprint={2108.05665}, | ||
archivePrefix={arXiv}, | ||
primaryClass={quant-ph} | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,35 @@ | ||
name = "OMEinsumContractionOrders" | ||
uuid = "6f22d1fd-8eed-4bb7-9776-e7d684900715" | ||
authors = ["Jin-Guo Liu", "Pan Zhang"] | ||
version = "0.8.2" | ||
version = "0.8.3" | ||
|
||
[deps] | ||
AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c" | ||
BetterExp = "7cffe744-45fd-4178-b173-cf893948b8b7" | ||
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6" | ||
Requires = "ae029012-a4dd-5104-9daa-d747884805df" | ||
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" | ||
Suppressor = "fd094767-a336-5f1f-9728-57cf17d0bbfb" | ||
|
||
[weakdeps] | ||
KaHyPar = "2a6221f6-aa48-11e9-3542-2d9e0ef01880" | ||
|
||
[extensions] | ||
KaHyParExt = ["KaHyPar"] | ||
|
||
[compat] | ||
AbstractTrees = "0.3, 0.4" | ||
BetterExp = "0.1" | ||
JSON = "0.21" | ||
Requires = "1" | ||
KaHyPar = "0.3" | ||
Suppressor = "0.2" | ||
julia = "1" | ||
julia = "1.9" | ||
|
||
[extras] | ||
Graphs = "86223c79-3864-5bf0-83f7-82e725a168b6" | ||
KaHyPar = "2a6221f6-aa48-11e9-3542-2d9e0ef01880" | ||
OMEinsum = "ebe7aa44-baf0-506c-a96f-8464559b3922" | ||
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" | ||
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" | ||
TropicalNumbers = "b3a74e9c-7526-4576-a4eb-79c0d4c32334" | ||
|
||
[targets] | ||
test = ["Test", "Random", "KaHyPar", "Graphs", "TropicalNumbers", "OMEinsum"] | ||
test = ["Test", "Random", "Graphs", "TropicalNumbers", "OMEinsum", "KaHyPar"] |
This file contains 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
module KaHyParExt | ||
|
||
using OMEinsumContractionOrders: KaHyParBipartite, SparseMatrixCSC, group_sc, induced_subhypergraph, convert2int | ||
import KaHyPar | ||
import OMEinsumContractionOrders: bipartite_sc | ||
using Suppressor: @suppress | ||
|
||
function bipartite_sc(bipartiter::KaHyParBipartite, adj::SparseMatrixCSC, vertices, log2_sizes) | ||
n_v = length(vertices) | ||
subgraph, remaining_edges = induced_subhypergraph(adj, vertices) | ||
hypergraph = KaHyPar.HyperGraph(subgraph, ones(n_v), convert2int(log2_sizes[remaining_edges])) | ||
local parts | ||
min_sc = 999999 | ||
for imbalance in bipartiter.imbalances | ||
parts = @suppress KaHyPar.partition(hypergraph, 2; imbalance=imbalance, configuration=:edge_cut) | ||
part0 = vertices[parts .== 0] | ||
part1 = vertices[parts .== 1] | ||
sc0, sc1 = group_sc(adj, part0, log2_sizes), group_sc(adj, part1, log2_sizes) | ||
sc = max(sc0, sc1) | ||
min_sc = min(sc, min_sc) | ||
@debug "imbalance $imbalance: sc = $sc, group = ($(length(part0)), $(length(part1)))" | ||
if sc <= bipartiter.sc_target | ||
return part0, part1 | ||
end | ||
end | ||
error("fail to find a valid partition for `sc_target = $(bipartiter.sc_target)`, got minimum value `$min_sc` (imbalances = $(bipartiter.imbalances))") | ||
end | ||
|
||
@info "`OMEinsumContractionOrders` loads `KaHyParExt` extension successfully." | ||
end |
This file contains 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 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 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 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 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