Skip to main content

Software for developing quantum computing programs

Project description

Qiskit Terra

LicenseBuild StatusCoverage Status

Qiskit is an open-source framework for working with noisy quantum computers at the level of pulses, circuits, and algorithms.

Qiskit is made up of elements that work together to enable quantum computing. This element is Terra and is the foundation on which the rest of Qiskit is built.

Installation

We encourage installing Qiskit via the pip tool (a python package manager), which installs all Qiskit elements, including Terra.

pip install qiskit

PIP will handle all dependencies automatically and you will always install the latest (and well-tested) version.

To install from source, follow the instructions in the documentation.

Creating Your First Quantum Program in Qiskit Terra

Now that Qiskit is installed, it's time to begin working with Terra.

We are ready to try out a quantum circuit example, which is simulated locally using the Qiskit BasicAer element. This is a simple example that makes an entangled state.

$ python
>>> from qiskit import *
>>> qc = QuantumCircuit(2, 2)
>>> qc.h(0)
>>> qc.cx(0, 1)
>>> qc.measure([0,1], [0,1])
>>> backend_sim = BasicAer.get_backend('qasm_simulator')
>>> transpiled_qc = transpile(qc, backend_sim)
>>> result = backend_sim.run(assemble(transpiled_qc)).result()
>>> print(result.get_counts(qc))

In this case, the output will be:

{'00': 513, '11': 511}

A script is available here, where we also show how to run the same program on a real quantum computer via IBMQ.

Executing your code on a real quantum chip

You can also use Qiskit to execute your code on a real quantum chip. In order to do so, you need to configure Qiskit for using the credentials in your IBM Q account:

Configure your IBMQ credentials

  1. Create an IBM Q > Account if you haven't already done so.

  2. Get an API token from the IBM Q website under My Account > API Token and the URL for the account.

  3. Take your token and url from step 2, here called MY_API_TOKEN, MY_URL, and run:

    >>> from qiskit import IBMQ
    >>> IBMQ.save_account('MY_API_TOKEN', 'MY_URL')
    

After calling IBMQ.save_account(), your credentials will be stored on disk. Once they are stored, at any point in the future you can load and use them in your program simply via:

>>> from qiskit import IBMQ
>>> IBMQ.load_account()

Those who do not want to save their credentials to disk should use instead:

>>> from qiskit import IBMQ
>>> IBMQ.enable_account('MY_API_TOKEN')

and the token will only be active for the session. For examples using Terra with real devices we have provided a set of examples in examples/python and we suggest starting with using_qiskit_terra_level_0.py and working up in the levels.

Contribution Guidelines

If you'd like to contribute to Qiskit Terra, please take a look at our contribution guidelines. This project adheres to Qiskit's code of conduct. By participating, you are expected to uphold this code.

We use GitHub issues for tracking requests and bugs. Please join the Qiskit Slack community and use our Qiskit Slack channel for discussion and simple questions. For questions that are more suited for a forum we use the Qiskit tag in the Stack Exchange.

Next Steps

Now you're set up and ready to check out some of the other examples from our Qiskit Tutorials repository.

Authors and Citation

Qiskit Terra is the work of many people who contribute to the project at different levels. If you use Qiskit, please cite as per the included BibTeX file.

Changelog and Release Notes

The changelog for a particular release is dynamically generated and gets written to the release page on Github for each release. For example, you can find the page for the 0.9.0 release here:

https://github.com/Qiskit/qiskit-terra/releases/tag/0.9.0

The changelog for the current release can be found in the releases tab: The changelog provides a quick overview of notable changes for a given release.

Additionally, as part of each release detailed release notes are written to document in detail what has changed as part of a release. This includes any documentation on potential breaking changes on upgrade and new features. For example, You can find the release notes for the 0.9.0 release in the Qiskit documentation here:

https://qiskit.org/documentation/release_notes.html#terra-0-9

License

Apache License 2.0

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

qiskit-terra-0.16.1.tar.gz (8.1 MB view details)

Uploaded Source

Built Distributions

qiskit_terra-0.16.1-cp38-cp38-win_amd64.whl (7.8 MB view details)

Uploaded CPython 3.8Windows x86-64

qiskit_terra-0.16.1-cp38-cp38-win32.whl (7.8 MB view details)

Uploaded CPython 3.8Windows x86

qiskit_terra-0.16.1-cp38-cp38-manylinux2010_x86_64.whl (8.6 MB view details)

Uploaded CPython 3.8manylinux: glibc 2.12+ x86-64

