You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As a rule of thumb, for circuit with qubit count larger than 16 and circuit depth larger than 8, customized contraction may outperform the deafult built-in greedy contraction strategy.
47
+
48
+
To setup or not setup the customized contractor is about a trade-off between the time on contraction path finding and the time on the real contraction via matmul.
49
+
50
+
The customized contractor cost much more time than default contractor in terms of contraction path searching, and via the path it finds, the real contraction can take less time and space.
51
+
52
+
If the circuit simulation time is the bottleneck of the whole workflow, one can always try customized contractor to see whether there is some performance improvement.
53
+
54
+
We recommend to use `cotengra library <https://cotengra.readthedocs.io/en/latest/index.html>`_ to setup the contractor, since there are lots of interesting hyperparameters to tune, we can achieve better trade-off between the time on contraction path search and the time on the real tensor network contraction.
55
+
56
+
It is also worth noting that for jitted function which we usually use, the contraction path search is only called at the first run of the function, which further amortize the time and favor the use of highly customized contractor.
57
+
58
+
In terms of how-to on contractor setup, please refer to :ref:`quickstart:Setup the Contractor`.
43
59
44
60
Is there some API less cumbersome than ``expectation`` for Pauli string?
0 commit comments