class pyquil.api.QPU(endpoint=None, user='pyquil-user', priority=1, *, session=None)[source]

A connection to the QPU.

  • endpoint (Optional[str]) – Address to connect to the QPU server. If not provided, the endpoint provided by engagement with dispatch is used. One or both must be available and valid.

  • user (str) – A string identifying who’s running jobs.

  • priority (int) – The priority with which to insert jobs into the QPU queue. Lower integers correspond to higher priority.

  • session (Optional[ForestSession]) – ForestSession object, which manages engagement and configuration.