Releases: XanaduAI/thewalrus
Release 0.22.0
New features
- Implements the pre-Iwasawa and Iwasawa decompositions for symplectic matrices (#382).
Breaking changes
- Upgrades to
numpy2 (#398).
Improvements
-
Further simplifies the implementation of
decompositions.williamsonand corrects its docstring (#380). -
Further simplifies the implementation of
decompositions.blochmessiah(#381).
Bug fixes
-
Add the calculation method of
takagiwhen the matrix is diagonal. (#394) -
Add the lines for avoiding the comparison of np.ndarray and list. (#395)
Contributors
This release contains contributions from (in alphabetical order):
L.G. Helt (@heltluke), Will McCutcheon, Nicolas Quesada (@nquesada)
Release 0.21.0
New features
Improvements
-
Tighten power-trace bound of odd loop Hafnian. (#362)
-
Simplifies the internal working of Bloch-Messiah decomposition (#363).
-
Simplifies the internal working of Williamson decomposition (#366).
-
Improves the handling of an edge case in Takagi (#373).
-
Adds extra tests for the Takagi decomposition (#377)
Contributors
This release contains contributions from (in alphabetical order):
Yanic Cardin (@yaniccd), Gregory Morse (@GregoryMorse), Nicolas Quesada (@nquesada)
Release 0.20.0
New features
- Implementation of gaussian boson sampling and gaussian boson sampling with threshold detectors. (#343)
- New function to produce Bloch-Messiah decomposition of symplectic matrices. (#352)
Improvements
- Added function to extend single mode symplectic to act on multiple modes. (#347)
- Added function to compute grouped (total) click probabilities for GBS setups using threshold detectors. The function uses the positive P-distribution simulation method of Drummond et al.. (#348)
Bug fixes
- Remove redundant call of
Qmat,Amatfromgenerate_hafnian_sample. (#343)
Documentation
- The centralized Xanadu Sphinx Theme is now used to style the Sphinx documentation. (#341)
Contributors
This release contains contributions from (in alphabetical order):
Mikhail Andrenkov (@Mandrenkov), Sebastián Duque (@sduquemesa), Jacob Hastrup (@JacobHast), Antonín Hoskovec (@thonic), Martin Houde (@MHoude2), Benjamin Lanthier (@benjaminlanthier), Dominic Leclerc (@dleclerc33), Filippo Miatto (@ziofil), Will McCutcheon, Brandon Turcotte (@brandonpolymtl), Jiaqi Zhao (@JQZ1111)
Release 0.19.0
New features
-
New functions for calculating properties of distinguishable squeezed states of light having passed through an interferometer. #326
-
New function
ltoris added which allowsthreshold_detector_probto act more consistently on displaced and zero-mean Gaussian states. #317 -
New functions for threshold detection probabilities of Fock states, the Bristolian (brs) and the Unitary Bristolian (ubrs). #316
-
Entanglement measures
entanglement_entropyandlog_negativityfor bipartite Gaussian states are added to the quantum submodule. #332 -
New functions,
recursive_hafnianandsolveadded in the_hafnianmodule. #325 -
New function to check if a matrix is symplectic
is_symplectic. #334. -
Adds support for Python 3.10. #337
Improvements
-
Update methods for calculating threshold detector probabilities of Gaussian states, now using
ltorfunction withinthreshold_detection_prob#317 -
numba_tornow can benefit from numba parallelization #317 -
Recursive Torontonian added for faster computation based on paper "Polynomial speedup in Torontonian calculation by a scalable recursive algorithm" by Ágoston Kaposi, Zoltán Kolarovszki, Tamás Kozsik, Zoltán Zimborás, and Péter Rakyta. #321
-
Recursive Loop Torontonian added for faster computation based on combining recursive Torontonian improvement and new loop Torontonian feature. #332
-
Hafnians of odd-sized matrices are calculated roughly twice as fast. #329
-
The new Hafnian functions now use the Labudde method to calculate power traces instead of using diagonalization. #333
Bug fixes
- Permanent algorithms handle 0x0 cases correctly. #320
Contributors
This release contains contributions from (in alphabetical order):
Jake Bulmer, Luke Helt, Martin Houde, Theodor Isacsson, Benjamin Lanthier, Fabian Laudenbach, Dominic Leclerc, Gregory Morse, Nicolas Quesada, Brandon Turcotte, Jiaqi Zhao
Release 0.18.0
New features
- Python module for the La Budde method of computing characteristic polynomials. #304
Improvements
-
Permanent algorithms are implemented in Python using Numba just-in-time compilation. #300
-
Hafnian algorithms are implemented in Python using Numba just-in-time compilation. #311
-
Documentation is updated to include the characteristic polynomials and decompositions modules. #312
Bug fixes
-
Makes modules reachable via the global namespace, instead of requiring importing the modules explicitly. #312
import thewalrus as tw tw.samples.generate_torontonian_sample
Breaking Changes
- The Walrus is no longer dependent on C++, and all C++-related code and documentation is removed. Instead, all code has been ported to Python using just-in-time compilation to improve performance. #311
Contributors
This release contains contributions from (in alphabetical order):
Theodor Isacsson, Benjamin Lanthier, Dominic Leclerc, Nicolas Quesada, Brandon Turcotte, Trevor Vincent, Jiaqi Zhao
Release 0.17.0
Improvements
-
Python installation no longer requires
repoze.lru. #293 -
Multidimensional Hermite polynomials are now implemented in Numba, hence reducing the C++ dependencies of The Walrus. #295
-
Updates missing figures in the "Basics of Hafnians and Loop Hafnians" documentation. #288
Contributors
This release contains contributions from (in alphabetical order):
Mikhail Andrenkov, Sebastián Duque
Release 0.16.2
Bug fixes
hermite_multidimensional_numbacan now handle a cutoff of typenp.ndarraywithshape=[]. #283
Contributors
This release contains contributions from (in alphabetical order):
Filippo Miatto
Release 0.16.1
Improvements
- Faster implementation of
hermite_multidimensional_numbaandhermite_multidimensional_numba_grad. #280
Bug fixes
-
Updates the
samples.generate_torontonian_samplefunction to ensure probabilities are normalized. #250 -
Pins Numba to version
<0.54to avoid binary imcompatibilities with the 1.21 release of NumPy. #250
Contributors
This release contains contributions from (in alphabetical order):
Josh Izaac, Filippo Miatto, Nicolas Quesada.
Release 0.16.0
New features
-
Adds the function
hafnian_sparseto compute sparse loop hafnians (pure Python implementation). #245 -
The
symplectic.squeezingfunction is now generalized to multiple modes of single mode squeezing. #249 -
Adds a function
symplectic.passive_transformationwhich allows for Gaussian states to be transformed by arbitrary non-unitary, non-square linear optical transformations. #249 -
The
torontonian_sample_statefunction can now sample displaced Gaussian states. #248 -
Adds the function
hafnian_bandedto calculate the hafnian of a banded matrix. #246 -
Adds the functions
hermite_multidimensional_numbaandgrad_hermite_multidimensional_numbato calculate renormalized multidimensional Hermite polynomials and its gradients using Numba. #251 -
Adds the functions
mzgateandgrad_mzgateto calculate the Fock representation of the Mach-Zehnder gate and its gradients. #257 -
Adds the ability to calculate n-body photon number distributions using the function
n_body_marginals. #253 -
Adds the ability to calculate cumulants and arbitrary expectation values of products of powers of photon numbers with the functions
photon_number_cumulantandphoton_number_momentrespectively. #264 -
Adds support for calculating the permanent using the BBFG algorithm and changes this to the default method for calculating permanents. #267
-
Adds the ability to calculate click cumulants in threshold detection with the function
click_cumulant. #264
Improvements
-
Speeds up the calculation of photon number variances/covariances. #244
-
Updates documentation for the the
torfunction. #265 -
Numba methods for multidimensional hermite can now detect dtype automatically. #271
Bug fixes
-
Corrects bug in the function
photon_number_covarthat gave incorrect results when the covariance between two modes with finite displacements was calculated. #264 -
Fixes a bug in
setup.pythat would cause the build to fail when using miniforge for M1 macs. #273 -
Updates the
samples.generate_hafnian_samplefunction to renormalize probabilities. #250
Breaking changes
- Torontonians and approximations to the hafnian for non-negative matrices are no longer calculated in C++ using the Eigen software library. Instead, they are now calculated in pure Python using Numba. These changes have the nice result of making The Walrus compilable from source using only a C++ compiler. #262 #259.
Contributors
This release contains contributions from (in alphabetical order):
Ali Asadi, Jake Bulmer, Timjan Kalajdzievski, Filippo Miatto, Nicolas Quesada, Yuan Yao
Release 0.15.1
Bug fixes
- Builds The Walrus binaries against an older version of NumPy, to avoid a breaking ABI change in NumPy 1.20. #240
Contributors
This release contains contributions from (in alphabetical order):
Josh Izaac