ProjectQ: an open source software framework for quantum computing

Damian S. Steiger, Thomas Häner, and Matthias Troyer

Institute for Theoretical Physics, ETH Zurich, 8093 Zurich, Switzerland

We introduce ProjectQ, an open source software effort for quantum computing. The first release features a compiler framework capable of targeting various types of hardware, a high-performance simulator with emulation capabilities, and compiler plug-ins for circuit drawing and resource estimation. We introduce our Python-embedded domain-specific language, present the features, and provide example implementations for quantum algorithms. The framework allows testing of quantum algorithms through simulation and enables running them on actual quantum hardware using a back-end connecting to the IBM Quantum Experience cloud service. Through extension mechanisms, users can provide back-ends to further quantum hardware, and scientists working on quantum compilation can provide plug-ins for additional compilation, optimization, gate synthesis, and layout strategies.

► BibTeX data

► References

[1] IBM Quantum Experience. http:/​/​research.ibm.com/​quantum/​.
http:/​/​research.ibm.com/​quantum/​

[2] Thomas Häner, Damian S. Steiger, Krysta Svore, and Matthias Troyer. A software methodology for compiling quantum programs. Quantum Science and Technology, 2018. https:/​/​doi.org/​10.1088/​2058-9565/​aaa5cc.
https://doi.org/https://doi.org/10.1088/2058-9565/aaa5cc

[3] pybind. https:/​/​github.com/​pybind.
https:/​/​github.com/​pybind

[4] Thomas Häner, Damian S. Steiger, Mikhail Smelyanskiy, and Matthias Troyer. High performance emulation of quantum circuits. In Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis, SC '16, pages 74:1-74:9, Piscataway, NJ, USA, 2016. IEEE Press. ISBN 978-1-4673-8815-3. 10.1109/​SC.2016.73.
https://doi.org/10.1109/SC.2016.73

[5] Alexander S. Green, Peter LeFanu Lumsdaine, Neil J. Ross, Peter Selinger, and Benoit Valiron. Quipper: a scalable quantum programming language. In ACM SIGPLAN Notices, volume 48, pages 333-342. ACM, 2013. 10.1145/​2499370.2462177.
https://doi.org/10.1145/2499370.2462177

[6] Ali JavadiAbhari, Shruti Patil, Daniel Kudrow, Jeff Heckey, Alexey Lvov, Frederic T. Chong, and Margaret Martonosi. Scaffcc: a framework for compilation and analysis of quantum computing programs. In Proceedings of the 11th ACM Conference on Computing Frontiers, page 1. ACM, 2014. 10.1145/​2597917.2597939.
https://doi.org/10.1145/2597917.2597939

[7] Dave Wecker and Krysta M. Svore. LIQ$Ui|\!>$: A software design architecture and domain-specific language for quantum computing. arXiv preprint arXiv:1402.4467, 2014.
arXiv:1402.4467

[8] ProjectQ website. www.projectq.ch.
http:/​/​www.projectq.ch

[9] Peter W. Shor. Algorithms for quantum computation: Discrete logarithms and factoring. In Foundations of Computer Science, 1994 Proceedings., 35th Annual Symposium on, pages 124-134. IEEE, 1994. 10.1109/​SFCS.1994.365700.
https://doi.org/10.1109/SFCS.1994.365700

[10] Stephane Beauregard. Circuit for shor's algorithm using 2n+ 3 qubits. Quantum Information and Computation, 3 (2): 175-185, 2003.

[11] Yasuhiro Takahashi, Seiichiro Tani, and Noboru Kunihiro. Quantum addition circuits and unbounded fan-out. Quantum Information and Computation, 10 (9&10): 0872-0890, 2010.

[12] Thomas Häner, Martin Roetteler, and Krysta M. Svore. Factoring using 2n+2 qubits with Toffoli based modular multiplication. Quantum Information and Computation, 17 (7&8): 0673-0684, 2017. 10.26421/​QIC17.7-8.
https://doi.org/10.26421/QIC17.7-8

[13] Thomas G. Draper. Addition on a quantum computer. arXiv preprint quant-ph/​0008033, 2000.
arXiv:quant-ph/0008033

[14] Adriano Barenco, Charles H. Bennett, Richard Cleve, David P. DiVincenzo, Norman Margolus, Peter Shor, Tycho Sleator, John A. Smolin, and Harald Weinfurter. Elementary gates for quantum computation. Physical Review A, 52 (5): 3457, 1995. 10.1103/​PhysRevA.52.3457.
https://doi.org/10.1103/PhysRevA.52.3457

