Skip to main content

"Orquestra Cirq package"

Project description

orquestra-cirq

What is it?

orquestra-cirq is a Zapata library holding modules for integrating cirq and qsimcirq with Orquestra.

Installation

Even though it's intended to be used with Orquestra, orquestra-cirq can be also used as a Python module. To install it, make to install orquestra-quantum first. Then you just need to run pip install . from the main directory. If you want to import QSimSimulator, you have to install it with the extra dependencies by running pip install -e .[qsim].

Overview

orquestra-cirq is a Python module that exposes Cirq's and qsim's simulators as an orquestra QuantumSimulator. They can be imported with:

from orquestra.integrations.cirq.simulator import CirqSimulator
from orquestra.integrations.cirq.simulator import QSimSimulator

In addition, it interfaces with the noise models and provides converters that allow switching between cirq circuits and those of orquestra.

The module can be used directly in Python or in an Orquestra workflow. For more details, see the Orquestra Core docs.

For more information regarding Orquestra and resources, please refer to the Orquestra documentation.

Running on GPU

The parameters to configure GPU executions are supplied to QSimSimulator as QSimOptions. The details of these parameters can be found in qsimcirq python interface. Passing use_gpu=True will enable gpu. If you want to use NVIDIA's cuStateVec, please additionally pass gpu_mode=1 as can be seen in the example below:

from orquestra.integrations.cirq.simulator import QSimSimulator

from qsimcirq import QSimOptions

qsim_options = QSimOptions(use_gpu=True, gpu_mode=1)

sim = QSimSimulator(qsim_options=qsim_options)

CuStateVecSimulator is using QsimSimulator and by default is set to use_gpu=true and gpu_mode=1. Below is an example of importing CuStateVecSimulator:

from orquestra.integrations.custatevec.simulator import CuStateVecSimulator

sim = CuStateVecSimulator()

Development and contribution

You can find the development guidelines in the orquestra-quantum repository.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

orquestra_cirq-0.13.0.tar.gz (38.4 kB view details)

Uploaded Source

File details

Details for the file orquestra_cirq-0.13.0.tar.gz.

File metadata

  • Download URL: orquestra_cirq-0.13.0.tar.gz
  • Upload date:
  • Size: 38.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.5

File hashes

Hashes for orquestra_cirq-0.13.0.tar.gz
Algorithm Hash digest
SHA256 c627aee3d1120443bc5f6a833b703eb2fd1549c1c24d9979baca5cb672878cec
MD5 81ed733a999d2fdf799af053866064dd
BLAKE2b-256 9e8d814abdee602810caec5f1b6aaa1236d49eaaaafe60ef7856f8392a94c752

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page