High performance quantum sims on qudits
Project description
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.
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
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file qudit-0.1.1.tar.gz.
File metadata
- Download URL: qudit-0.1.1.tar.gz
- Upload date:
- Size: 20.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
18aef2798e647b7430f1d125d824467bc3f623e0257eb35c7cd72328d615c27a
|
|
| MD5 |
63e52b49b894c35ef8e39adec1ff8d2f
|
|
| BLAKE2b-256 |
cf89eec0352ac436f2fa4deb7b0d5bb4b873991fd91d388684b7dbeb7be94f62
|
File details
Details for the file qudit-0.1.1-py3-none-any.whl.
File metadata
- Download URL: qudit-0.1.1-py3-none-any.whl
- Upload date:
- Size: 25.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8682050557c3ad19a94282b1609f213edde19f3739591262a2fee36a604ac946
|
|
| MD5 |
2ac0ac7219b388981d23470994025ec2
|
|
| BLAKE2b-256 |
250bcf6cf93799174ee1b4dd26d2177c853f4def4dafbff194baf9a3e2547e98
|