waveforms
Form waveforms used in experiment.
Installation
We encourage installing waveforms via the pip tool (a python package manager):
python -m pip install waveforms
To install from the latest source, you need to clone the GitHub repository on your machine.
git clone https://github.com/feihoo87/waveforms.git
Then dependencies and waveforms can be installed in this way:
cd waveforms
python -m pip install numpy
python -m pip install -e .
Usage
import numpy as np
import matplotlib.pyplot as plt
from waveforms import *
pulse = cosPulse(20e-9)
x_wav = zero()
y_wav = zero()
I, Q = mixing(0.5*pulse, freq=-20e6, DRAGScaling=0.2)
x_wav += I
y_wav += Q
I, Q = mixing(pulse >> 1e-6, freq=-20e6, phase=np.pi/2, DRAGScaling=0.2)
x_wav += I
y_wav += Q
I, Q = mixing((0.5 * pulse) >> 2e-6, freq=-20e6, DRAGScaling=0.2)
x_wav += I
y_wav += Q
t = np.linspace(-1e-6, 9e-6, 10001)
plt.plot(t, x_wav(t))
plt.plot(t, y_wav(t))
plt.show()
Packed binary representation
Starting with version 3, Waveform and WaveVStack use a packed-binary backend.
It is intended for workloads with many small pulses and for low-overhead
serialization.
import waveforms as wf
# Optional; call this once, before constructing or loading waveform objects.
wf.set_time_resolution(1e-12)
pulse = (wf.gaussian(12e-9) >> 20e-9) * wf.cos(2 * wf.pi * 5e9)
data = pulse.to_bytes()
restored = wf.Waveform.from_bytes(data)
Time resolution is process-wide and is not stored in each binary block. A process loading a block must therefore use the same resolution as the process that created it. The setting is locked when the first waveform object is created or loaded.
Reporting Issues
Please report all issues on github.
License
Metadata
Release files for waveforms 3.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| waveforms-3.0.0.tar.gz | 44.9 kB | Details |
Built distributions (wheels)
Total release size: 22.7 MB
Release files / waveforms-3.0.0.tar.gz
| Download URL | waveforms-3.0.0.tar.gz |
|---|---|
| Size | 44.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1bd250afa22221c63df0dff21b89875bc23a6a84d3049d91f183e9acab8ece12
|
|
BLAKE2b-256 checksum How to use checksums |
61ea9791412f65f71f519b7dc53f1d75cf8f7235be11346aaefced49e909f4e5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.15
|
Release files / waveforms-3.0.0-cp314-cp314t-win_amd64.whl
| Download URL | waveforms-3.0.0-cp314-cp314t-win_amd64.whl |
|---|---|
| Size | 325.8 kB |
| Tags | CPython 3.14 CPython 3.14 free-threading Windows x86-64 |
|
SHA-256 checksum How to use checksums |
d377904f81cd272fcd5d9549faf3fa111ef6841774787a104ae7631e28a95cb7
|
|
BLAKE2b-256 checksum How to use checksums |
18142a88ddbdf0f00cb2107eafa31f4352799c76d1d4a4d729b88fbbb2055fb4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / waveforms-3.0.0-cp314-cp314t-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl
| Download URL | waveforms-3.0.0-cp314-cp314t-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.7 MB |
| Tags | CPython 3.14 CPython 3.14 free-threading Linux glibc 2.17+ x86-64 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
c99b772f5a658625f805f5ed3817cd2adf1a03ec3ccc199834405969f02c9022
|
|
BLAKE2b-256 checksum How to use checksums |
1d866f62fa675380ffbd5895663646562a3d1f240231b335609d6a04546643c9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / waveforms-3.0.0-cp314-cp314t-macosx_10_15_universal2.whl
| Download URL | waveforms-3.0.0-cp314-cp314t-macosx_10_15_universal2.whl |
|---|---|
| Size | 781.4 kB |
| Tags | CPython 3.14 CPython 3.14 free-threading macOS 10.15+ universal2 (ARM64, x86-64) |
|
SHA-256 checksum How to use checksums |
3438906593708802df8d702e53a201bd1fde6ad7555d7f7b204434882cb83f49
|
|
BLAKE2b-256 checksum How to use checksums |
2a70b9b572c2497ea95f6f334b2ae04f30af6425f7a089bc64adc90de9c2e6c4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / waveforms-3.0.0-cp314-cp314-win_amd64.whl
| Download URL | waveforms-3.0.0-cp314-cp314-win_amd64.whl |
|---|---|
| Size | 300.4 kB |
| Tags | CPython 3.14 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
5ff2add08ebf61397a988181c3d6cb7fe5892d7a85f53e2dd439793fdffa4f44
|
|
BLAKE2b-256 checksum How to use checksums |
aecbcd94836a66592e2c16bc6f9f0be11c47d837fb863c596bc0e32904c74213
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / waveforms-3.0.0-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl
| Download URL | waveforms-3.0.0-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.14 Linux glibc 2.17+ x86-64 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
c9861186deee974a82707636d97a46c8b4348c52b2934354f5076ab202ad72bc
|
|
BLAKE2b-256 checksum How to use checksums |
4d4ab6b0c03fe98c8e6b7262784a4afcc85f8f35b81ba277a9043fbc76a44971
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / waveforms-3.0.0-cp314-cp314-macosx_10_15_universal2.whl
| Download URL | waveforms-3.0.0-cp314-cp314-macosx_10_15_universal2.whl |
|---|---|
| Size | 744.0 kB |
| Tags | CPython 3.14 macOS 10.15+ universal2 (ARM64, x86-64) |
|
SHA-256 checksum How to use checksums |
71377d84073faa86b1f2ba38a2c35b75602728adeb916571f5ba0f57a11d3c73
|
|
BLAKE2b-256 checksum How to use checksums |
51df7d948536c851f180297eb3bcfee7e64a46d1d516b438ef6e45dbb2e2d353
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|
Release files / waveforms-3.0.0-cp313-cp313-win_amd64.whl
| Download URL | waveforms-3.0.0-cp313-cp313-win_amd64.whl |
|---|---|
| Size | 293.8 kB |
| Tags | CPython 3.13 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
7cae14d3133dc3728ec98782ea21e34f05be327f3ea16f69604663582627cbbb
|
|
BLAKE2b-256 checksum How to use checksums |
6c2f799797c1102371bde770c7d1a9c290e73dd76d0811c26487fc79f6eb6aec
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.15
|
Release files / waveforms-3.0.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl
| Download URL | waveforms-3.0.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.7 MB |
| Tags | CPython 3.13 Linux glibc 2.17+ x86-64 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
235078b32b4488f7383e9320f8b1e7607ae494aed940726aa1f714a21c2a2978
|
|
BLAKE2b-256 checksum How to use checksums |
af9cbd6f4a97ef57276ad9efc37620dcf029515ef9b4f16caaac9fe41ac82e8a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.15
|
Release files / waveforms-3.0.0-cp313-cp313-macosx_10_13_universal2.whl
| Download URL | waveforms-3.0.0-cp313-cp313-macosx_10_13_universal2.whl |
|---|---|
| Size | 740.6 kB |
| Tags | CPython 3.13 macOS 10.13+ universal2 (ARM64, x86-64) |
|
SHA-256 checksum How to use checksums |
76bd2e72cfffbac7eb7255381dfef61ed50dd502281385950b9b11dcf4a03934
|
|
BLAKE2b-256 checksum How to use checksums |
0c5ebb6069a1c2865dc9ec70d4b52d6c0bc71204bc84cbf5626b6aa8eb12cc0c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / waveforms-3.0.0-cp312-cp312-win_amd64.whl
| Download URL | waveforms-3.0.0-cp312-cp312-win_amd64.whl |
|---|---|
| Size | 294.6 kB |
| Tags | CPython 3.12 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
422df5c25aed0fbaf38038817e65202d98c42058f662c74a67c6b7e7eef101f3
|
|
BLAKE2b-256 checksum How to use checksums |
2ef596e446968fa9e7f489268e6866cd988b6f95c964d1b33e59b72e7cdafe57
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.10
|
Release files / waveforms-3.0.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl
| Download URL | waveforms-3.0.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.12 Linux glibc 2.17+ x86-64 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
bd27009e1efd4ebbba22c62fc32f9a57609199b7f4050329eebd1d7984bac927
|
|
BLAKE2b-256 checksum How to use checksums |
0a6c722fdb202e53eb756496c9c1f230c5c416536fd7a3e61336de784280af9b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.14
|
Release files / waveforms-3.0.0-cp312-cp312-macosx_10_13_universal2.whl
| Download URL | waveforms-3.0.0-cp312-cp312-macosx_10_13_universal2.whl |
|---|---|
| Size | 741.5 kB |
| Tags | CPython 3.12 macOS 10.13+ universal2 (ARM64, x86-64) |
|
SHA-256 checksum How to use checksums |
611c1b2a385016ced4df2b32a14d99c81b7d82206fdebdde1c07bce7fad12428
|
|
BLAKE2b-256 checksum How to use checksums |
1683244b96d19cf9b6cbb3418ce3e5b730e21ec85d3d490a08f9e4f19872b6a4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.10
|
Release files / waveforms-3.0.0-cp311-cp311-win_amd64.whl
| Download URL | waveforms-3.0.0-cp311-cp311-win_amd64.whl |
|---|---|
| Size | 325.4 kB |
| Tags | CPython 3.11 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
3bd9b0ca9252db5e3dc101c5879944714f35f0b41232f0ac8b60c76d75a75e36
|
|
BLAKE2b-256 checksum How to use checksums |
f2e602cefc39aac4e94fb9e919a784e6eb36b7acf62704c17d930b49a28c422a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.9
|
Release files / waveforms-3.0.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl
| Download URL | waveforms-3.0.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.9 MB |
| Tags | CPython 3.11 Linux glibc 2.17+ x86-64 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
18a7f05f93a1cca2c173acfa4364cdc35e70a036b7a68ab1b628cc7e9b6c82b4
|
|
BLAKE2b-256 checksum How to use checksums |
6145891949f32f6bee18c6c10f9da4c183f97974a4e8447b711b82d0dbf0e806
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.16
|
Release files / waveforms-3.0.0-cp311-cp311-macosx_10_9_universal2.whl
| Download URL | waveforms-3.0.0-cp311-cp311-macosx_10_9_universal2.whl |
|---|---|
| Size | 729.1 kB |
| Tags | CPython 3.11 macOS 10.9+ universal2 (ARM64, x86-64) |
|
SHA-256 checksum How to use checksums |
6e511dc053a7cd8a395630839b4ce7d31d5b187e1a11a7991f311a644437a916
|
|
BLAKE2b-256 checksum How to use checksums |
765d64c97c623a0efdde28f7a6b991e2809cae29832f823a528a96b7860b2f29
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.9
|
Release files / waveforms-3.0.0-cp310-cp310-win_amd64.whl
| Download URL | waveforms-3.0.0-cp310-cp310-win_amd64.whl |
|---|---|
| Size | 326.0 kB |
| Tags | CPython 3.10 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
d9ef9e9dacde31e5d4c5b0475b6f681f87e28350ce3a9c3b3d0c1cdb78dad8d3
|
|
BLAKE2b-256 checksum How to use checksums |
859ac3bb03eb6c1cffd7a3a325382ab766f47a910e5f9748226381f55591efcd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.11
|
Release files / waveforms-3.0.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl
| Download URL | waveforms-3.0.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.8 MB |
| Tags | CPython 3.10 Linux glibc 2.17+ x86-64 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
876a9a8a235774a101f327a022d1dce0c1d1895dfa3ac88a6627ddd1c9a77e2a
|
|
BLAKE2b-256 checksum How to use checksums |
8c23fa347c8e2e50ff62d59c0390abd2b29027be37ef0852fd956012547d9d79
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.21
|
Release files / waveforms-3.0.0-cp310-cp310-macosx_10_9_universal2.whl
| Download URL | waveforms-3.0.0-cp310-cp310-macosx_10_9_universal2.whl |
|---|---|
| Size | 731.9 kB |
| Tags | CPython 3.10 macOS 10.9+ universal2 (ARM64, x86-64) |
|
SHA-256 checksum How to use checksums |
8b32738dbd7effbe5aa69a7516b07edafb40adaedf445ee1aac9afdd3aa3a94f
|
|
BLAKE2b-256 checksum How to use checksums |
4f421253dd0470955d229a1da2956d81dd2502bf196079ae6c2b0d7bec7869e6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.11
|