[15] Anders Sørensen and Klaus Mølmer. Quantum computation with ions in thermal motion. Physical Review Letters, 82 (9): 1971, 1999. 10.1103/​PhysRevLett.82.1971.
https://doi.org/10.1103/PhysRevLett.82.1971

[16] Ryan Babbush, Dominic W. Berry, Ian D. Kivlichan, Annie Y. Wei, Peter J. Love, and Alán Aspuru-Guzik. Exponentially more precise quantum simulation of fermions in second quantization. New Journal of Physics, 18 (3): 033032, 2016. 10.1088/​1367-2630/​18/​3/​033032.
https://doi.org/10.1088/1367-2630/18/3/033032

[17] Fermilib. https:/​/​github.com/​projectq-framework/​fermilib.
https:/​/​github.com/​projectq-framework/​fermilib

[18] Ludwig E. de Clercq, Hsiang-Yu Lo, Matteo Marinelli, David Nadlinger, Robin Oswald, Vlad Negnevitsky, Daniel Kienzler, Ben Keitch, and Jonathan P. Home. Parallel transport quantum logic gates with trapped ions. Physical Review Letters, 116 (8): 080502, 2016. 10.1103/​PhysRevLett.116.080502.
https://doi.org/10.1103/PhysRevLett.116.080502

[19] Thomas Häner and Damian S. Steiger. 0.5 petabyte simulation of a 45-qubit quantum circuit. In Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis, SC '17, pages 33:1-33:10, New York, NY, USA, 2017. ACM. ISBN 978-1-4503-5114-0. 10.1145/​3126908.3126947.
https://doi.org/10.1145/3126908.3126947

[20] Lov K. Grover. A fast quantum mechanical algorithm for database search. In Proceedings of the twenty-eighth annual ACM Symposium on Theory of Computing, pages 212-219. ACM, 1996. 10.1145/​237814.237866.
https://doi.org/10.1145/237814.237866

Cited by

[1] Alexander Singh, Konstantinos Giannakis, and Theodore Andronikos, "Qumin, a minimalist quantum programming language", arXiv:1704.04460 (2017).

[2] Alwin Zulehner and Robert Wille, "Advanced Simulation of Quantum Computations", arXiv:1707.00865 (2017).

[3] Frederic T. Chong, Diana Franklin, and Margaret Martonosi, "Programming languages and compiler design for realistic quantum hardware", Nature 549 7671, 180 (2017).

[4] Keith A. Britt, Fahd A. Mohiyaddin, and Travis S. Humble, "Quantum Accelerators for High-Performance Computing Systems", arXiv:1712.01423 (2017).

[5] X. Fu, M. A. Rol, C. C. Bultink, J. van Someren, N. Khammassi, I. Ashraf, R. F. L. Vermeulen, J. C. de Sterke, W. J. Vlothuizen, R. N. Schouten, C. G. Almudever, L. DiCarlo, and K. Bertels, "An Experimental Microarchitecture for a Superconducting Quantum Processor", arXiv:1708.07677 (2017).

[6] Mathias Soeken, Thomas Häner, and Martin Roetteler, "Programming Quantum Computers Using Design Automation", arXiv:1803.01022 (2018).

[7] E. Schuyler Fried, Nicolas P. D. Sawaya, Yudong Cao, Ian D. Kivlichan, Jhonathan Romero, and Alán Aspuru-Guzik, "qTorch: The Quantum Tensor Contraction Handler", arXiv:1709.03636 (2017).

[8] Krysta M. Svore, Alan Geller, Matthias Troyer, John Azariah, Christopher Granade, Bettina Heim, Vadym Kliuchnikov, Mariia Mykhailova, Andres Paz, and Martin Roetteler, "Q#: Enabling scalable quantum computing and development with a high-level domain-specific language", arXiv:1803.00652 (2018).

[9] Alexander McCaskey, Eugene Dumitrescu, Mengsu Chen, Dmitry Lyakh, and Travis S. Humble, "Validating Quantum-Classical Programming Models with Tensor Network Simulations", arXiv:1807.07914 (2018).

[10] Thomas Häner and Damian S. Steiger, "0.5 Petabyte Simulation of a 45-Qubit Quantum Circuit", arXiv:1704.01127 (2017).

