Parallel Quantum Manager

This module defines the quantum manager class, to track quantum states.

The states may currently be defined in two possible ways:
  • KetState (with the QuantumManagerKet class)

  • DensityMatrix (with the QuantumManagerDensity class)

The manager defines an API for interacting with quantum states.

class parallel.src.p_quantum_manager.ParallelQuantumManagerDensity(states)

Class to track and manage states with the density matrix formalism.

remove(key: int) None

Method to remove state stored at key.

run_circuit(circuit: Circuit, keys: List[int], meas_samp=None) Dict[int, int]

Method to run a circuit on a given set of quantum states.

Parameters:
  • circuit (Circuit) – quantum circuit to apply.

  • keys (List[int]) – list of keys for quantum states to apply circuit to.

  • meas_samp (float) – random sample used for measurement.

Returns:

dictionary mapping qstate keys to measurement results.

Return type:

Dict[int, int]

class parallel.src.p_quantum_manager.ParallelQuantumManagerKet(states)

Class to track and manage quantum states with the ket vector formalism.

remove(key: int) None

Method to remove state stored at key.

run_circuit(circuit: Circuit, keys: List[int], meas_samp=None) Dict[int, int]

Method to run a circuit on a given set of quantum states.

Parameters:
  • circuit (Circuit) – quantum circuit to apply.

  • keys (List[int]) – list of keys for quantum states to apply circuit to.

  • meas_samp (float) – random sample used for measurement.

Returns:

dictionary mapping qstate keys to measurement results.

Return type:

Dict[int, int]