Amazon Braket now supports adjoint gradient computation, unlocking runtime improvements and cost savings
Share
Services
SV1, the on-demand state vector simulator on [Amazon Braket](/braket/), now supports the computation of gradients using the adjoint differentiation method, enabling customers to reduce runtime and save costs for their quantum machine learning and optimization workloads. With this launch, customers simulating variational quantum algorithms with a large number of parameters, such as the quantum approximate optimization algorithm (QAOA), can now seamlessly incorporate adjoint gradient computation either directly from the [Braket Python SDK](https://github.com/aws/amazon-braket-sdk-python) or API, or through [PennyLane](https://docs.aws.amazon.com/braket/latest/developerguide/hybrid.html), an open-source software framework built for quantum differentiable programming.
When using classical simulation to compute gradients for variational quantum algorithms, customers look to use the adjoint differentiation method for its inherent efficiency, requiring only two circuit executions, irrespective of the number of parameters or qubit count. Alternative methods, such as the parameter-shift rule, require the number of circuit executions to scale linearly with the number of parameters. For example, computing gradients using the adjoint differentiation method for a 2-layer QAOA with four total parameters, unlocks 4x speedups in runtime and corresponding cost savings, compared to using the parameter shift method. To compute adjoint gradients on SV1, customers now simply specify the adjoint gradient result type along with the corresponding parameters and observables, and run their simulation as usual.
This capability is available starting today in [all AWS Regions](https://docs.aws.amazon.com/braket/latest/developerguide/braket-regions.html) where Braket is available, at no additional cost. To get started with gradient computation on SV1, please see the following resources: [Amazon Braket Developer Guide](https://docs.aws.amazon.com/braket/latest/developerguide/what-is-braket.html), [example notebook](https://github.com/aws/amazon-braket-examples/tree/main/examples/braket%5Ffeatures/Using%5FThe%5FAdjoint%5FGradient%5FResult%5FType.ipynb) exploring adjoint gradient computation on Braket, or this [example notebook](https://github.com/aws/amazon-braket-examples/tree/main/examples/pennylane/6%5FAdjoint%5Fgradient%5Fcomputation/6%5FAdjoint%5Fgradient%5Fcomputation.ipynb) using the PennyLane integration. For more information about the AWS Free Tier for simulator usage on Braket, please visit our [pricing page](/braket/pricing/).
What else is happening at Amazon Web Services?
Read update
Services
Share
Read update
Services
Share
Read update
Services
Share
Read update
Services
Share
Read update
Services
Share