Closed EllaCrane closed 2 years ago
Choosing numberofqubitspermode to be 2 here works fine, but setting it to 3 throws an error.
numberofqubitspermode
numberofmodes=2 numberofqubitspermode=3 qmr = c2qa.QumodeRegister(num_qumodes=numberofmodes, num_qubits_per_qumode=numberofqubitspermode) circuit = c2qa.CVCircuit(qmr) circuit.cv_bs(-1j, qmr[0], qmr[1])
Error: CircuitError: 'The amount of qubit(6)/clbit(0) arguments does not match the gate expectation (8).'
CircuitError: 'The amount of qubit(6)/clbit(0) arguments does not match the gate expectation (8).'
Resolve by adding the value to num_qubits e.g. num_qubits=len(qumode_a) + 1` in the definition of ParameterizedUnitaryGate
num_qubits
num_qubits=len(qumode_a)
Choosing
numberofqubitspermode
to be 2 here works fine, but setting it to 3 throws an error.Error:
CircuitError: 'The amount of qubit(6)/clbit(0) arguments does not match the gate expectation (8).'