[11] Kyle E. C. Booth, Minh Do, J. Christopher Beck, Eleanor Rieffel, Davide Venturelli, and Jeremy Frank, "Comparing and Integrating Constraint Programming and Temporal Planning for Quantum Circuit Compilation", arXiv:1803.06775 (2018).

[12] Kanav Setia and James D. Whitfield, "Bravyi-Kitaev Superfast simulation of electronic structure on a quantum computer", Journal of Chemical Physics 148 16, 164104 (2018).

[13] Hao Tang, Yan-Yan Zhu, Jun Gao, Marcus Lee, Peng-Cheng Lai, and Xian-Min Jin, "FeynmanPAQS: A Graphical Interface Program for Photonic Analog Quantum Computing", arXiv:1810.02289 (2018).

[14] Nathan Killoran, Josh Izaac, Nicolás Quesada, Ville Bergholm, Matthew Amy, and Christian Weedbrook, "Strawberry Fields: A Software Platform for Photonic Quantum Computing", arXiv:1804.03159 (2018).

[15] Jarrod R. McClean, Ian D. Kivlichan, Kevin J. Sung, Damian S. Steiger, Yudong Cao, Chengyu Dai, E. Schuyler Fried, Craig Gidney, Brendan Gimby, Pranav Gokhale, Thomas Häner, Tarini Hardikar, Vojtěch Havlíček, Cupjin Huang, Josh Izaac, Zhang Jiang, Xinle Liu, Matthew Neeley, Thomas O'Brien, Isil Ozfidan, Maxwell D. Radin, Jhonathan Romero, Nicholas Rubin, Nicolas P. D. Sawaya, Kanav Setia, Sukin Sim, Mark Steudtner, Qiming Sun, Wei Sun, Fang Zhang, and Ryan Babbush, "OpenFermion: The Electronic Structure Package for Quantum Computers", arXiv:1710.07629 (2017).

[16] Jin-Guo Liu and Lei Wang, "Differentiable Learning of Quantum Circuit Born Machine", Physical Review A 98 6, 062324 arXiv:1804.04168 (2018).

[17] Andrew W. Cross, Lev S. Bishop, John A. Smolin, and Jay M. Gambetta, "Open Quantum Assembly Language", arXiv:1707.03429 (2017).

[18] Gian Giacomo Guerreschi and Jongsoo Park, "Two-step approach to scheduling quantum circuits", Quantum Science and Technology 3 4, 045003 (2018).

[19] Davide Ferrari and Michele Amoretti, "Efficient and effective quantum compiling for entanglement-based machine learning on IBM Q devices", International Journal of Quantum Information 16 08, 1840006 (2018).

[20] Patrick Rebentrost, Brajesh Gupt, and Thomas R. Bromley, "Quantum computational finance: Monte Carlo pricing of financial derivatives", Physical Review A 98 2, 022321 (2018).

[21] Julien Ross, "The dawn of quantum programming", Quantum Views 2, 4 (2018).

[22] Aniruddha Bapat, Zachary Eldredge, James R. Garrison, Abhinav Deshpande, Frederic T. Chong, and Alexey V. Gorshkov, "Unitary entanglement construction in hierarchical networks", Physical Review A 98 6, 062328 (2018).

[23] Axel Dahlberg and Stephanie Wehner, "SimulaQron—a simulator for developing quantum internet software", Quantum Science and Technology 4 1, 015001 (2018).

[24] Ilya G. Ryabinkin, Tzu-Ching Yen, Scott N. Genin, and Artur F. Izmaylov, "Qubit Coupled Cluster Method: A Systematic Approach to Quantum Chemistry on a Quantum Computer", Journal of Chemical Theory and Computation 14 12, 6317 (2018).

[25] Mark Fingerhuth, Tomáš Babej, Peter Wittek, and Leonie Anna Mueck, "Open source software in quantum computing", PLOS ONE 13 12, e0208561 (2018).

The above citations are from Crossref's cited-by service (last updated 2019-01-23 03:00:29) and SAO/NASA ADS (last updated 2019-01-23 03:00:30). The list may be incomplete as not all publishers provide suitable and complete citation data.

2 thoughts on “ProjectQ: an open source software framework for quantum computing

  1. Pingback: Qstarter award for Quantum! – Quantum

  2. Pingback: Qstarter award for Quantum! – Quantum Electronics