Skip to content

Commit

Permalink
docs: skip graphviz_draw cell in notebooks
Browse files Browse the repository at this point in the history
  • Loading branch information
mrossinek committed Sep 10, 2024
1 parent 2a99008 commit af63153
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 39 deletions.
3 changes: 0 additions & 3 deletions .github/workflows/test_development_versions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,6 @@ jobs:
"qiskit @ git+https://github.com/Qiskit/qiskit.git" \
"qiskit-ibm-runtime @ git+https://github.com/Qiskit/qiskit-ibm-runtime.git" \
--inplace
- name: Install binary dependencies
run: |
sudo apt-get install -y graphviz
- name: Test using tox environment
shell: bash
run: |
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/test_latest_versions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,6 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install tox
- name: Install binary dependencies
run: |
sudo apt-get install -y graphviz
if: runner.os == 'Linux'
- name: Test using tox environment
shell: bash
run: |
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/test_minimum_versions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@ jobs:
python -m pip install extremal-python-dependencies==0.0.3
pip install "tox==$(extremal-python-dependencies get-tox-minversion)"
extremal-python-dependencies pin-dependencies-to-minimum --inplace
- name: Install binary dependencies
run: |
sudo apt-get install -y graphviz
- name: Test using tox environment
shell: bash
run: |
Expand Down
75 changes: 46 additions & 29 deletions docs/tutorials/01_getting_started.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,27 @@
},
"tags": []
},
"outputs": [],
"source": [
"from qiskit.transpiler import CouplingMap\n",
"\n",
"# Generate some coupling map to use for this example\n",
"coupling_map = CouplingMap.from_line(10, bidirectional=False)"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "e15dd313-668d-48b3-8133-3cd4df9a3d8e",
"metadata": {
"editable": true,
"slideshow": {
"slide_type": ""
},
"tags": [
"skip-execution"
]
},
"outputs": [
{
"data": {
Expand All @@ -92,18 +113,14 @@
"<PIL.PngImagePlugin.PngImageFile image mode=RGBA size=1595x59>"
]
},
"execution_count": 1,
"execution_count": 2,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from qiskit.transpiler import CouplingMap\n",
"from rustworkx.visualization import graphviz_draw\n",
"\n",
"# Generate some coupling map to use for this example\n",
"coupling_map = CouplingMap.from_line(10, bidirectional=False)\n",
"\n",
"graphviz_draw(coupling_map.graph, method=\"circo\")"
]
},
Expand All @@ -124,7 +141,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 3,
"id": "c03810d1-cb9f-429e-85d2-055486d77d2b",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -174,7 +191,7 @@
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": 4,
"id": "77232669-aa00-4f74-9f50-758f0c960693",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -289,7 +306,7 @@
},
{
"cell_type": "code",
"execution_count": 4,
"execution_count": 5,
"id": "89682993-64b3-44ea-ae95-cc9eea30a632",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -331,7 +348,7 @@
},
{
"cell_type": "code",
"execution_count": 5,
"execution_count": 6,
"id": "4898872e-8dc5-43f6-9615-31081851a80a",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -377,7 +394,7 @@
},
{
"cell_type": "code",
"execution_count": 6,
"execution_count": 7,
"id": "e0db1488-21f5-4f7b-a9f4-98e2e945afde",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -423,7 +440,7 @@
},
{
"cell_type": "code",
"execution_count": 7,
"execution_count": 8,
"id": "3bce6d85-a9dd-49e4-abe0-f8575394122c",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -468,7 +485,7 @@
},
{
"cell_type": "code",
"execution_count": 8,
"execution_count": 9,
"id": "b8ffca3a-87e7-4344-b189-af95ef5bf2f2",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -512,7 +529,7 @@
},
{
"cell_type": "code",
"execution_count": 9,
"execution_count": 10,
"id": "30dac7af-5a92-48f4-bc1a-1e140546cab2",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -577,7 +594,7 @@
},
{
"cell_type": "code",
"execution_count": 10,
"execution_count": 11,
"id": "fe25afaf-2f43-4c82-a97b-946b9a86df98",
"metadata": {
"editable": true,
Expand All @@ -603,7 +620,7 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": 12,
"id": "01b3c52b-53cc-4ccc-a2f0-efd774486070",
"metadata": {
"editable": true,
Expand All @@ -620,7 +637,7 @@
"<Figure size 6809.16x869.556 with 1 Axes>"
]
},
"execution_count": 11,
"execution_count": 12,
"metadata": {},
"output_type": "execute_result"
}
Expand All @@ -631,7 +648,7 @@
},
{
"cell_type": "code",
"execution_count": 12,
"execution_count": 13,
"id": "73e2099d-e7a7-4b6b-b6be-5f75fb1ccc8d",
"metadata": {
"editable": true,
Expand All @@ -648,7 +665,7 @@
"<Figure size 10153.6x869.556 with 1 Axes>"
]
},
"execution_count": 12,
"execution_count": 13,
"metadata": {},
"output_type": "execute_result"
}
Expand All @@ -659,7 +676,7 @@
},
{
"cell_type": "code",
"execution_count": 13,
"execution_count": 14,
"id": "25fcf8ff-3f91-4312-9334-ea55cf3efb14",
"metadata": {
"editable": true,
Expand All @@ -676,7 +693,7 @@
"<Figure size 16006.4x869.556 with 1 Axes>"
]
},
"execution_count": 13,
"execution_count": 14,
"metadata": {},
"output_type": "execute_result"
}
Expand Down Expand Up @@ -705,7 +722,7 @@
},
{
"cell_type": "code",
"execution_count": 14,
"execution_count": 15,
"id": "6c049ff6-5fc0-4673-a9d9-a37abcf96711",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -744,7 +761,7 @@
},
{
"cell_type": "code",
"execution_count": 15,
"execution_count": 16,
"id": "494cb360-91ae-4ba3-88ca-97e017ef1de5",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -781,7 +798,7 @@
},
{
"cell_type": "code",
"execution_count": 16,
"execution_count": 17,
"id": "7779817f-638d-4728-87d2-473d75e3aef4",
"metadata": {
"editable": true,
Expand Down Expand Up @@ -821,7 +838,7 @@
},
{
"cell_type": "code",
"execution_count": 17,
"execution_count": 18,
"id": "e5f536d5-ffce-4b7a-80f3-44846d50ee19",
"metadata": {
"editable": true,
Expand All @@ -835,9 +852,9 @@
"name": "stdout",
"output_type": "stream",
"text": [
"Analytical solution: 0.39548478559799655\n",
"Exact model solution: 0.395484785597998\n",
"Approx. model solution: 0.4299121425348964\n"
"Analytical solution: 0.3954847855980006\n",
"Exact model solution: 0.39548478559800204\n",
"Approx. model solution: 0.42991214253489807\n"
]
}
],
Expand All @@ -864,7 +881,7 @@
},
{
"cell_type": "code",
"execution_count": 18,
"execution_count": 19,
"id": "eeff7277-7295-4b78-a449-f151c8bd3e66",
"metadata": {
"editable": true,
Expand All @@ -878,7 +895,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"0.40060242487900255\n"
"0.40060242487899755\n"
]
}
],
Expand Down

0 comments on commit af63153

Please sign in to comment.