Hi,
When using qml.probs() at the end of a circuit, am I correct in thinking you don’t have to specify shots when using default.qubit?
And will qml.probs() also work with lightning.qubit?
Thanks again
Hi,
When using qml.probs() at the end of a circuit, am I correct in thinking you don’t have to specify shots when using default.qubit?
And will qml.probs() also work with lightning.qubit?
Thanks again
Hi @James_Ellis!
When using qml.probs() at the end of a circuit, am I correct in thinking you don’t have to specify shots when using default.qubit?
That’s right. If shots aren’t specified (and analytic=True
), then the probabilities returned are exact, and computed directly from the statevector.
Instead, if analytic=False
and a finite number of shots requested, then the probabilities will be estimated based on the samples generated by the device.
And will qml.probs() also work with lightning.qubit?
It will