A PyTorch-based framework for Quantum Classical Simulation, Quantum Machine Learning, Quantum Neural Networks, Parameterized Quantum Circuits with support for easy deployments on real quantum computers.
This PR adds the ability to fix parameters of some parameterised gates in a GeneralEncoder.
This allows, for example, a single parameterised gate to have a fixed parameter, shared across all items in the batch, while all other parameters can be dynamically provided. The change is fully backwards compatible, and no changes need to be made to existing encoder definitions.
This supports ansatze which have some fixed gates which aren't Paulis or other named operators.
I expect this could already be achieved by subclassing existing operators, but I think this imposes less effort on the user.
Opening this to gauge interest. Shall update documentation and tests pending feedback.
This PR adds the ability to fix parameters of some parameterised gates in a
GeneralEncoder
.This allows, for example, a single parameterised gate to have a fixed parameter, shared across all items in the batch, while all other parameters can be dynamically provided. The change is fully backwards compatible, and no changes need to be made to existing encoder definitions.
This supports ansatze which have some fixed gates which aren't Paulis or other named operators. I expect this could already be achieved by subclassing existing operators, but I think this imposes less effort on the user.
Opening this to gauge interest. Shall update documentation and tests pending feedback.