Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
quantum
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lifo
Nicolas Ollinger
quantum
Commits
90bd9ac2
Commit
90bd9ac2
authored
Dec 08, 2019
by
Nicolas Ollinger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
essai
parent
8a7c30d7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
337 additions
and
0 deletions
+337
-0
qistest.ipynb
notebooks/qistest.ipynb
+337
-0
No files found.
notebooks/qistest.ipynb
0 → 100644
View file @
90bd9ac2
{
"cells": [
{
"cell_type": "code",
"execution_count": 2,
"metadata": {
"slideshow": {
"slide_type": "slide"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n",
"Total count are: {'00': 505, '11': 495}\n"
]
},
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAr4AAADrCAYAAACPW5UYAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjIsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy8li6FKAAAgAElEQVR4nO3deXRU9f3/8VcWwmLClgQChCUQAiQSEoNKEQMRWpai8GWJslRKoWAILXjoRlsBoaXueKiAUkTa4qE/lojarxb7rRDANQG0YTPSIEloBGSpJCKQyfz+SIMGE5KZZOYzd+7zcQ5HZ+Yu78SPb1755N7PDXA6nU4BAAAAfi7QdAEAAACANxB8AQAA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"<Figure size 911.6x292.4 with 1 Axes>"
]
},
"execution_count": 2,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"import numpy as np\n",
"from qiskit import(\n",
" QuantumCircuit,\n",
" execute,\n",
" Aer)\n",
"from qiskit.visualization import plot_histogram\n",
"\n",
"# Use Aer's qasm_simulator\n",
"simulator = Aer.get_backend('qasm_simulator')\n",
"\n",
"# Create a Quantum Circuit acting on the q register\n",
"circuit = QuantumCircuit(2,2)\n",
"\n",
"circuit.h(0)\n",
"circuit.barrier()\n",
"circuit.h(0)\n",
"circuit.h(1)\n",
"circuit.cx(1,0)\n",
"circuit.h(0)\n",
"circuit.h(1)\n",
"circuit.barrier()\n",
"circuit.measure([0,1], [0,1])\n",
"\n",
"# Execute the circuit on the qasm simulator\n",
"job = execute(circuit, simulator, shots=1000)\n",
"\n",
"# Grab results from the job\n",
"result = job.result()\n",
"\n",
"# Returns counts\n",
"counts = result.get_counts(circuit)\n",
"print(\"\\nTotal count are:\",counts)\n",
"\n",
"# Draw the circuit\n",
"circuit.draw(output='mpl',scale=1)\n",
"\n"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {
"slideshow": {
"slide_type": "slide"
}
},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAc0AAAE9CAYAAABp1zkEAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjIsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy8li6FKAAAgAElEQVR4nO3de3hV9Z3v8fe34VKwgIRmMKlFilCKSGmUY6dW8VY82hln6mVqe7Ta6bSe1movjrWXsfZyps4ZbXt0PO2IzsVLrbW2Tq/D6GNhyoi2thAzImkKReAAkUZERECC8Xv+2BsmxiSsQG4k79fz7Cd7/9ZvrXyXebYf1lq/9VuRmUiSpH17VX8XIEnSwcLQlCSpIENTkqSCDE1JkgoyNCVJKs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p/3mkqZcpf7l+AoymNOvP79pPkVee9OAvMvMt/VCipDYi4lZKs3RdB5wDXAwcCTQC/wr8DJgO3JiZI/qrzsHCI029TGbuBP4KGAXcAVwUEa+PiNfA3sEEJwHL+69KSQARMYzSmaFnM3N1Zn41M2cB/w34OaUA/S5wE3Bn/1U6eHikqQ6VT+N8HvgTShO1PwI0A+8AmoAPZubj/VehJICIGA9MzMzflGfs2t12QFBEnA/cDRyTmY/1V52DhaGpLpVvP/kj4F2UpsxbDtybmb/p18Ikdao8a1dkZmtEfIjSqdnR/V3XYGBoqjAfASYdfCLiCqAiM6/v71oGA0NTkgaxiBgOtPoP3p5haEqSVJCjZyVJKsjQlCSpIENTkqSCDE1JkgoyNCVJKsjQlCSpoP8P3xnuwro7BbIAAAAASUVORK5CYII=\n",
"text/plain": [
"<Figure size 504x360 with 1 Axes>"
]
},
"execution_count": 3,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Plot a histogram\n",
"plot_histogram(counts)"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {
"slideshow": {
"slide_type": "slide"
}
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Help on method draw in module qiskit.circuit.quantumcircuit:\n",
"\n",
"draw(scale=0.7, filename=None, style=None, output=None, interactive=False, line_length=None, plot_barriers=True, reverse_bits=False, justify=None, vertical_compression='medium', idle_wires=True, with_layout=True, fold=None, ax=None) method of qiskit.circuit.quantumcircuit.QuantumCircuit instance\n",
" Draw the quantum circuit\n",
" \n",
" **text**: ASCII art TextDrawing that can be printed in the console.\n",
" \n",
" **latex**: high-quality images compiled via latex.\n",
" \n",
" **latex_source**: raw uncompiled latex output.\n",
" \n",
" **matplotlib**: images with color rendered purely in Python.\n",
" \n",
" Args:\n",
" scale (float): scale of image to draw (shrink if < 1)\n",
" filename (str): file path to save image to\n",
" style (dict or str): dictionary of style or file name of style\n",
" file. This option is only used by the ``mpl`` output type. If a\n",
" str is passed in that is the path to a json file which contains\n",
" that will be open, parsed, and then used just as the input\n",
" dict. See: :ref:`Style Dict Doc <style-dict-circ-doc>` for more\n",
" information on the contents.\n",
" output (str): Select the output method to use for drawing the\n",
" circuit. Valid choices are ``text``, ``latex``,\n",
" ``latex_source``, or ``mpl``. By default the `'text`' drawer is\n",
" used unless a user config file has an alternative backend set\n",
" as the default. If the output kwarg is set, that backend\n",
" will always be used over the default in a user config file.\n",
" interactive (bool): when set true show the circuit in a new window\n",
" (for `mpl` this depends on the matplotlib backend being used\n",
" supporting this). Note when used with either the `text` or the\n",
" `latex_source` output type this has no effect and will be\n",
" silently ignored.\n",
" line_length (int): Deprecated, see `fold` which supersedes this\n",
" option. Sets the length of the lines generated by `text` output\n",
" type. This useful when the drawing does not fit in the console.\n",
" If None (default), it will try to guess the console width using\n",
" ``shutil.get_terminal_size()``. However, if you're running in\n",
" jupyter the default line length is set to 80 characters. If you\n",
" don't want pagination at all, set ``line_length=-1``.\n",
" reverse_bits (bool): When set to True reverse the bit order inside\n",
" registers for the output visualization.\n",
" plot_barriers (bool): Enable/disable drawing barriers in the output\n",
" circuit. Defaults to True.\n",
" justify (string): Options are ``left``, ``right`` or\n",
" ``none``, if anything else is supplied it defaults to left\n",
" justified. It refers to where gates should be placed in the\n",
" output circuit if there is an option. ``none`` results in\n",
" each gate being placed in its own column.\n",
" vertical_compression (string): ``high``, ``medium`` or ``low``. It\n",
" merges the lines generated by the ``text`` output so the\n",
" drawing will take less vertical room. Default is ``medium``.\n",
" Only used by the ``text`` output, will be silently ignored\n",
" otherwise.\n",
" idle_wires (bool): Include idle wires (wires with no circuit\n",
" elements) in output visualization. Default is True.\n",
" with_layout (bool): Include layout information, with labels on the\n",
" physical layout. Default is True.\n",
" fold (int): Sets pagination. It can be disabled using -1.\n",
" In `text`, sets the length of the lines. This useful when the\n",
" drawing does not fit in the console. If None (default), it will\n",
" try to guess the console width using ``shutil.\n",
" get_terminal_size()``. However, if running in jupyter, the\n",
" default line length is set to 80 characters. In ``mpl`` is the\n",
" number of (visual) layers before folding. Default is 25.\n",
" ax (matplotlib.axes.Axes): An optional Axes object to be used for\n",
" the visualization output. If none is specified a new matplotlib\n",
" Figure will be created and used. Additionally, if specified\n",
" there will be no returned Figure since it is redundant. This is\n",
" only used when the ``output`` kwarg is set to use the ``mpl``\n",
" backend. It will be silently ignored with all other outputs.\n",
" \n",
" Returns:\n",
" :class:`PIL.Image` or :class:`matplotlib.figure` or :class:`str` or\n",
" :class:`TextDrawing`:\n",
" \n",
" * `PIL.Image` (output='latex')\n",
" an in-memory representation of the image of the circuit\n",
" diagram.\n",
" * `matplotlib.figure.Figure` (output='mpl')\n",
" a matplotlib figure object for the circuit diagram.\n",
" * `str` (output='latex_source')\n",
" The LaTeX source code for visualizing the circuit diagram.\n",
" * `TextDrawing` (output='text')\n",
" A drawing that can be printed as ascii art\n",
" \n",
" Raises:\n",
" VisualizationError: when an invalid output method is selected\n",
" ImportError: when the output methods requires non-installed\n",
" libraries.\n",
" \n",
" .. _style-dict-circ-doc:\n",
" \n",
" **Style Dict Details**\n",
" \n",
" The style dict kwarg contains numerous options that define the style of\n",
" the output circuit visualization. The style dict is only used by the\n",
" ``mpl`` output. The options available in the style dict are defined\n",
" below:\n",
" \n",
" Args:\n",
" textcolor (str): The color code to use for text. Defaults to\n",
" `'#000000'`\n",
" subtextcolor (str): The color code to use for subtext. Defaults to\n",
" `'#000000'`\n",
" linecolor (str): The color code to use for lines. Defaults to\n",
" `'#000000'`\n",
" creglinecolor (str): The color code to use for classical register\n",
" lines. Defaults to `'#778899'`\n",
" gatetextcolor (str): The color code to use for gate text. Defaults\n",
" to `'#000000'`\n",
" gatefacecolor (str): The color code to use for gates. Defaults to\n",
" `'#ffffff'`\n",
" barrierfacecolor (str): The color code to use for barriers.\n",
" Defaults to `'#bdbdbd'`\n",
" backgroundcolor (str): The color code to use for the background.\n",
" Defaults to `'#ffffff'`\n",
" fontsize (int): The font size to use for text. Defaults to 13\n",
" subfontsize (int): The font size to use for subtext. Defaults to 8\n",
" displaytext (dict): A dictionary of the text to use for each\n",
" element type in the output visualization. The default values\n",
" are::\n",
" \n",
" {\n",
" 'id': 'id',\n",
" 'u0': 'U_0',\n",
" 'u1': 'U_1',\n",
" 'u2': 'U_2',\n",
" 'u3': 'U_3',\n",
" 'x': 'X',\n",
" 'y': 'Y',\n",
" 'z': 'Z',\n",
" 'h': 'H',\n",
" 's': 'S',\n",
" 'sdg': 'S^\\dagger',\n",
" 't': 'T',\n",
" 'tdg': 'T^\\dagger',\n",
" 'rx': 'R_x',\n",
" 'ry': 'R_y',\n",
" 'rz': 'R_z',\n",
" 'reset': '\\left|0\\right\\rangle'\n",
" }\n",
" \n",
" You must specify all the necessary values if using this. There\n",
" is no provision for passing an incomplete dict in.\n",
" displaycolor (dict): The color codes to use for each circuit\n",
" element. The default values are::\n",
" \n",
" {\n",
" 'id': '#F0E442',\n",
" 'u0': '#E7AB3B',\n",
" 'u1': '#E7AB3B',\n",
" 'u2': '#E7AB3B',\n",
" 'u3': '#E7AB3B',\n",
" 'x': '#58C698',\n",
" 'y': '#58C698',\n",
" 'z': '#58C698',\n",
" 'h': '#70B7EB',\n",
" 's': '#E0722D',\n",
" 'sdg': '#E0722D',\n",
" 't': '#E0722D',\n",
" 'tdg': '#E0722D',\n",
" 'rx': '#ffffff',\n",
" 'ry': '#ffffff',\n",
" 'rz': '#ffffff',\n",
" 'reset': '#D188B4',\n",
" 'target': '#70B7EB',\n",
" 'meas': '#D188B4'\n",
" }\n",
" \n",
" Also, just like `displaytext` there is no provision for an\n",
" incomplete dict passed in.\n",
" \n",
" latexdrawerstyle (bool): When set to True enable latex mode which\n",
" will draw gates like the `latex` output modes.\n",
" usepiformat (bool): When set to True use radians for output\n",
" fold (int): The number of circuit elements to fold the circuit at.\n",
" Defaults to 20\n",
" cregbundle (bool): If set True bundle classical registers\n",
" showindex (bool): If set True draw an index.\n",
" compress (bool): If set True draw a compressed circuit\n",
" figwidth (int): The maximum width (in inches) for the output figure.\n",
" dpi (int): The DPI to use for the output image. Defaults to 150\n",
" margin (list): A list of margin values to adjust spacing around\n",
" output image. Takes a list of 4 ints:\n",
" [x left, x right, y bottom, y top].\n",
" creglinestyle (str): The style of line to use for classical\n",
" registers. Choices are `'solid'`, `'doublet'`, or any valid\n",
" matplotlib `linestyle` kwarg value. Defaults to `doublet`\n",
"\n"
]
}
],
"source": [
"help(circuit.draw)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"celltoolbar": "Diaporama",
"kernelspec": {
"display_name": "qiskitenv",
"language": "python",
"name": "qiskitenv"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.8"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment