Skip to main content

Classiq SDK Package

Reason this release was yanked:

Invalid Python requirements

Project description

Classiq

The Classiq Quantum Algorithm Design platform helps teams build sophisticated quantum circuits that could not be designed otherwise

We do this by synthesizing high-level functional models into optimized quantum circuits, taking into account the constraints that are important to the designer. Furthermore, we are able to generate circuits for practically any universal gate-based quantum computer and are compatible with most quantum cloud providers.

Requirements

Python 3.8+

Installation

pip install --upgrade pip
$ pip install 'classiq[all]'

Example

from classiq import generator
from classiq.builtin_functions import StatePreparation, QFT
from classiq_interface.generator.state_preparation import (
    PMF,
    Metrics,
    NonNegativeFloatRange,
)

circuit_generator = generator.Generator(qubit_count=20, max_depth=100)

probabilities = (0.5, 0.1, 0.2, 0.005, 0.015, 0.12, 0.035, 0.025)
pmf = PMF(pmf=probabilities)
sp_params = StatePreparation(
    probabilities=pmf,
    num_qubits=4,
    error_metric={Metrics.KL: NonNegativeFloatRange(upper_bound=0.3)},
)

output_dict = circuit_generator.StatePreparation(params=sp_params)

state_preparation_output = output_dict["OUT"]

qft_params = QFT(num_qubits=3)
circuit_generator.QFT(
    params=qft_params, in_wires={"IN": state_preparation_output}
)

circuit = circuit_generator.generate()
circuit.show()

License

See license.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

classiq-0.4.0.tar.gz (25.8 kB view details)

Uploaded Source

Built Distribution

classiq-0.4.0-py3-none-any.whl (34.1 kB view details)

Uploaded Python 3

File details

Details for the file classiq-0.4.0.tar.gz.

File metadata

  • Download URL: classiq-0.4.0.tar.gz
  • Upload date:
  • Size: 25.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.11 CPython/3.8.12 Linux/5.11.0-1022-azure

File hashes

Hashes for classiq-0.4.0.tar.gz
Algorithm Hash digest
SHA256 c16d92973ecb0cb538de827ca355b48909364206697f9719bd44908aeed0ece9
MD5 685fcd272430fe9ae81471a0b1028bbd
BLAKE2b-256 b670b1a3b60c9e8236088f6b59b6a1dc3d32229229a442af372c22eaab7d77c7

See more details on using hashes here.

File details

Details for the file classiq-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: classiq-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 34.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.11 CPython/3.8.12 Linux/5.11.0-1022-azure

File hashes

Hashes for classiq-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f1f7587d1d649ba0d760238c59631f6313dc036b58f939ca3b24da1bdb99c645
MD5 bf85960f748b737a142114c2b13a599f
BLAKE2b-256 5990469482c87f14752b340ea53626257ee7dca9dd04cafde82a25a75d06007f

See more details on using hashes here.

Supported by

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