Circuit.pop_qudit

Circuit.pop_qudit(qudit_index)[source]

Pop a qudit from the circuit and all gates attached to it.

Parameters:

qudit_index (int) – The index of the qudit to pop.

Raises:
  • IndexError – If qudit_index is out of range.

  • ValueError – If circuit only has one qudit.