qiskit_terra-0.16.1-cp38-cp38-manylinux2010_i686.whl (8.6 MB view details)

Uploaded CPython 3.8manylinux: glibc 2.12+ i686

qiskit_terra-0.16.1-cp38-cp38-macosx_10_9_x86_64.whl (7.8 MB view details)

Uploaded CPython 3.8macOS 10.9+ x86-64

qiskit_terra-0.16.1-cp37-cp37m-win_amd64.whl (7.8 MB view details)

Uploaded CPython 3.7mWindows x86-64

qiskit_terra-0.16.1-cp37-cp37m-win32.whl (7.8 MB view details)

Uploaded CPython 3.7mWindows x86

qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_x86_64.whl (8.5 MB view details)

Uploaded CPython 3.7mmanylinux: glibc 2.12+ x86-64

qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_i686.whl (8.5 MB view details)

Uploaded CPython 3.7mmanylinux: glibc 2.12+ i686

qiskit_terra-0.16.1-cp37-cp37m-macosx_10_9_x86_64.whl (7.8 MB view details)

Uploaded CPython 3.7mmacOS 10.9+ x86-64

qiskit_terra-0.16.1-cp36-cp36m-win_amd64.whl (7.8 MB view details)

Uploaded CPython 3.6mWindows x86-64

qiskit_terra-0.16.1-cp36-cp36m-win32.whl (7.8 MB view details)

Uploaded CPython 3.6mWindows x86

qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_x86_64.whl (8.5 MB view details)

Uploaded CPython 3.6mmanylinux: glibc 2.12+ x86-64

qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_i686.whl (8.5 MB view details)

Uploaded CPython 3.6mmanylinux: glibc 2.12+ i686

qiskit_terra-0.16.1-cp36-cp36m-macosx_10_9_x86_64.whl (7.8 MB view details)

Uploaded CPython 3.6mmacOS 10.9+ x86-64

File details

Details for the file qiskit-terra-0.16.1.tar.gz.

File metadata

  • Download URL: qiskit-terra-0.16.1.tar.gz
  • Upload date:
  • Size: 8.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit-terra-0.16.1.tar.gz
Algorithm Hash digest
SHA256 9b07cedef6e2d62eabf003447b1338887af7ebbf4f2bebfe7d0b3581d0e9afd4
MD5 73a3fded420bf712696064d5b7604d61
BLAKE2b-256 ae70f92b0678bc8e294bdecf1956d4145625ac07d185c207a270b57fa5d8afe7

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for qiskit_terra-0.16.1-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 2d2f7011e69b562af9e3616573248e0d6886e8ac4f1d99277baac0ba0a2cabe3
MD5 0c0b7fa673595f81c791258b0e9d9235
BLAKE2b-256 672e9a70a2d88aa141350c94b866adccb2e34a5e2567d9b6a7ae37f3a3de887a

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp38-cp38-win32.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp38-cp38-win32.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.8, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for qiskit_terra-0.16.1-cp38-cp38-win32.whl
Algorithm Hash digest
SHA256 d59801668ae1cb0bfe672faeab30ec4760a68aa73733c92f95b798104e9f9e86
MD5 9ff1b835ee71341f145360f0a7015a8e
BLAKE2b-256 1475f4a707cd50ed087b4c1a98f368b5982e8156d19dd224550a35bfceb35613

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp38-cp38-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp38-cp38-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 8.6 MB
  • Tags: CPython 3.8, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp38-cp38-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 f50dc4b9cad2d015579526b0d997dd449a9f4501a836a45e7f7f50cf9cbc65af
