Level 6 · Practitioner’s Corner
Choosing Your First Quantum Framework
About 4,882 words · roughly 22 minute read · sources checked December 2, 2026
Beginners often spend days asking which framework to learn. The honest answer is that the choice matters less than it seems, because all of them describe the same physics with different syntax. But the choice does affect which hardware you can reach, which tutorials you can follow, and how quickly you get working results, so it is worth making on purpose.
This lesson explains what a framework actually does, shows the same two-qubit circuit written for each of five toolkits, compares them using the vendors’ own documentation, and gives a decision guide by goal. Where I could open a documentation page I say so. Code samples for toolkits other than Qiskit are written from my knowledge of their standard usage and were not run in this session, and the lesson marks them clearly.
You need the first Qiskit lesson in this level, which supplies the comparison point.
What you will learn
- What a quantum framework does and which layers are separate from it.
- How the same circuit looks in Qiskit, Cirq, PennyLane, Braket and Q#.
- What each of the five main toolkits says it is for, from its documentation.
- Which free options exist for simulators and for hardware access.
- Which differences, such as bit order, can silently change your results when you switch.
- A decision guide by goal, and a plan for the first month.
Helpful first: Your First Qiskit Circuit, Reading a Quantum Circuit Diagram, Quantum Hardware.
What a framework does (and does not do)
A quantum programming framework is a software library. It lets you describe circuits, simulate them, convert them into forms that a device accepts, and send them to a backend. It does not change what a qubit is. The physics, the gates and the results are the same in every toolkit.
This is why the framework is not the main hurdle. Learning to think in circuits, amplitudes and measurement is the hard part, and that knowledge transfers. A person who can write a Bell circuit in one toolkit can write it in another after a short look at the documentation.
Frameworks do differ in three ways that matter in practice. First, which hardware you can reach easily. Second, how much help they give for the kind of work you want to do, such as chemistry, machine learning or error-correction research. Third, how large their community and tutorial base is, which decides how fast you get unstuck.
The same circuit in five toolkits
The best comparison is the same small program. Each sample below prepares the Bell state (|00⟩ + |11⟩)/√2 and samples it. I computed the expected result: only the outcomes 00 and 11, each with probability 0.5, in every toolkit. The Qiskit code follows IBM’s documented example. The others are from my knowledge, unrun, and marked as such.
Qiskit
from qiskit import QuantumCircuit from qiskit.primitives import StatevectorSampler qc = QuantumCircuit(2) qc.h(0); qc.cx(0, 1); qc.measure_all() counts = StatevectorSampler().run([(qc, None, 1000)]).result()[0].data.meas.get_counts()
Cirq (from memory, not run)
import cirq a, b = cirq.LineQubit.range(2) circuit = cirq.Circuit(cirq.H(a), cirq.CNOT(a, b), cirq.measure(a, b, key='m')) result = cirq.Simulator().run(circuit, repetitions=1000) print(result.histogram(key='m'))
PennyLane (from memory, not run)
import pennylane as qml
dev = qml.device('default.qubit', wires=2, shots=1000)
@qml.qnode(dev)
def bell():
qml.Hadamard(wires=0)
qml.CNOT(wires=[0, 1])
return qml.counts()
print(bell())Amazon Braket (from memory, not run)
from braket.circuits import Circuit from braket.devices import LocalSimulator circuit = Circuit().h(0).cnot(0, 1) result = LocalSimulator().run(circuit, shots=1000).result() print(result.measurement_counts)
Q# (from memory, not run)
operation Bell() : (Result, Result) {
use (a, b) = (Qubit(), Qubit());
H(a);
CNOT(a, b);
return (MResetZ(a), MResetZ(b));
}Look at what stays the same. Every sample allocates two qubits, applies a Hadamard to the first, a CNOT from the first to the second, and measures. The vocabulary (H, CNOT, measure, shots) is shared. The differences are in how qubits are named, how measurement results are returned, and how a backend is chosen.
The main candidates, in their own words
The summaries below stick to what each vendor’s page said when I opened it. I have not tried to rank them, because the right choice depends on your goal.
Qiskit (IBM)
IBM’s tools page describes the Qiskit SDK as the core open-source library for working with quantum circuits, operators and primitives, with modules for circuit building, a circuit library, quantum information tools, the transpiler and the primitives. Running on IBM hardware goes through the IBM Quantum Compute Service, which the page says was formerly called the Qiskit Runtime Service. The page also lists ecosystem projects that work with Qiskit but are not part of it, such as Qiskit Aer for simulation and mthree for measurement mitigation. IBM’s plans page says the Open Plan includes the equivalent of up to 10 minutes of quantum processor time per 28-day rolling window.
Strengths for a beginner: a very large amount of documentation and tutorials, a clear path from a simulator to real hardware, and the primitives model used throughout this course. Cautions: the software changed a great deal between versions 0.x, 1.0 and 2.0, so older tutorials break.
Cirq (Google)
Google’s Cirq introduction describes it as a framework for writing quantum algorithms for noisy intermediate-scale quantum (NISQ) devices, and says programs should take a device’s architectural properties into account. Its key ideas are qubits as identifiers (LineQubit, GridQubit, NamedQubit), gates that become operations when applied to qubits, moments as groups of operations in the same time slice, and circuits as ordered sequences of moments.
Strengths: an explicit model of time (moments) and of device layout, which makes it a good tool for thinking about hardware constraints and for research on noise. Cautions: the page I opened is a short introduction, and I did not check which hardware an outside user can currently reach through Cirq.
PennyLane (Xanadu)
The PennyLane introduction page describes an open-source Python library for quantum computing, quantum machine learning and quantum chemistry, and says it lets you train quantum circuits much like neural networks. It highlights built-in automatic differentiation of circuits and says the same circuit can be run on different backends. It lists integrations with PyTorch, JAX and NumPy. The plugin list on that page also names products that look dated, so check its current device list.
Strengths: if your interest is variational algorithms or quantum machine learning, differentiating a circuit with respect to its parameters is a built-in feature. Cautions: it is less focused on low-level control of a particular device.
Amazon Braket (AWS)
The Braket page describes a service that gives access to multiple types of quantum computers: superconducting devices from IQM and Rigetti, ion-trap devices from IonQ, and a QuEra Rydberg atom array for analog Hamiltonian simulation. It offers a free local simulator included in the Braket SDK, and on-demand simulators named SV1 (state vector, up to 34 qubits), DM1 (noisy, up to 16 qubits) and TN1 (tensor network, up to 50 qubits). The page also mentions PennyLane, Qiskit and CUDA-Q plugins and says hardware pricing depends on the number of tasks and shots.
Strengths: one account for several hardware technologies, which is useful for comparing devices. Cautions: it is a paid cloud service beyond its free tier, and it requires an AWS account.
Microsoft Quantum Development Kit and Q#
Microsoft’s overview describes the QDK as a free open-source kit for writing, simulating, debugging and running quantum programs, connected to Azure Quantum to reach real quantum computers. It lists language support, simulators and noise models, a circuit editor, a quantum resource estimator and quantum error correction among its features, with a VS Code extension and a Python package, and says you can write and run Q# or OpenQASM programs. The page has no code samples or hardware-submission details.
Strengths: a dedicated language and a resource estimator, which suit people interested in the cost of large algorithms. Cautions: Q# is a separate language to learn, with fewer third-party tutorials than Qiskit.
An older comparison
In 2018, LaRose compared four platforms of the time (Forest, Qiskit, ProjectQ and the Quantum Developer Kit with Q#) on installation, syntax, libraries, simulators and hardware access. The paper is a good model of how to compare, but every toolkit has changed since, so do not use its conclusions today.
Side by side
| Toolkit | Language | Described focus | Free simulation | Hardware route (from the pages above) |
|---|---|---|---|---|
| Qiskit | Python | General circuits, primitives, transpiler | Exact simulators in the SDK; Aer as a separate package | IBM Quantum Compute Service; Open Plan up to 10 minutes per 28 days |
| Cirq | Python | NISQ devices, moments, device layout | Built-in simulator | Not checked here |
| PennyLane | Python | Differentiable circuits, quantum ML and chemistry | Built-in default devices | Through plugins to other providers |
| Amazon Braket | Python SDK | Multi-vendor cloud hardware | Free local simulator; 1 hour per month of on-demand simulator in the free tier | IQM, Rigetti, IonQ and QuEra devices, priced per task and shot |
| QDK / Q# | Q# and Python | Language support, resource estimation, error correction | Simulators and noise models | Azure Quantum |
A comparison based on the documentation pages I opened. A blank in a cell means I did not verify it, not that it is absent.
Worked example
What the simulator limits mean in memory
- Braket lists SV1 as a state-vector simulator up to 34 qubits. A state vector of 34 qubits has 2³⁴ = 1.7 × 10¹⁰ amplitudes. At 16 bytes per amplitude (double precision complex numbers), that is about 275 GB. With single precision it would be about 137 GB. The page does not say which is used, so this is my arithmetic.
- DM1 simulates noise with a density matrix, which has 4ⁿ entries. For 16 qubits that is 4¹⁶ = 4.3 × 10⁹ entries, about 68.7 GB at 16 bytes each. This is why the noisy simulator’s limit is far lower than the noiseless one’s.
- TN1 reaches 50 qubits by using a tensor-network method, which works only for circuits with limited entanglement. A full state vector at 50 qubits would need about 18 petabytes, as the table in the previous lesson showed.
- None of these numbers matter for a first Bell circuit. They matter when you ask why a simulator stops at a given size, and they show that a cloud simulator is mostly renting memory.
A decision guide by goal
| If your main goal is… | A sensible first choice | Why |
|---|---|---|
| Learning the concepts and the standard tutorials | Qiskit | The most documentation, and a direct path to real hardware on a free plan |
| Running on real hardware at no cost to start | Qiskit (IBM Open Plan) | The plans page states a free allowance of QPU time |
| Comparing different hardware technologies | Amazon Braket | One service lists superconducting, ion-trap and neutral-atom devices |
| Variational algorithms or quantum machine learning | PennyLane | Automatic differentiation of circuits is a core feature |
| Thinking about device layout and time structure | Cirq | Moments and device-aware qubits are central to its model |
| Estimating the cost of a large algorithm | QDK with its resource estimator | The overview lists a resource estimator among the features |
| Not sure yet | Qiskit, then read one Cirq or PennyLane tutorial | Seeing a second toolkit makes the shared structure obvious |
A starting guide, not a ranking.
My honest advice for this course
The lessons here use Qiskit conventions, because they are the most widely documented and because hardware access is free to start. Pick it unless you have a reason from the table above. You can always read the others later.
The same Bell pair in three frameworks
The best way to compare frameworks is to write the same small circuit in each. Below is a Bell pair measured 1,000 times, in Qiskit, Cirq and PennyLane. I wrote these from my knowledge of the three libraries' documented interfaces. None of them is installed in my environment, so I did not run them, and interface details can change between versions. Check each against the version you install.
# Qiskit (not run) from qiskit import QuantumCircuit from qiskit_aer import AerSimulator qc = QuantumCircuit(2, 2) qc.h(0) qc.cx(0, 1) qc.measure([0, 1], [0, 1]) result = AerSimulator().run(qc, shots=1000).result() print(result.get_counts())
# Cirq (not run)
import cirq
q0, q1 = cirq.LineQubit.range(2)
circuit = cirq.Circuit(
cirq.H(q0),
cirq.CNOT(q0, q1),
cirq.measure(q0, q1, key='m'),
)
result = cirq.Simulator().run(circuit, repetitions=1000)
print(result.histogram(key='m'))# PennyLane (not run)
import pennylane as qml
dev = qml.device('default.qubit', wires=2, shots=1000)
@qml.qnode(dev)
def bell():
qml.Hadamard(wires=0)
qml.CNOT(wires=[0, 1])
return qml.counts()
print(bell())The three programs have the same structure: make two qubits, apply H to the first, apply CNOT, measure, run many times, print counts. What differs is the style. Qiskit builds a circuit object and sends it to a backend. Cirq builds a circuit from a list of operations on named qubits. PennyLane wraps a Python function as a quantum node that can also be differentiated, which is why it is popular for variational and machine-learning work.
| Aspect | Qiskit | Cirq | PennyLane |
|---|---|---|---|
| Style | Circuit object, then run | Circuit from operations | Decorated function |
| Qubit naming | Integers | Qubit objects | Wire labels |
| Printed bit order | Qubit 0 on the right | Order of the measured list | Wire order |
| Strength (my summary) | Hardware access and tutorials | Fine control of gate layouts | Gradients for optimisation |
A comparison from my reading of the documentation style. The strengths row is my summary and not a ranking.
Check the bit order
A Bell pair gives 00 and 11 in any ordering, so it hides the bit-order difference. To see the difference, flip only qubit 0 and print the result. In Qiskit the string is '01'; in a library that prints qubit 0 on the left it is '10'. The widgets on this site use the Qiskit order.
Translating results between conventions
If two toolkits print the same physical result in opposite bit order, you need a reliable way to translate. For three qubits, a Qiskit key lists qubit 2, qubit 1 and qubit 0, left to right. A toolkit that lists the first qubit first would print the same outcome with the characters reversed. The table shows all eight cases, with the integer value each reading gives.
| Qiskit key (q2 q1 q0) | Reversed key (q0 q1 q2) | Integer, Qiskit reading | Integer, reversed reading |
|---|---|---|---|
| 000 | 000 | 0 | 0 |
| 001 | 100 | 1 | 4 |
| 010 | 010 | 2 | 2 |
| 011 | 110 | 3 | 6 |
| 100 | 001 | 4 | 1 |
| 101 | 101 | 5 | 5 |
| 110 | 011 | 6 | 3 |
| 111 | 111 | 7 | 7 |
The same eight outcomes in the two conventions. Four keys are palindromes and do not change; four do.
Notice that half of the outcomes look the same in both conventions. That is exactly why a bit-order bug can hide for a long time: circuits whose answers happen to be 000, 010, 101 or 111, which includes every GHZ and Bell result, pass without any sign of trouble. The first circuit that gives a different key shows the error.
Worked example
A quick translation recipe
- To convert a counts dictionary from one convention to the other, reverse every key string. In Python this is {k[::-1]: v for k, v in counts.items()}.
- To convert an integer outcome, reverse its n-bit binary string and read it again. For n = 3, 3 (011) becomes 6 (110).
- To avoid translating at all, choose one convention for your own notes, write it in a comment at the top of the notebook, and convert only at the boundary where a toolkit’s output enters your code.
What “differentiable” means, with numbers
PennyLane’s page highlights built-in automatic differentiation of quantum circuits. To see why that is a real feature and not a slogan, consider the simplest case, which can be worked by hand and which any toolkit can reproduce.
A single qubit starts in |0⟩, receives Ry(θ), and we measure the expectation value of Z. The result is f(θ) = cos θ, as in the parameter sweep of the first lesson. Training a circuit means adjusting θ to move f in a wanted direction, which needs the derivative df/dθ = −sin θ.
Worked example
Two ways to get the slope from noisy samples
- At θ = 0.7 the exact slope is −sin 0.7 = −0.6442.
- Finite differences: evaluate f at θ + h and θ − h and divide the difference by 2h. With a tiny h such as 0.01, the exact formula gives −0.6442, but each evaluation on a quantum device is a sample average with a standard deviation of up to 1/√N. With N = 1,000 shots the difference has a spread of up to √(2/N) = 0.045, and dividing by 2h = 0.02 magnifies it to about 2.2. The estimate is useless, since the true slope is 0.64.
- Parameter shift: for gates of this kind a standard result, which I did not look up in this session, says the exact slope is [f(θ + π/2) − f(θ − π/2)] / 2. I checked numerically that this gives −0.6442. The shifts are large, so the noise is not magnified: the spread is at most √(2/N)/2 = 0.022, which is 100 times smaller than for the small-step finite difference.
- So a toolkit that knows the parameter-shift rule gives usable gradients from a quantum device. That is what the ‘automatic differentiation of circuits’ feature provides, and why it matters for training.
You do not need this to write your first circuits. It explains why a toolkit built for variational work, and a toolkit built for general circuits, can differ in the tools they offer, even when the underlying circuits are identical.
Simulation cost: a measured example
Memory is one limit on simulation. Time is the other. To see how quickly the cost grows, I timed a minimal state-vector simulation that I wrote in NumPy: a layer of Hadamard gates on every qubit followed by a chain of CNOTs, on a single processor core of my working environment. This is not any framework’s simulator, and a tuned simulator would be faster, but the trend is what matters.
| Qubits | State size | Time (my NumPy code) |
|---|---|---|
| 10 | 16 KB | 0.0002 s |
| 14 | 0.26 MB | 0.003 s |
| 18 | 4.2 MB | 0.08 s |
| 20 | 16.8 MB | 0.41 s |
| 22 | 67 MB | 2.5 s |
| 24 | 268 MB | 13.7 s |
Measured wall-clock time for 2n gates in a simple state-vector simulator written for this lesson. The state size is 2ⁿ × 16 bytes.
Every extra qubit doubles the memory, and in this test it cost roughly 2.4 times as much time per qubit at the larger sizes, since memory traffic dominates. Two more qubits cost about five or six times as much time. Extrapolating the trend, 30 qubits would need 17 GB and tens of minutes with this unoptimised code, and 40 would be out of reach. Optimised simulators in the toolkits push the limit higher, but the doubling cannot be avoided.
What to take from this
If your toolkit’s simulator is slow, the cause is usually the number of qubits and not the toolkit. The remedy is smaller test circuits, or a method suited to your circuit’s structure, not switching framework.
A five-test acceptance suite for any toolkit
Whatever toolkit you pick, run the same five small tests before trusting it. Each has an exact answer that I computed, so you can check your setup, conventions and understanding in one sitting. If you later switch toolkit, rerun the suite and compare.
| Test | Circuit | Expected exact result | What it checks |
|---|---|---|---|
| 1. Bell pair | H on qubit 0, CNOT(0 → 1), measure | Only 00 and 11, each 0.5. ⟨ZZ⟩ = +1, ⟨ZI⟩ = 0 | Superposition, entanglement and sampling |
| 2. Bit order | X on index 1 of two qubits, measure | Qiskit: key '10' with probability 1. Another convention may print '01' | How results are ordered |
| 3. Rotation | Ry(π/3) on |0⟩, measure | P(1) = sin²(π/6) = 0.25, ⟨Z⟩ = cos(π/3) = 0.5 | Angle units and rotation direction |
| 4. Interference | H, Rz(π/2), H, measure | P(1) = sin²(π/4) = 0.5 | Phase turning into probability |
| 5. Ghz | H on 0, then CNOT(0,1), CNOT(1,2), measure | Only 000 and 111, each 0.5 | Multi-qubit gates and order |
A portable acceptance suite. All expected values were computed with matrices.
Worked example
How to use the suite
- Write each test in your chosen toolkit. Run with 4,096 shots, so the sampling spread on a 0.5 outcome is about 32 counts, or 0.8 percentage points.
- For test 3, the count of ‘1’ should be near 1,024, with a spread of √(4,096 × 0.25 × 0.75) = 27.7. A count of 1,100 would be 2.7 spreads away and would be worth investigating, perhaps as an angle given in the wrong units.
- For test 2, the result tells you your toolkit’s bit order. Write it at the top of your notebook.
- Keep the five tests in a file. After any upgrade, rerun them. If one fails, the change in the toolkit is the first suspect.
Two other checks cost nothing. The Estimator or its equivalent should give ⟨ZZ⟩ = 1 for test 1, and the parameter-shift estimate of the slope of ⟨Z⟩ for Ry(θ) at θ = 0.7 should be −0.6442, if the toolkit provides gradients. Both numbers appear earlier in this course.
A translation table for gate names
The names of gates differ in small ways. The table lists the usual spellings as I know them. I did not verify each against current documentation, so treat it as a starting point and check the toolkit’s reference.
| Operation | Qiskit | Cirq | PennyLane | Braket SDK | Q# |
|---|---|---|---|---|---|
| Hadamard | qc.h(0) | cirq.H(q) | qml.Hadamard(wires=0) | Circuit().h(0) | H(q) |
| Pauli X | qc.x(0) | cirq.X(q) | qml.PauliX(wires=0) | Circuit().x(0) | X(q) |
| CNOT | qc.cx(0, 1) | cirq.CNOT(a, b) | qml.CNOT(wires=[0, 1]) | Circuit().cnot(0, 1) | CNOT(a, b) |
| Z rotation | qc.rz(t, 0) | cirq.rz(t)(q) | qml.RZ(t, wires=0) | Circuit().rz(0, t) | Rz(t, q) |
| Measure | qc.measure_all() | cirq.measure(q, key='m') | qml.counts() or qml.probs() | run with shots | M(q) or MResetZ(q) |
Usual spellings from memory. Check each against the current documentation before use; argument order for rotations differs between toolkits.
The one detail to watch is argument order. Some toolkits take the angle first and the qubit second, others the reverse. A swapped argument usually gives an error, but in a few cases it quietly rotates the wrong qubit.
Evaluating a tutorial before you follow it
- What is its date, and which version of the toolkit does it use?
- Does it print results and show the expected output, so you can compare?
- Does it explain the bit order, or at least avoid circuits where it matters?
- Does it use removed features? For Qiskit, check against the 1.0 and 2.0 notes: execute, the Aer import, BasicAer, V1 primitives, BackendV1 and c_if.
- Does it say what to expect on hardware as opposed to a simulator?
A tutorial that scores well on these five questions is worth following even if it uses a toolkit you did not choose, since the ideas carry over.
Moving between toolkits: what silently changes
The dangerous differences are not the syntax errors, which are loud, but the conventions that produce plausible wrong answers. Three are worth checking whenever you switch.
| Convention | What to check | A one-line test |
|---|---|---|
| Bit order of results | Qiskit puts qubit 0 on the right of a printed key. Other toolkits may list the first qubit first (leftmost). I believe some do, but did not verify it from a page I opened, so test it. | Apply X to the second qubit only and see whether the result is 01 or 10 |
| Gate names and angles | CNOT is cx in Qiskit. Rotation angles are in radians. Some toolkits define rotations differently, for example about different axes or with a different global phase. | Apply Rz(π) and Rx(π) and compare with Z and X |
| How results are returned | Counts dictionaries, histograms of integers, probability arrays, expectation values | Print the raw result for a one-gate circuit |
| Measurement and qubit allocation | Some toolkits make you declare qubits first, others infer them from the operations | Read the toolkit’s introduction page |
Things to check when you change framework.
Worked example
The one-gate test, with its expected answer
- Build a two-qubit circuit that applies X to the second qubit (index 1) only, then sample it.
- In Qiskit, IBM’s bit-ordering page gives the key '10' for this circuit. The leftmost character is qubit 1.
- A toolkit that writes the first qubit leftmost would print '01' for the same physical circuit. Both are correct for their own convention.
- Once you know the convention you can translate. Without the test, you may mistake a convention difference for a bug in the algorithm.
Keeping up as the tools change
- Pin versions in a requirements file and note the version in your notebook. Tutorials break when versions move, as the Qiskit 1.0 and 2.0 notes showed.
- Read the release notes when you upgrade. The Qiskit 2.0 release notes list removals clearly, and other toolkits publish similar notes.
- Prefer the documentation of your installed version over search results.
- Keep your circuits portable. OpenQASM is a text format for circuits that the Microsoft page lists as supported by the QDK, and Qiskit and other toolkits have also supported it; I did not open a page confirming current support in each, so check before relying on it.
- Keep tests: a few small circuits with known answers, such as the Bell state and the GHZ state, which you can rerun after any upgrade.
The transferable skill
What lasts is the ability to predict a circuit’s result by hand, to check it with a simulator and to interpret deviations on hardware. Those skills are the same in every toolkit.
A first-month plan
- Week 1: install the toolkit and run the Bell circuit on a simulator. Predict the result first. Repeat with a three-qubit GHZ circuit.
- Week 2: write the circuits from the Level 2 and 3 lessons, such as Deutsch–Jozsa and the two-qubit Grover, and check each against the exact answer from the lessons.
- Week 3: learn the parameter and Estimator workflow and reproduce the Ry sweep table from the first Qiskit lesson.
- Week 4: run one of the circuits on real hardware within the free allowance and compare the noisy counts with the simulator, using the checklist in the next lesson.
This plan is a suggestion and not a measured path. The point is to alternate between predicting, simulating and comparing, because that loop is what builds the intuition.
A learning exercise: translate between frameworks
Once you have one framework working, the fastest way to deepen your understanding is to translate a circuit into another. Translation forces you to see the circuit as an idea, separate from one library's syntax. I suggest three steps, using the Bell pair above as the starting point.
- Write the circuit in words: 'put qubit 0 in superposition, copy its value to qubit 1 with a CNOT, measure both.'
- Write it in your first framework and run it, checking for counts near 500 and 500 of 00 and 11.
- Rewrite it in a second framework from its documentation, without copying a tutorial, and compare the results, including the bit order.
Then change one thing in both versions, for example add an X gate on qubit 0 before the Hadamard, and predict the new counts before you run them. If both frameworks agree with your prediction, you have learned the circuit and not just the libraries. If they disagree, the difference is almost always notation, such as bit order or the meaning of an angle, and finding it is a lesson in itself.
Keep the exercise small. A Bell pair, a GHZ state and a one-qubit rotation are enough. The goal is not to master every library but to be able to read any quantum code you meet, which is the real skill behind the choice of a first framework.
Common mistakes when choosing
| Mistake | Better approach |
|---|---|
| Spending weeks comparing toolkits before writing a circuit | Pick Qiskit or follow your goal in the table, and start. You can switch later. |
| Following a tutorial without checking its version | Check the date and the library version first. |
| Judging a toolkit by hardware names alone | Check which devices you can actually reach on a free plan, and what the queue is like. |
| Assuming results are identical across toolkits | Check bit order, angle conventions and result formats. |
| Choosing based on one blog post | Use the vendor’s documentation for facts and several sources for opinions. |
| Committing to a paid cloud service before using the free tiers | Start with local simulators and free allowances. |
Mistakes in choosing a framework.
Extra practice: choosing a framework
Check yourself on the comparison above.
Check yourself
F1. What is the first thing to check when a Bell-pair result looks reversed between two libraries?
The bit order. Qiskit prints qubit 0 on the right, and some libraries print it on the left.
F2. Which of the three frameworks in the Bell example is built around differentiable functions?
PennyLane, whose quantum nodes can be differentiated for optimisation, per its documented design.
F3. Why did I label the code blocks 'not run'?
Because none of the three libraries is installed in my environment, so I could not execute them, and interface details can change between versions.
F4. How would you decide between frameworks for a first project?
Pick the one with the best tutorials for your goal and the hardware you plan to use, build the Bell pair in it, and switch only if you hit a clear limitation.
Practice problems
Check yourself
Which layer of the workflow does a framework mainly provide?
The layer where you describe circuits and call simulators and backends. The compiler and backend are often separate or swappable.
Apply X only to index 1 in a two-qubit Qiskit circuit. What key results?
'10'.
Why can the same physical circuit print different keys in two toolkits?
Their conventions for ordering qubits in a result may differ.
How much memory does an exact 34-qubit state vector need at 16 bytes per amplitude?
2³⁴ × 16 bytes ≈ 275 GB.
How much does a 16-qubit density matrix need at 16 bytes per entry?
4¹⁶ × 16 bytes ≈ 68.7 GB.
Which toolkit among those covered lists automatic differentiation of circuits as a headline feature?
PennyLane.
What does the IBM plans page say the Open Plan includes?
The equivalent of up to 10 minutes of quantum processor time per 28-day rolling window.
Give two reasons to keep a set of small test circuits.
To catch breakage after an upgrade and to check conventions when switching toolkit.
Why is the 2018 platform comparison not a good guide today?
All the toolkits have changed, and some it compared are no longer the main choices.
Name a situation where you would prefer Braket over a single-vendor toolkit.
When you want to compare several hardware technologies through one account.
References and further reading
I opened IBM’s page listing its tools (the Qiskit SDK, the IBM Quantum Compute Service and ecosystem projects such as Qiskit Aer and mthree), Google’s Cirq introduction, the PennyLane introduction page, the Amazon Braket getting-started page, Microsoft’s QDK overview page and the abstract of LaRose’s 2018 platform comparison. The Qiskit code follows IBM’s documentation examples. The Cirq, PennyLane, Braket and Q# code samples are from my own knowledge of their standard usage, and I did not run them or check them against current documentation, so confirm each against the toolkit’s own pages before relying on it. The Bell-state results that all the samples should produce were computed by me. Features, prices and device lists change often, so treat every vendor detail here as correct on the checking date only.
- IBM Quantum documentation: tools (IBM Quantum documentation) Opened. Qiskit SDK modules, the IBM Quantum Compute Service (formerly Qiskit Runtime Service), ecosystem projects such as Aer and mthree.
- IBM Quantum plans overview (IBM Quantum documentation) Opened. Open Plan: up to 10 minutes per 28-day rolling window.
- Introduction to Cirq (Google Quantum AI) Opened. A framework for NISQ algorithms; qubits, operations, moments, circuits; simulator run example.
- PennyLane documentation: introduction (Xanadu) Opened. Open-source library for quantum computing, machine learning and chemistry; automatic differentiation; ML library integrations. Its plugin list appears dated.
- Amazon Braket: getting started (Amazon Web Services) Opened. Devices from IQM, Rigetti, IonQ and QuEra; local simulator; SV1, DM1, TN1; free tier; pricing per task and shot.
- Microsoft Quantum Development Kit overview (Microsoft Learn) Opened. Free open-source kit; VS Code extension and Python package; Q# and OpenQASM; resource estimator; connection to Azure Quantum.
- Overview and Comparison of Gate Level Quantum Software Platforms (arXiv 1807.02500, R. LaRose, 2018) Abstract opened. Compared Forest, Qiskit, ProjectQ and the Quantum Developer Kit. Dated.
Key terms in the dictionary