Skip to main content

No project description provided

Project description

Randomized benchmarking for 1-qubit and 2-qubit

PyPI version

Install

Install from pypi

pip install rb_generator

Install from source

pip install .

Packaging

python setup.py bdist_wheel

Find wheel file in dist/rb_generator_xxxx.whl

Usage

See test.

rb22.get_full_sequence_and_inverse_sequence

rb22 = rb_generator.RB22()

# Open file first
if not rb22.load_from_file('./rb22.dat'):
    print('load failed')
    exit(0)

# Define the clifford length
clifford_length = 100

# Generate a random sequence (each element in [0, N-1], N is the size of the clifford group)
cliffords = np.random.randint(0, rb22.N, clifford_length)
sequence, inverse_sequence = rb22.get_full_sequence_and_inverse_sequence(cliffords)

print(sequence)
print(inverse_sequence)
# You will obtain the following two outputs

# sequence = [3, 6, 5, 4, 1, 4, 4, 5, 2, 5, 3, 4, 3, 3, 6, 5, 6, 5, 4, 5, 1, 6, 3, 4, 5, 4, 4, 3, 5, 4, 3, 4, 5, 4, 6, 2, 3, 3, 4, 1, 4, 6, 5, 3, 3, 6, 3, 1, 6, 3, 6, 6, 5, 4, 3, 3, 4, 5, 4, 5, 5, 6, 4, 5, 0, 6, 5, 2, 5, 5, 4, 3, 6, 5, 2, 3, 5, 3, 6, 3, 4, 3, 4, 5, 3, 6, 6, 5, 3, 4, 5, 4, 3, 0, 3, 4, 3, 4, 2, 3, 2, 5, 1, 6, 4, 5, 6, 5, 3, 3, 6, 3, 5, 6, 5, 4, 5, 4, 3, 6, 3, 6, 5, 5, 4, 4, 5, 2, 2, 2, 1, 6, 6, 2, 3, 4, 3, 4, 5, 6, 6, 3, 6, 3, 4, 1, 4, 3, 6, 3, 0, 6, 5, 4, 5, 6, 3, 3, 4, 3, 4, 5, 6, 5, 6, 3, 2, 3, 6, 3, 0, 1, 6, 5, 6, 2, 3, 5, 4, 5, 6, 5, 6, 5]

# inverse_sequence = [5, 6]

"sequence" means the operation sequence for generating the RB sequence. "inverse_sequence" means the operation sequence for inverting the sequence to identity.

rb44.get_full_sequence_and_inverse_sequence

Same as the version of rb22.

For the definition of basic generators

They are generated by C++ enums. Find them in clifford22.h and clifford44.h

enum Generator22Enum : int
{
    Generator_I22,
    Generator_X,
    Generator_Y,
    Generator_SX,
    Generator_SY,
    Generator_SXdag,
    Generator_SYdag,
};
enum Generator44Enum : int
{
    Generator_I44,
    Generator_XI,
    Generator_IX,
    Generator_YI,
    Generator_IY,
    Generator_SX_I,
    Generator_SXdag_I,
    Generator_I_SX,
    Generator_I_SXdag,
    Generator_SY_I,
    Generator_SYdag_I,
    Generator_I_SY,
    Generator_I_SYdag,
    Generator_CZ,
};

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

rb_generator-0.1.0-cp314-cp314-win_amd64.whl (123.5 kB view details)

Uploaded CPython 3.14Windows x86-64

rb_generator-0.1.0-cp314-cp314-win32.whl (114.5 kB view details)

Uploaded CPython 3.14Windows x86