MD5 d814685a63887bcfb941971d8944197b
BLAKE2b-256 73f0bb166bf322fba3511c881c0d3b930350a00ab26c21650374b4b21e46c5a4

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp38-cp38-manylinux2010_i686.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp38-cp38-manylinux2010_i686.whl
  • Upload date:
  • Size: 8.6 MB
  • Tags: CPython 3.8, manylinux: glibc 2.12+ i686
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp38-cp38-manylinux2010_i686.whl
Algorithm Hash digest
SHA256 5864e80587239570191cf994a2d3284313e72ab5a87a9d5c2ccd789d0e419307
MD5 e1db7b35a741d2caa655df4203c60307
BLAKE2b-256 bf0216d1370f6b1696c51a4ea3e4ae0f466ad4a6a7a668930ccffb44b4a023bd

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp38-cp38-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.8, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 4cb4aa27abf79f4c04e44c49149349e77d39ebea9dc0a9b60e902eff5c150451
MD5 d6f0c36c29f48d3ea711076c29e9b433
BLAKE2b-256 0bf7cc0a5e28797e2499ddc8068a1555c49f82d146fa5161b9e44c1a60e5d3cc

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for qiskit_terra-0.16.1-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 584e7e69a830c497668de0e249d427520c1f74af984c3e1af3fc364175daca35
MD5 793ac5799ac0d867f8a0b437753f8b6d
BLAKE2b-256 197d0482a7f3c6916b3a29fcd51b29dc883ab6cef5cee6eeb026c677cfcbc343

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp37-cp37m-win32.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp37-cp37m-win32.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for qiskit_terra-0.16.1-cp37-cp37m-win32.whl
Algorithm Hash digest
SHA256 157fc830cc8f678dec9f7f92c1cf55b1a64cb65b1ed93384cdceae232d8533ef
MD5 d52d6152fbde407e7a2fa9aa1f28c30f
BLAKE2b-256 9821482a5bba453a2c0dac8d5719732358481ef6bbf3092098f811d706d21370

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 8.5 MB
  • Tags: CPython 3.7m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 8ae81663818981643508f868a42036503efce8719bdd997a9ad71a21bdbc8682
MD5 827c1dc42693d6751257a0ccd7964ba4
BLAKE2b-256 e8fc0954577ef9f64eb5f99a348cd193be4bc30b95104b73de05d4cc59e80551

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_i686.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_i686.whl
  • Upload date:
  • Size: 8.5 MB
  • Tags: CPython 3.7m, manylinux: glibc 2.12+ i686
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp37-cp37m-manylinux2010_i686.whl
Algorithm Hash digest
SHA256 3ba2b06bf88d1fefa677298d4f91446d138133d002c83548595da4f893fdbbf0
MD5 d107b1711be50ae263f03e65f33745c5
BLAKE2b-256 07da93419e7a1df9f2900a15f17f64a323e264de352ec61386f01db5a9a089b1

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp37-cp37m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.7m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 7b0e565313b0a11e5c31b1cafaf3ba26a218f3cbc027e8f6311e66fc231549df
MD5 1068de2710bc556f570113e9667a0228
BLAKE2b-256 1ac9c5d6c9f623250729a76eab48e1e69977f6c67aeb6bb8513701d1b419e64e

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for qiskit_terra-0.16.1-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 b716f8681c5c429341a8098f156a6274147bbad52d661a3b2dfb77948badbe5d
MD5 304dc832da6a7ba037de6bbf954eadd2
BLAKE2b-256 2193f41abafccfb8d45e665d9961ffd5840ba91ba0744b87882bef338f8b8cb2

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp36-cp36m-win32.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp36-cp36m-win32.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.6m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for qiskit_terra-0.16.1-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 8927d92307f476b75f662956926e5836be0f636f84e6f6575c325c54bee9ffec
MD5 b7c9de32e77e31c5776130d348aa852d
BLAKE2b-256 5acccc1c3f2c066798f29b3b706e5c7bac688d72e0a931cf0e71dd6354b70c96

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 8.5 MB
  • Tags: CPython 3.6m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 a0d666117a015ceb838741806c841a97b00866b72741d00af98dd3a56009862d
MD5 55ba5520cc8264e61fee6c3be4ecef7f
BLAKE2b-256 6691813c0b986fa953d09ff58c74a7948bf9d52c64497319746bb4a1bb0e7f3a

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_i686.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_i686.whl
  • Upload date:
  • Size: 8.5 MB
  • Tags: CPython 3.6m, manylinux: glibc 2.12+ i686
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp36-cp36m-manylinux2010_i686.whl
Algorithm Hash digest
SHA256 63a9c47d6ecbf796840b960abd542e5680fa39e322e9d21f525c452a487bcbc0
MD5 991fc4a52790c24e141fe8b05ef39e82
BLAKE2b-256 ebbeef0649b48f5be5e97a7e6ae71579992fe1e2c7c21e2bb4f9b32d0ac249da

See more details on using hashes here.

File details

Details for the file qiskit_terra-0.16.1-cp36-cp36m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qiskit_terra-0.16.1-cp36-cp36m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 7.8 MB
  • Tags: CPython 3.6m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for qiskit_terra-0.16.1-cp36-cp36m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 226afa8568233e6082b82b0e20e5bed6e737837c3d303f9440b4128a80c06448
MD5 35dfafcd8243e564146996d2795c6f49
BLAKE2b-256 79bc43ad183ef242853c8268e7c413dc8561b15476bba5d1c8842be25a13ee6e

See more details on using hashes here.

Supported by

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