pyquil.api.QPU

class pyquil.api.QPU(endpoint, user='pyquil-user')[source]

A connection to the QPU.

Parameters:
  • endpoint (str) – Address to connect to the QPU server.
  • user (str) – A string identifying who’s running jobs.
__init__(endpoint, user='pyquil-user')[source]

A connection to the QPU.

Parameters:
  • endpoint (str) – Address to connect to the QPU server.
  • user (str) – A string identifying who’s running jobs.
Return type:

None

Methods

__init__(endpoint[, user]) A connection to the QPU.
get_version_info() Return version information for this QPU’s execution engine and its dependencies.
load(executable) Initialize a QAM into a fresh state.
read_from_memory_region(*, region_name) Reads from a memory region named region_name on the QAM.
read_memory(*, region_name) Reads from a memory region named region_name on the QAM.
reset() Reset the Quantum Abstract Machine to its initial state, which is particularly useful when it has gotten into an unwanted state.
run() Run a pyquil program on the QPU.
wait() Blocks until the QPU enters the halted state.
write_memory(*, region_name[, offset, value]) Writes a value into a memory region on the QAM at a specified offset.