Tensorflow-quantum

Latest version: v0.7.3

Safety actively analyzes 688587 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

0.7.3

Updates TFQ To run on TensorFlow 2.15.0.

No Functional changes.

0.7.2

Patch release to bring GitHub release versions in line with pypi. No functional changes.

0.6.1

No functional changes. Fix for internal build systems.

0.6.0

New Features / Improvements

`tfq.math` now contains high performance fixed bond dimension MPS simulation to sample, compute expectation values and compute expectation values via sampling from 1D non periodic circuits.
`tfq.math.mps_1d_expectation`
`tfq.math.mps_1d_sample`
`tfq.math.mps_1d_sampled_expectation`
These are fully parallelized and based on new qsim MPS functionality found here: https://github.com/quantumlib/qsim/blob/d063d427d1f55d580416259233ce9c64037c00a0/lib/mps_simulator.h#L1

Instances of `cirq.LineQubit` are now supported when serializing circuits and paulisum objects.

`tfq.optimizers` now contains an implementation of SPSA optimization: https://www.jhuapl.edu/spsa/
`tfq.optimizers.spsa_minimize`.
Other

Minor CPU performance boosts from qsim upgrades.
TFQ now relies on TensorFlow version 2.7.0.
New tutorials that can be found on website.

Full commit list:
* Bump working version to 0.6.0 by MichaelBroughton in https://github.com/tensorflow/quantum/pull/570
* Remove -q flag from pip install in notebooks. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/575
* Quantum reinforcement learning tutorial by sjerbi in https://github.com/tensorflow/quantum/pull/541
* Removed fixed grpcio version. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/584
* Cleaned up latex and docs rendering. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/585
* Added new noise tutorial. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/582
* Upgraded sympy to v1.8. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/591
* Updated tensorflow.org/quantum landing cards. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/593
* Pulled out Cirq proto dependency. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/590
* Ensure gradient of tf.math.fidelity remains float32 when autographed. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/596
* Fix internal build error by jaeyoo in https://github.com/tensorflow/quantum/pull/600
* Upgrade to TF2.5.1 by jaeyoo in https://github.com/tensorflow/quantum/pull/612
* Upgrade CI to 18.04 to follow TF 2.5.0 by MichaelBroughton in https://github.com/tensorflow/quantum/pull/613
* Update concepts.md by MichaelBroughton in https://github.com/tensorflow/quantum/pull/626
* Update design.md by MichaelBroughton in https://github.com/tensorflow/quantum/pull/627
* importlib.reload(pkg_resources) for tensorflow.org by MarkDaoust in https://github.com/tensorflow/quantum/pull/631
* Fix QRL tutorial by sjerbi in https://github.com/tensorflow/quantum/pull/634
* Add cirq.LineQubit support to op_deserializer.py. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/633
* Add support for cirq.LineQubit to op_serializer.py by MichaelBroughton in https://github.com/tensorflow/quantum/pull/632
* Increment requirement to Cirq to 0.13.1 by tonybruguier in https://github.com/tensorflow/quantum/pull/621
* Add support for LineQubit to serializer.py by MichaelBroughton in https://github.com/tensorflow/quantum/pull/637
* Fix auditwheel script by jaeyoo in https://github.com/tensorflow/quantum/pull/639
* Finish support for LineQubit everywhere. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/641
* Implement serialization logic for ProjectorSums. by tonybruguier in https://github.com/tensorflow/quantum/pull/623
* Run format_all script by tonybruguier in https://github.com/tensorflow/quantum/pull/644
* change import to cirq_google from cirq.google by tonybruguier in https://github.com/tensorflow/quantum/pull/643
* Upgrade to TF 2.7.0. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/650
* Add `tfq.math.mps_1d_expectation` for 1D MPS by jaeyoo in https://github.com/tensorflow/quantum/pull/610
* update qsim to latest version. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/651
* Add mps 1d Sample / SampledExpectation ops by jaeyoo in https://github.com/tensorflow/quantum/pull/654
* Add SPSA optimizer by lockwo in https://github.com/tensorflow/quantum/pull/653
* Update MPS docs by MichaelBroughton in https://github.com/tensorflow/quantum/pull/657
* Loosen cirq requirements in anticipation of release. by MichaelBroughton in https://github.com/tensorflow/quantum/pull/659
* constrain xticks in two plt figures by tbcdebug in https://github.com/tensorflow/quantum/pull/658

New Contributors
* sjerbi made their first contribution in https://github.com/tensorflow/quantum/pull/541
* tbcdebug made their first contribution in https://github.com/tensorflow/quantum/pull/658

**Full Changelog**: https://github.com/tensorflow/quantum/compare/v0.5.0...v0.6.0

0.5.1

Remove explicit and potentially problematic `grpcio==1.30.0` dependency, along with some docs cleanup.

0.5.0

TensorFlow Quantum 0.5.0 includes new features, bug fixes and minimal API changes.

**New Features/Improvements:**
Added support for Cirq gates that have arbitrary control via the `gate.controlled_by` function. (Gradient support as well)
Added `tfq.math.inner_product` gradient. This op will now provide a gradient via `tf.GradientTape`.
Added `tfq.math.fidelity` op and gradient. This op will now provide a gradient via `tf.GradientTape`.
Added support in `tfq.convert_to_tensor` for circuits containing any Cirq noise channel from [common_channels](https://github.com/quantumlib/Cirq/blob/master/cirq-core/cirq/ops/common_channels.py) .
Added `tfq.noise.expectation` op and support with existing Differentiators for noisy analytic expectation calculation. Noisy simulations done via monte-carlo/trajectory sampling.
Added `tfq.noise.samples` op to draw bitstring samples from noisy circuits.
Added `tfq.noise.sampled_expectation` op and support with existing Differentiators for sample based expectation calculation.
Introduced `get_gradient_circuits` interface method for differentiators for users wanting to define a custom Differentiator.
Updated `tfq.layers.Expectation`, `tfq.layers.Samples`, `tfq.layers.SampledExpectation` with `__init__` parameter `backend=noisy`, `backend='noiseless'` to support noisy circuits.
Added `tfq.layers.NoisyPQC` and `tfq.layers.NoisyControlledPQC` which are noisy equivalents of `tfq.layers.PQC` and `tfq.layers.ControlledPQC`.
New datasets available via `tfq.datasets`.
Improved stability and performance in distributed training with `MultiWorkerMirroredStrategy` and `ParameterServer`.

**Bug fixes**
Fixed an issue where backward passes done on expectation ops with empty input tensors would cause `SEGFAULT`.
Fixed inconsistent output shapes between some ops, when input was the empty tensor.
Fixed randomness sources used for sampling to use thread safe `philox_random` approaches from TF instead of `std::mt19937` from the standard library.
Removed parallel calls to custom Cirq simulators when using `backend != None` inside of any `tfq.layers`. This is to ensure compatibility with high performance remote simulators as well as when running on real devices.

**Breaking changes**
We now depend on `cirq==0.11.0` and `tensorflow==2.4.1`.

A big thanks to all of our contributors for this release:
zaqqwerty , jaeyoo , lamberta , MarkDaoust , MichaelBroughton , therooler , sjerbi, balopat , lockwo, gatorwatt .

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.