What's new
Cirq has officially left alpha and is v1.0. With this release comes new policies on API stability as well as functionality gaurantees for the long term. Along with some minor bug fixes and tweaks, this release focuses on stabilizing the APIs within cirq-core
. With cirq-core
we intend to follow along with semver and only make breaking changes with moves to new major versions. For the vendor packages we plan to continue to allow developers to iterate at speed and will do best effort on ensuring any API changes come with as little friction as possible. For all the details on this policy please see: release.md.
To make this upgrade as smooth as possible, we recommend first upgrading your installation to Cirq v0.15 to surface any deprecation warnings or upcoming breakages you might experience, once those are resolved, you can safely install Cirq v1.0.0.
Thank you all so much for your hard work.
What's Changed
- Fix for issue #5637 by @mhucka in #5638
- Remove stale TODO and fix #5546 by @tanujkhattar in #5643
- Bump cirq version to 0.16.0 by @MichaelBroughton in #5640
- Change GridDeviceMetadata qubit type to GridQubit by @verult in #5633
- Fix small issues in Shor tutorial by @dstrain115 in #5639
- Fix CI failure due to incompatible qiskit packages by @pavoljuhas in #5661
- Fix typing of the protocols.commutes() function by @pavoljuhas in #5651
- Remove GlobalPhaseOperation and GateSet.accepts_global_phase by @daxfohl in #5663
- Add init.py to make
cirq.contrib.hacks
a proper package by @maffoo in #5662 - Remove tetris_concat by @daxfohl in #5659
- Migrate StrategyExecutor to new transformer infrastructure by @ammareltigani in #5644
- Add return-type description for
cirq.sample
by @95-martin-orion in #5649 - Pin python-rapidjson in cirq-rigetti. by @MichaelBroughton in #5666
- Fix typing in numpy function arguments by @pavoljuhas in #5657
- Minor updates to development page by @dstrain115 in #5667
- Replace
SwapPermutationReplacer
withcirq.map_operations
by @tanujkhattar in #5655 - Engine creator helper function by @augustehirth in #5658
- Fix more numpy / mypy typing issues by @pavoljuhas in #5669
- Deprecate
MergeNQubitGates
optimizer by @tanujkhattar in #5653 DensePauliString
andMutableDensePauliString
docs and inconsistencies fixes by @tanujkhattar in #5624- Missing stubs for mypy --next by @dabacon in #5670
- Update docstrings for PauliSum. by @MichaelBroughton in #5596
- Change GridDeviceMetadata gate duration property to Mapping type by @verult in #5656
- Modify some numpy types to be compatible with
numpy>=1.20
by @vtomole in #5668 - Revert "Pin python-rapidjson in cirq-rigetti." by @vtomole in #5671
- Remove deprecated ArithmeticOperation by @daxfohl in #5579
- Remove quantum engine sampler by @dstrain115 in #5673
- Remove deprecated experiments by @dstrain115 in #5674
- Remove key protocols frozenset conversion by @daxfohl in #5660
- Remove PasqalConverter deprecation. by @MichaelBroughton in #5672
- Fix remaining mypy/numpy errors by @pavoljuhas in #5677
- Call
cirq.testing.assert_equivalent_repr
forcirq.SingleQubitCliffordGate
andcirq.CliffordTableau
by @vtomole in #5664 - Remove ops.Moment deprecation. by @MichaelBroughton in #5682
- Remove sim v0.16 deprecations by @daxfohl in #5645
- Deprecate classes and paramters in contrib by @dstrain115 in #5684
- Refactored and created an abstraction for control values by @NoureldinYosri in #5362
- Document dimension of X/ZPowGate by @95-martin-orion in #5648
- Link out to ParamResolver in resolve_parameters docstring by @95-martin-orion in #5699
- De-indent channel matrices by @95-martin-orion in #5700
- Remove deprecated SingleQubitGate by @dstrain115 in #5686
with_probability
docstring by @95-martin-orion in #5697- A Cauldron of Doc fixes by @dstrain115 in #5680
- Fix 5702: prevent confusing error if
dev_tools/modules.py
is invoked without arguments by @mhucka in #5706 - Use
@cached_method
for FrozenCircuit properties by @maffoo in #5707 - Remove deprecated stratify module by @dstrain115 in #5714
- Loosen
pyquil
requirements by @vtomole in #5681 - Remove deprecated class PauliTransform by @pavoljuhas in #5703
- Two more small doc fixes by @dstrain115 in #5711
- Remove CrossEntropyResult and CrossEntropyResultDict by @dstrain115 in #5687
- Cirq monofsv cleanup by @95-martin-orion in #5685
- Remove deprecated netural_atoms classes by @dstrain115 in #5695
- Remove Deprecated Quil classes by @dstrain115 in #5710
- Change exponent asterisks in doc string to carats by @dstrain115 in #5716
- Remove remaining quil magic methods by @dstrain115 in #5723
- unleash confusion map by @pavoljuhas in #5717
- Remove final_state_vector deprecations. by @MichaelBroughton in #5720
- Dedicated method for creating circuit from op tree with EARLIEST strategy by @daxfohl in #5332
- Remove virtual_predicate deprecations. by @MichaelBroughton in #5724
- Remove deprecated merge_single_qubit optimizer by @dstrain115 in #5725
- Improve common_gates docstrings by @95-martin-orion in #5722
- remove 2 deprecated create_device_proto_* methods for v0.16 release by @kmlau in #5704
- Remove a batch of deprecated optimizers by @dstrain115 in #5727
- Finish removing optimizers by @dstrain115 in #5729
- More numpy types by @vtomole in #5683
- Improve Fourier Checking tutorial by @dstrain115 in #5708
- Remove circuits.CircuitDag by @dstrain115 in #5733
- Nitpick on comment after #5724 by @pavoljuhas in #5732
- Fix 5701: avoid
dev_tools/modules.py print_version
failing by @mhucka in #5705 - Add async methods to AbstractEngine and AbstractJob by @maffoo in #5555
- Remove deprecated calls in examples/bcs_mean_field by @dstrain115 in #5737
- Eigengate docs: move init to class docs for better rendering by @dstrain115 in #5735
- Fix the definition of PhasedFSimGate by @eliottrosenberg in #5736
- Add json serialization to sweeps by @dabacon in #5618
- Fix reference to
run_batch
inrun_batch_async
docs by @maffoo in #5740 - Fix incomplete sentences by @augustehirth in #5741
- GridDevice: Exclude MeasurementGates in validation of qubit pairs by @verult in #5654
- Cache the hash of frozen circuits to avoid recomputing by @maffoo in #5738
- Remove gatesets deprecations. by @MichaelBroughton in #5679
- Remove deprecated class SerializableDevice by @pavoljuhas in #5743
- Remove unused method SimulationState.with_qubits by @pavoljuhas in #5748
- Fix very trivial grammar issues & typos in docs/start/basics by @mhucka in #5752
- Re-enable doctest by @dabacon in #5742
- json serialize SharedRuntimeInfo.device by @pavoljuhas in #5746
- Update deprecated pandas in Fourier Checking tutorial by @dstrain115 in #5751
- Miscellaneous Doc Fixes by @dstrain115 in #5754
- Increase timeout of a flaky speed test by @pavoljuhas in #5756
- Add
cirq.two_qubit_matrix_to_cz_isometry
decomposition for single to two qubit isometry using at-most 2CZs. by @tanujkhattar in #5728 - Remove deprecated classes ConvertToIonGates and IonDevice by @pavoljuhas in #5696
- Fix the final mypy --next errors by @dabacon in #5760
- Return processor_id and project_id in get_qcs_objects_for_notebooks by @dstrain115 in #5759
- Remove mypy --next by @dabacon in #5763
- QASM for MatrixGate by @dabacon in #5731
- cirq-google: Remove SerializableGateSet by @verult in #5762
- Add
CliffordTargetGateset
and deprecateConvertToSingleQubitCliffordGates
andConvertToPauliStringPhasor
by @tanujkhattar in #5650 - cirq-google: Remove serializers by @verult in #5764
- Remove gate_set arg in CircuitSerializer constructor by @verult in #5769
- Simplify
reshape(a, prod(a.shape))
toa.reshape(-1)
by @pavoljuhas in #5768 - Google colab tutorial - minor cleanup by @verult in #5430
- Fixes #5713:
pytest .
fails to findcirq
module by @mhucka in #5772 - Created SumOfProducts subclass of ControlValues by @NoureldinYosri in #5755
- Add device specification to QVM by @dstrain115 in #5771
- Bump mypy to latest version by @maffoo in #5767
- Remove unused method AQTDevice.neighbors_of by @pavoljuhas in #5770
- Remove unnecessary casts and type: ignores by @maffoo in #5781
- Update XEB and Coherent Error Tutorial by @augustehirth in #5158
- Run tests against python 3.10 by @maffoo in #5486
- Miscellaenous doc fixes by @dstrain115 in #5779
- Move AQTTargetGateset to its own module by @pavoljuhas in #5782
- Fixes #5773: guard against user's
~/.gitconfig
settinginit.templateDir
by @mhucka in #5774 - Add AQTDeviceMetadata and clean up AQTDevice by @pavoljuhas in #5789
- Use Mapping instead of Dict in some grid device helper funcs by @maffoo in #5790
- Removing cirq_google.optimizers by @verult in #5780
- GoogleCZTargetGateset by @verult in #5744
- Handle global phase gate in single-qubit merge transformers by @viathor in #5786
- pytest exclude TestNoiseProperties from test discovery by @pavoljuhas in #5791
- Always return 1D vector from final_state_vector by @maffoo in #5793
- Remove unused qid_shape param from DMSimState.init by @daxfohl in #5792
- Fix classically controlled op Moment diagram by @daxfohl in #5777
- Use GoogleCZTargetGateset; add device gateset as additional gates in target gatesets by @verult in #5765
- Suppress matplotlib warnings on non-GUI use of show() by @pavoljuhas in #5749
- Refactor AbstractControlValues and it's implementations to fix multiple bugs and improve consistency by @tanujkhattar in #5788
New Contributors
- @mhucka made their first contribution in #5638
- @ammareltigani made their first contribution in #5644
- @kmlau made their first contribution in #5704
- @eliottrosenberg made their first contribution in #5736
Full Changelog: v0.15.0...v1.0.0
A very special thanks to the all the contributors we've had over the years:
Abhik Banerjee, Abhishek Chakraborty, Abraham Asfaw, Adam Zalcman, AJ Hanus, Alapan Chaudhuri, Albert Frisch, Aleksandr Pak, Alexis Shaw, Alex McNamara, Ali Panahi, Ammar Eltigani, Ana Sofia Uzsoy, Andreas Bengtsson, Andrea Skolik, Andrew Hancock, Andriy Kushnarov, Animesh Sinha, Anna Nachesa, Antoine (Tony) Bruguier, Antonio Martinez, asaf david, augustehirth, Balint Pato, balopat, Bao Nguyen, Ben Brady, Bicheng Ying, Billy Lamberta, brett koonce, Bryan A. O'Gorman, Bryan Bonnet, bryano, bt3gl, Casey Duckering, Cheng Xing, Chen Jialin, Cirq Bot, cjcarey, Cody Poole, cognigami, Craig Gidney, crystalzhaizhai, Daniel (Bochen) Tan, Dave Bacon, David Cox, David Yonge-Mallo, Dax Fohl, dependabot[bot], dkafri, Dmytro Fedoriaka, Dominic Widdows, Doug Strain, Drew, eliottrosenberg, Eric Hulburd, Etsuji Nakai, evan, Evan Peters, FallenApart, Freyam Mehta, fvkg, Gaurav Mann, Gregory Clark, Guen Prawiroatmodjo, gwhitehawk, Hannah Sim, harryputterman, Henrique Silvério, Hosseinberg, idk3, Ilja Livenson, ishmum123, Ishmum Jawad Khan, Jack Ceroni, Jae H. Yoo, Jannes Stubbemann, Jimmy Yao, Jintao YU, jitendrs, Jon Donovan, joshp112358, jshede, karlunho, Kevin J. Sung, KevinVillela, Kislay Kishore, K M Lau, Kunal Arya, Laurent AJDNIK, Leonid Kuligin, lilies, lindmarkm, Loïc Henriet, madcpf, Malice, Mark Daoust, Martin Ganahl, Martin Leib, Matteo Pompili, Matthew Harrigan, Matthew McEwen, Matthew Neeley, Max Hettrich, melonwater211, Mia von Steinkirch, Mia von Steinkirch, Ph.D., M.Sc, Michael A. Perlin, Michael Broughton, MichaelBroughton, Mike Hucka, Misha Brukman, m-szalay, Muyuan Li, Nathanael Thompson, Nathan Shammah, Nicholas Rubin, Niko Savola, Noureldin, Oliver O'Brien, Orion Martin, Patrick Nannt, Pavol Juhas, Paweł Pamuła, Peter Karalekas, Philip Massey, Pieter Eendebak, Ping Yeh, pschindler, Purva Thakre, Rhea Parekh, Rishabh, Rishit Vora, Robert Hundt, Ryan Babbush, Ryan Gonzalez, Ryan LaRose, Ryan Levy, Sagar Dollin, Samarth Vadia, sboixo, sebgrijalva, Seb Grijalva, Seun Omonije, Shadab Hussain, Shaswata Das, Shrill Shrestha, smadhuk, smitsanghavi, Smit Sanghavi, Spencer Churchill, stoykojulia, TAKAHASHI Shuuji, Tanuj Khattar, Tim Gates, Timo Eckstein, Timothy Man, Tim Swast, Tony Bruguier, tonybruguier-google, twojno, Unai Corzo, Vamsi Krishna Devabathini, Victory Omole, Walker Willetts, William Courtney, wing, Wojciech Mruczkiewicz, XiaoMiQC, Yash Katariya, YBC, yourball, Yusheng Zhao, Zachary Crockett, Zeeshan Ahmed, Zhang Jiang, Zijun Chen, Zijun "Jimmy" Chen, zoltanegyed