Here’s a minimal working example of some code that tries to create a PyTorch layer using the native gateset provided by the
import pennylane as qml from pennylane_ionq import ops # quantum circuit setup nqbits = 1 device = qml.device('ionq.simulator', wires=nqbits) @qml.qnode(device=device, interface='torch', diff_method='best') def circuit(inputs): # feature encoding layer ops.GPI2(inputs, wires=0) return [qml.expval(qml.PauliZ(0))] circuit([1.0])
Unfortunately it returns the following error, which seems odd, as one would think the IonQ simulator would support its own native gateset
pennylane._device.DeviceError: Gate GPI2 not supported on device ionq.simulator
Can anyone help shed some light on this issue?