Skip to main content

High performance quantum sims on qudits

Project description

icon

qudit

High performance simulations for qudit systems. To make qudit machine learning, qudit error correction, and qudit circuit simulation easier. Qudit is made fully around numpy and pytorch to make it easy to mix and match tools without worrying about type errors.

PyPI version

pip install qudit

Quickstart

In most cases it should not matter if you mix and match numpy with qudit since most abstractions are built on top of numpy arrays. The following is two examples to do the same thing, one using the Circuit class and the other manually using the matrices.

Using the Circuit class:

from qudit import Circuit
import numpy as np

C = Circuit(2, dim=2)  # 2 qBits with d=2
G = C.gates[2]

C.gate(G.H, dits=[0])
C.gate(G.CX, dits=[0, 1])

ket0 = np.zeros(2**2)
ket0[0] = 1.0  # |00>

print(C(ket0))  # [1. 0. 0. 1.]/rt2

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

qudit-0.2.0.tar.gz (18.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

qudit-0.2.0-py3-none-any.whl (23.1 kB view details)

Uploaded Python 3

File details

Details for the file qudit-0.2.0.tar.gz.

File metadata

  • Download URL: qudit-0.2.0.tar.gz
  • Upload date:
  • Size: 18.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for qudit-0.2.0.tar.gz
Algorithm Hash digest
SHA256 84ece44662e0896bbc62f8d222365166ea861abf04eff750707f02e53307cf63
MD5 3747559aa56379ccb5769a7479a4f56c
BLAKE2b-256 89f5c0664e042595eb19d60161c4cc06f7a6da2a2c3cac5ac0cbbcc85c04f3fa

See more details on using hashes here.

File details

Details for the file qudit-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: qudit-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 23.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for qudit-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a3d4ad38f776f07e515a72f0150bbed200f57c7d7ef6fbce016eb4a3e8a91d89
MD5 87dcdae94678cc238ba9da0eddb0a104
BLAKE2b-256 69174b5948ef65aaabc80c46e4e0f92653c3c646cd9e78a766e77a009e174846

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