Skip to content

Commit 219e984

Browse files
update cite
1 parent 925d9b5 commit 219e984

File tree

2 files changed

+21
-6
lines changed

2 files changed

+21
-6
lines changed

tensorcircuit/about.py

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
Prints the information for tensorcircuit installation and environment.
33
"""
44

5+
# pylint: disable=line-too-long
6+
57
import platform
68
import sys
79
import numpy
@@ -155,10 +157,18 @@ def cite(format: str = "bib") -> str:
155157
month = feb,
156158
title = {{TensorCircuit: a Quantum Software Framework for the NISQ Era}},
157159
volume = {7},
158-
year = {2023}}"""
160+
year = {2023}}
161+
162+
@article{Zhang_TensorCircuitNG_2026,
163+
author = {Zhang, Shi-Xin and Chen, Yu-Qin and Li, Weitang and Sun, Jiace and Ma, Wei-Guo and Zheng, Pei-Lin and Huang, Yu-Xiang and Wang, Qi-Xiang and Yu, Hui and Li, Zhuo and Huang, Xuyang and Li, Zong-Liang and Wan, Zhou-Quan and Liu, Shuo and Qiu, Jiezhong and Miao, Jiaqi and Song, Zixuan and Yan, Yuxuan and Tsuoka, Kazuki and Zhang, Pan and Wang, Lei and Fan, Heng and Hsieh, Chang-Yu and Yao, Hong and Xiang, Tao},
164+
doi = {10.48550/arXiv.2602.14167},
165+
journal = {arXiv preprint arXiv:2602.14167},
166+
title = {{TensorCircuit-NG: A Universal, Composable, and Scalable Platform for Quantum Computing and Quantum Simulation}},
167+
year = {2026}}"""
159168
elif format == "aps":
160-
return """S.-X. Zhang, J. Allcock, Z.-Q. Wan, S. Liu, J. Sun, H. Yu, X.-H. Yang, J. Qiu, Z. Ye, Y.-Q. Chen, C.-K. Lee, Y.-C. Zheng, S.-K. Jian, H. Yao, C.-Y. Hsieh, and S. Zhang, TensorCircuit: a Quantum Software Framework for the NISQ Era, Quantum 7, 912 (2023).""" # pylint: disable=line-too-long
161-
raise ValueError(f"Unsupported format: {format}")
169+
return """S.-X. Zhang, J. Allcock, Z.-Q. Wan, S. Liu, J. Sun, H. Yu, X.-H. Yang, J. Qiu, Z. Ye, Y.-Q. Chen, C.-K. Lee, Y.-C. Zheng, S.-K. Jian, H. Yao, C.-Y. Hsieh, and S. Zhang, TensorCircuit: a Quantum Software Framework for the NISQ Era, Quantum 7, 912 (2023).
170+
171+
S.-X. Zhang, Y.-Q. Chen, W. Li, J. Sun, W.-G. Ma, P.-L. Zheng, Y.-X. Huang, Q.-X. Wang, H. Yu, Z. Li, X. Huang, Z.-L. Li, Z.-Q. Wan, S. Liu, J. Qiu, J. Miao, Z. Song, Y. Yan, K. Tsuoka, P. Zhang, L. Wang, H. Fan, C.-Y. Hsieh, H. Yao, and T. Xiang, TensorCircuit-NG: A Universal, Composable, and Scalable Platform for Quantum Computing and Quantum Simulation, arXiv:2602.14167 (2026)."""
162172

163173

164174
if __name__ == "__main__":

tensorcircuit/shadows.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,8 @@ def global_shadow_state(
169169
pauli_strings: Optional[Tensor] = None,
170170
sub: Optional[Sequence[int]] = None,
171171
) -> Tensor:
172-
r"""To generate the global shadow state from local snapshot states or snapshots and pauli strings
172+
r"""To generate the global shadow state from local snapshot states or snapshots and pauli strings.
173+
This is the recommended implementation as it typically offers the best performance
173174
174175
:param snapshots: shape = (ns, repeat, nq, 2, 2) or (ns, repeat, nq)
175176
:type: Tensor
@@ -371,7 +372,9 @@ def global_shadow_state1(
371372
pauli_strings: Optional[Tensor] = None,
372373
sub: Optional[Sequence[int]] = None,
373374
) -> Tensor:
374-
r"""To generate the global snapshots states from local snapshot states or snapshots and pauli strings
375+
r"""To generate the global snapshots states from local snapshot states or snapshots and pauli strings.
376+
Note: This version uses a single pure einsum which may be slower during compilation
377+
and execution for larger qubit counts compared to `global_shadow_state`.
375378
376379
:param snapshots: shape = (ns, repeat, nq, 2, 2) or (ns, repeat, nq)
377380
:type: Tensor
@@ -418,7 +421,9 @@ def global_shadow_state2(
418421
pauli_strings: Optional[Tensor] = None,
419422
sub: Optional[Sequence[int]] = None,
420423
) -> Tensor:
421-
r"""To generate the global snapshots states from local snapshot states or snapshots and pauli strings
424+
r"""To generate the global snapshots states from local snapshot states or snapshots and pauli strings.
425+
Note: This version uses vmap over einsum which may be slower during compilation
426+
and execution for larger qubit counts compared to `global_shadow_state`.
422427
423428
:param snapshots: shape = (ns, repeat, nq, 2, 2) or (ns, repeat, nq)
424429
:type: Tensor

0 commit comments

Comments
 (0)