CircuitHelpers
- braket.circuits.circuit_helpers.validate_circuit_and_shots(circuit, shots)[source]
Validates if circuit and shots are correct before running on a device
- Parameters:
circuit (Circuit) – circuit to validate
shots (int) – shots to validate
- Raises:
ValueError – If circuit has no instructions; if circuit has a non-gphase instruction; if no result types specified for circuit and
shots=0. Seebraket.circuit.result_types; if circuit has observables that cannot be simultaneously measured andshots>0; or, ifStateVectororAmplitudeare specified as result types whenshots>0.- Return type:
None