rb_generator-0.1.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (302.6 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

rb_generator-0.1.0-cp313-cp313-win_amd64.whl (120.1 kB view details)

Uploaded CPython 3.13Windows x86-64

rb_generator-0.1.0-cp313-cp313-win32.whl (111.3 kB view details)

Uploaded CPython 3.13Windows x86

rb_generator-0.1.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (302.6 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

rb_generator-0.1.0-cp312-cp312-win_amd64.whl (120.1 kB view details)

Uploaded CPython 3.12Windows x86-64

rb_generator-0.1.0-cp312-cp312-win32.whl (111.3 kB view details)

Uploaded CPython 3.12Windows x86

rb_generator-0.1.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (302.6 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

rb_generator-0.1.0-cp311-cp311-win_amd64.whl (119.1 kB view details)

Uploaded CPython 3.11Windows x86-64

rb_generator-0.1.0-cp311-cp311-win32.whl (110.3 kB view details)

Uploaded CPython 3.11Windows x86

rb_generator-0.1.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (302.6 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

rb_generator-0.1.0-cp310-cp310-win_amd64.whl (119.2 kB view details)

Uploaded CPython 3.10Windows x86-64

rb_generator-0.1.0-cp310-cp310-win32.whl (110.4 kB view details)

Uploaded CPython 3.10Windows x86

rb_generator-0.1.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (302.6 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

File details

Details for the file rb_generator-0.1.0-cp314-cp314-win_amd64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 051753d950112e43740bad29e54bbe4d2a5b3ec2033ca9534a2fed2b23ec5555
MD5 c3278658af0afd4b5404dd4fb4def92e
BLAKE2b-256 7724664e268c977c1efd8f13ab1cbd8c832ae647b129de1866977e89c5e4ebbb

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp314-cp314-win_amd64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp314-cp314-win32.whl.

File metadata

  • Download URL: rb_generator-0.1.0-cp314-cp314-win32.whl
  • Upload date:
  • Size: 114.5 kB
  • Tags: CPython 3.14, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rb_generator-0.1.0-cp314-cp314-win32.whl
Algorithm Hash digest
SHA256 01fd25d9878a92243bf5664a0a4c7bd8b041273cdf608477e2125e612c83e170
MD5 04f54795d28576c498deb586ad717911
BLAKE2b-256 ae9e80567294e7e59d2628fdaf6ee93f16febf7ce467d93af366a5e54614a68b

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp314-cp314-win32.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 8f794630c1147670eba709d2969e8a0f57e9d95deafa3ed03025272ae442d4b6
MD5 3e80e79d883b190faea32df85eca498e
BLAKE2b-256 e16871c7991e06b30ac5ec47460458f6860682546d1ad23a3d81e948b35d6bad

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 0455c56482adcb30da005cd65c1165e4f4ace96e09a0fa155a79e7e4504bec86
MD5 205e8714b26ac9377e502b1cef8027be
BLAKE2b-256 a8e6f48f834500af25595483c5326de158173cb8534fb82d5e8392749989a435

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp313-cp313-win_amd64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp313-cp313-win32.whl.

File metadata

  • Download URL: rb_generator-0.1.0-cp313-cp313-win32.whl
  • Upload date:
  • Size: 111.3 kB
  • Tags: CPython 3.13, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rb_generator-0.1.0-cp313-cp313-win32.whl
Algorithm Hash digest
SHA256 64befed493577a4f5452c03ffb59ad31077775ef6110d7ffdbfc46794180d805
MD5 571c49388109661dea60e266ba5e02dd
BLAKE2b-256 5fe3d3e3eb4fc7b596e7950897b3d93038413161052e831d95e17c5d2fb488bb

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp313-cp313-win32.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 0ed3758a2b511800007b6890b26179c3c8549af424873bb04ed171f4924e4863
MD5 191805be19d04415dc0c92047f917780
BLAKE2b-256 ebc341d0004e8fdffcf521f8a4b70bb18261c373c9d9b6901abdbb75e6fd23c5

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 68593eb26c86cfa795453b4a0c9b1cf26d641e480d5680532c2948bd8015ec72
MD5 7804c175136b80c625ad1c4eb0726070
BLAKE2b-256 d63623f8c0e3f31ae998c1cf2fa5f9ba9cac7a69e6943bd204eac7c123a643ba

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp312-cp312-win_amd64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp312-cp312-win32.whl.

File metadata

  • Download URL: rb_generator-0.1.0-cp312-cp312-win32.whl
  • Upload date:
  • Size: 111.3 kB
  • Tags: CPython 3.12, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rb_generator-0.1.0-cp312-cp312-win32.whl
Algorithm Hash digest
SHA256 585bef845b904f971ff24c08f197e6cb3553603d83476b552df7584da8bbfbd8
MD5 e0c85e1c58d10b72970d14c82805916c
BLAKE2b-256 fd8b5d1c977fbb38e04f201fcf33fa7706e5646ea2c757d923787d85c5243cf6

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp312-cp312-win32.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 2dd1d11a37180a78bbcd09ea06effbe4ec57a5ea59c35a5a77e617fd4145b88b
MD5 9c2d65e1620f7bc1f03a8b1d34ae41fe
BLAKE2b-256 df1c3bd53d3787d50ab5323c9fc9d17caf716bc3d48ed32140f1b70f4ce96402

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 e41ef32cf972228b4a8c0f6fce6c52bfc3a23c037c8323e9bf5d94f3e2ca3556
MD5 ef54bb07d551ec07e81d2dbcb6f68809
BLAKE2b-256 311dd4387c9e651b32fbe776bc2ad0898a5f80424dd6f48e5829df2558779676

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp311-cp311-win_amd64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp311-cp311-win32.whl.

File metadata

  • Download URL: rb_generator-0.1.0-cp311-cp311-win32.whl
  • Upload date:
  • Size: 110.3 kB
  • Tags: CPython 3.11, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rb_generator-0.1.0-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 26932184f6ac81d5509e82a7d2cfd0dfb937dfe524ae386e59779b0afaa39656
MD5 9162299cf34dfbda4d44c535e8c268fa
BLAKE2b-256 b3c82e8ddbb588ffe52424de996ed75af7a89ed2ecaa90486209e8f5766617de

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp311-cp311-win32.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 0f8ed6a84608ab8c84d160c6cfad4641f1ad3e74aa5e214df7520358892c2679
MD5 95ccbfddcdd61527d8f92f9df4bb657a
BLAKE2b-256 dbdd63ba921f1e6111077dd55ef0a0dd3d7584c5062d7d2a72cad0c3034d9c97

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 6be74221e859c5c942cf2c3cb1328611e13dfedcbd80f870d3d4a6d0c000e21c
MD5 4ada0b18266394db2e9acc7775e9766d
BLAKE2b-256 81ecc25c41b8477866aea8cf230bf50254684e5213807d91b62872f6b321b44f

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp310-cp310-win_amd64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp310-cp310-win32.whl.

File metadata

  • Download URL: rb_generator-0.1.0-cp310-cp310-win32.whl
  • Upload date:
  • Size: 110.4 kB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rb_generator-0.1.0-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 7d3b55b771d828b70a3ed1ab3f8001aee550363727cd231668ad9ec3df5815ee
MD5 58f3ebcb1aaa0674ee7929850b9af720
BLAKE2b-256 6bca7b96593f735c5e3549ae862bfab6bedc259427db7fcbf5e1d35ad5039466

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp310-cp310-win32.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rb_generator-0.1.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for rb_generator-0.1.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 c920b17b11c96d336da23bebd8e24126935345837bd9c36d2f5c29a244999f62
MD5 25795e29c19b138ed18a99d6d30a3e80
BLAKE2b-256 5665efef22c1a8e1bf403c222f5f554929155568f6f985ee604918fab7fb6e19

See more details on using hashes here.

Provenance

The following attestation bundles were made for rb_generator-0.1.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on Agony5757/rb_generator

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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