From c7a519fec3dfde04b9798ce00d4d9e6ba8be3345 Mon Sep 17 00:00:00 2001 From: Sarunas Kalade Date: Mon, 3 Oct 2022 23:40:02 +0100 Subject: [PATCH] common notebook updates for v3.0 (#1390) * getting rid of remaining freebuffer() calls * added extra check to zynq_clocks notebook to avoid error * updated overlay_download notebook to showcase raw bitstream download and Overlay class with caching * suppress opencv warning on display_port intro notebook * update overlay_download notebook to reflect BaseOverlay paths/performance --- .../notebooks/video/hdmi_introduction.ipynb | 12 +- .../common/display_port_introduction.ipynb | 13 +- pynq/notebooks/common/overlay_download.ipynb | 130 +++++++++++++----- pynq/notebooks/common/zynq_clocks.ipynb | 8 +- 4 files changed, 117 insertions(+), 46 deletions(-) diff --git a/boards/Pynq-Z1/base/notebooks/video/hdmi_introduction.ipynb b/boards/Pynq-Z1/base/notebooks/video/hdmi_introduction.ipynb index 606f7693ce..d18bc87616 100755 --- a/boards/Pynq-Z1/base/notebooks/video/hdmi_introduction.ipynb +++ b/boards/Pynq-Z1/base/notebooks/video/hdmi_introduction.ipynb @@ -162,7 +162,7 @@ "for _ in range(numframes):\n", " inframe = hdmi_in.readframe()\n", " cv2.cvtColor(inframe,cv2.COLOR_BGR2GRAY,dst=grayscale)\n", - " inframe.freebuffer()\n", + " # inframe.freebuffer()\n", " cv2.Laplacian(grayscale, cv2.CV_8U, dst=result)\n", "\n", " outframe = hdmi_out.newframe()\n", @@ -287,7 +287,7 @@ "for _ in range(numframes):\n", " inframe = hdmi_in.readframe()\n", " cv2.cvtColor(inframe,cv2.COLOR_BGR2GRAY,dst=grayscale)\n", - " inframe.freebuffer()\n", + " # inframe.freebuffer()\n", " cv2.Laplacian(grayscale, cv2.CV_8U, dst=result)\n", "\n", " outframe = hdmi_out.newframe()\n", @@ -365,7 +365,7 @@ " inframe = hdmi_in.readframe()\n", " outframe = hdmi_out.newframe()\n", " cv2.Laplacian(inframe, cv2.CV_8U, dst=outframe)\n", - " inframe.freebuffer()\n", + " # inframe.freebuffer()\n", " hdmi_out.writeframe(outframe)\n", " \n", "end = time.time()\n", @@ -527,7 +527,7 @@ ], "metadata": { "kernelspec": { - "display_name": "Python 3", + "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, @@ -541,9 +541,9 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.6.0" + "version": "3.10.4" } }, "nbformat": 4, - "nbformat_minor": 2 + "nbformat_minor": 4 } diff --git a/pynq/notebooks/arch/aarch64/common/display_port_introduction.ipynb b/pynq/notebooks/arch/aarch64/common/display_port_introduction.ipynb index 16f65394cc..8db697315f 100755 --- a/pynq/notebooks/arch/aarch64/common/display_port_introduction.ipynb +++ b/pynq/notebooks/arch/aarch64/common/display_port_introduction.ipynb @@ -15,7 +15,10 @@ "cell_type": "code", "execution_count": 1, "metadata": { - "collapsed": true + "collapsed": true, + "jupyter": { + "outputs_hidden": true + } }, "outputs": [], "source": [ @@ -101,6 +104,8 @@ } ], "source": [ + "import os\n", + "os.environ[\"OPENCV_LOG_LEVEL\"]=\"SILENT\"\n", "import cv2\n", "\n", "capture = cv2.VideoCapture(0)\n", @@ -163,7 +168,7 @@ ], "metadata": { "kernelspec": { - "display_name": "Python 3", + "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, @@ -177,9 +182,9 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.6.5" + "version": "3.10.4" } }, "nbformat": 4, - "nbformat_minor": 2 + "nbformat_minor": 4 } diff --git a/pynq/notebooks/common/overlay_download.ipynb b/pynq/notebooks/common/overlay_download.ipynb index 4157c6b07a..1648abc4a0 100755 --- a/pynq/notebooks/common/overlay_download.ipynb +++ b/pynq/notebooks/common/overlay_download.ipynb @@ -29,31 +29,13 @@ "cell_type": "code", "execution_count": 1, "metadata": {}, - "outputs": [ - { - "data": { - "application/javascript": [ - "\n", - "require(['notebook/js/codecell'], function(codecell) {\n", - " codecell.CodeCell.options_default.highlight_modes[\n", - " 'magic_text/x-csrc'] = {'reg':[/^%%microblaze/]};\n", - " Jupyter.notebook.events.one('kernel_ready.Kernel', function(){\n", - " Jupyter.notebook.get_cells().map(function(cell){\n", - " if (cell.cell_type == 'code'){ cell.auto_highlight(); } }) ;\n", - " });\n", - "});\n" - ] - }, - "metadata": {}, - "output_type": "display_data" - } - ], + "outputs": [], "source": [ "import os, warnings\n", "from pynq import PL\n", "from pynq import Overlay\n", "\n", - "if not os.path.exists(PL.bitfile_name):\n", + "if PL.bitfile_name == None or not os.path.exists(PL.bitfile_name):\n", " warnings.warn('There is no overlay loaded after boot.', UserWarning)" ] }, @@ -78,7 +60,46 @@ "cell_type": "code", "execution_count": 2, "metadata": {}, - "outputs": [], + "outputs": [ + { + "data": { + "application/javascript": [ + "\n", + "try {\n", + "require(['notebook/js/codecell'], function(codecell) {\n", + " codecell.CodeCell.options_default.highlight_modes[\n", + " 'magic_text/x-csrc'] = {'reg':[/^%%microblaze/]};\n", + " Jupyter.notebook.events.one('kernel_ready.Kernel', function(){\n", + " Jupyter.notebook.get_cells().map(function(cell){\n", + " if (cell.cell_type == 'code'){ cell.auto_highlight(); } }) ;\n", + " });\n", + "});\n", + "} catch (e) {};\n" + ] + }, + "metadata": {}, + "output_type": "display_data" + }, + { + "data": { + "application/javascript": [ + "\n", + "try {\n", + "require(['notebook/js/codecell'], function(codecell) {\n", + " codecell.CodeCell.options_default.highlight_modes[\n", + " 'magic_text/x-csrc'] = {'reg':[/^%%pybind11/]};\n", + " Jupyter.notebook.events.one('kernel_ready.Kernel', function(){\n", + " Jupyter.notebook.get_cells().map(function(cell){\n", + " if (cell.cell_type == 'code'){ cell.auto_highlight(); } }) ;\n", + " });\n", + "});\n", + "} catch (e) {};\n" + ] + }, + "metadata": {}, + "output_type": "display_data" + } + ], "source": [ "ol = Overlay(PL.bitfile_name)" ] @@ -98,7 +119,7 @@ { "data": { "text/plain": [ - "'2019/8/2 18:0:15 +752992'" + "''" ] }, "execution_count": 3, @@ -130,7 +151,7 @@ { "data": { "text/plain": [ - "'/usr/local/share/pynq-venv/lib/python3.8/site-packages/pynq/overlays/base/base.bit'" + "'/usr/local/share/pynq-venv/lib/python3.10/site-packages/pynq/overlays/base/base.bit'" ] }, "execution_count": 4, @@ -150,7 +171,7 @@ { "data": { "text/plain": [ - "'2019/8/2 18:0:15 +752992'" + "'2022/10/3 21:36:17 +589236'" ] }, "execution_count": 5, @@ -195,7 +216,7 @@ "source": [ "## 3. Overlay downloading overhead\n", "\n", - "Finally, using Python, we can see the bitstream download time over 50 downloads. " + "Finally, using Python, we can see the bitstream download time over 50 downloads. We use the Bitstream class to download the bitstream directly, bypassing any Overlay PL state caching." ] }, { @@ -205,19 +226,64 @@ "outputs": [ { "data": { - "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYMAAAEICAYAAAC9E5gJAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4xLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvAOZPmwAAFolJREFUeJzt3Xu0ZGV95vHvQzcXG4SGpkOgm1sC0cFkVDxBjI6iJI6ipFkzhjExocdhFpMsk+ioo+jEKzKjThTQmTGyRIWAF8QL6KjIIF6SGYmnwXBrE3oISDdtd8sdwQvwmz/2e+iiu8+1qs+p4/l+1jqrar/73e9+662uemq/u2p3qgpJ0sK2y1x3QJI09wwDSZJhIEkyDCRJGAaSJAwDSRKGgXok+askb5nrfuwMSW5N8ts7od23J7mw3T8kyQNJFg16P+Ps+8Ykx83Svo5KMpokA273s0lePMg2NTOGwQLS3hAfam9Ydyf5X0kOHltfVX9cVWe0usclWT/Fdg9LUkkW76y+zwdV9YOq2quqHhl020k+nuRd2+zvKVX1jUHvaxxnAH9Zg/9h0nuAd01aSzudYbDwnFhVewEHApuAD87GThd6UMxnSQ4Eng98YdBtV9XfAXsnGRl025oew2CBqqqfAJcAR42VjX36TLIn8BXgoHYU8UCSg5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JEnNyAbCfL7ERZIPJdnee/5FkuOS3JLkvnZ/7DDbOChJTk7yuSR3J9mQ5NJWPu/6I8nhSW5P8s3WF7/VyuddX+ySZEGSbyS5qT2el32R5IEkdya5Y9fhpjPpi5EMBC9xwbXA8j3KLgNuraqlwK3t8XzwBPCmqno2cC5wSftbmI/98Tjwoqr6aeBsYHmSc5mffbHLpcDdPY/nc1/8XFWd3XMexrT7YiQDgXl+iYuq+iLw3T2KzwNWt+nVwPmDbNOwVNXWqvp6m36U7sO/mHnYH9V5rD08tN2KedgXAEmWAL8AfLCneF72xT5Muy9GNRAmusTF4iG1ZVScUFVbofuSBI4fcnsGLslpwHOArzJP+6MNkdwBbAduqap52xfAu4G3AD/qKZuvfVHAZ5Ksb5f+gRn0xaAvXdGvvi5xofkjyVHAx4E3VtUjyUR/Ige/qtoJnJ3kGOCTSX5yyE0aiiSvALZX1fokLxxyc0bB86tqS5LjgVuS3DOThYzqFoKXuNjbtiQnArT77UNuz8AkOZQuDNZU1Sda8bztD4Cqehj4PN2+pvnYF88HfjHJA3RDyi9Kcj3zsy+oqi3tfjvwSbph92n3xagGgpe42Ns6YGWbXgncOMS2DEy6TYE/Ae6uqnf1PDXv+iPJorZlQJIjgBcD9zAP+6KqLq+qJVV1Gt33w19W1auYh32R5MgkT901DbwE+BYz6IuRPVM5ycvpxgh3XeLiiuG2aHCSfBR4Id2lfLcB7wA+BawFTgE2ARdU1Z47ng86SV4A/BVwJ7vHit9Gtx9hXvVHkp+i2zm4gO7H3Nqq+i9Jns4864tebcjozVX1ivnYF0l+nG6rALrdAB+pqitm0hcjGwiSpMEa1SEjSdKAGQiSJMBAkCQ1BoIkCTAQJEmNgSBJAgwESVLz/wFJLZPEaCWwrAAAAABJRU5ErkJggg==\n", "text/plain": [ - "" + "
" ] }, - "metadata": {}, + "metadata": { + "needs_background": "light" + }, "output_type": "display_data" } ], "source": [ "import time\n", "import matplotlib.pyplot as plt\n", + "from pynq import Bitstream\n", + "\n", + "length = 50\n", + "time_log = []\n", + "bits = Bitstream(PL.bitfile_name)\n", + "for i in range(length):\n", + " start = time.time()\n", + " bits.download()\n", + " end = time.time()\n", + " time_log.append((end-start)*1000)\n", "\n", + "%matplotlib inline\n", + "plt.plot(range(length), time_log, 'ro')\n", + "plt.title('Bitstream loading time (ms)')\n", + "plt.axis([0, length, 0, 5000])\n", + "plt.show()" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Alternatively, using the Overlay object, the first download of the overlay is cached and stored in a global state file. If the bitstream we want to upload doesn't change the Overlay class simply bypasses the download and allows quick access to interact with the PL without the download overhead." + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": {}, + "outputs": [ + { + "data": { + "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYQAAAEICAYAAABfz4NwAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjUuMSwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy/YYfK9AAAACXBIWXMAAAsTAAALEwEAmpwYAAAZ9UlEQVR4nO3de5RlZX3m8e9jg4hc5NY40M1NbUTIMu1QIllegvECOo5gJjhNEkWjtrBgAhldKiYzmgvRJN5CjJBGERgRxAvSGsmIjpdoQKxW5E5opIWy2+5GRHBUxm5/88d+yz401V1Vp05XVVvfz1pnnX3evd93v+et6vPUfvfep1NVSJL0qJnugCRpdjAQJEmAgSBJagwESRJgIEiSGgNBkgQYCOqR5Lwk/2Om+zFoSQ5OUkl22AZtfznJa9vyHyT5/KD3sYX9HpjkJ0nmTdP+Xp/kfQNuc6cktyXZd5Dtqn8GwhySZFWSn7UPkh8l+eckB4yur6pTquov27bHJBmZYLvb7AN3e1JVl1TVC7dF2+1n9/yefd1dVbtW1cZtsb/N9v1o4M+Avxtku1X1EHAB8OZBtqv+GQhzz3+uql2B/YC1wD9Mx07nelhs544Hbquq72+Dtj8KnJxkp23QtibJQJijqurnwCeAw0fLklyY5K+S7AJcBezfjiZ+kmT/JEclGU7yQJK1Sd7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tus7C3AF6tqEfDF9nou2AC8oaqeAhwNnNZ+F+bieDwE/E5V/SawGDguydHMzbEYdQZwa8/ruTwWz62qxT33YUx6LGZlIABHASur6rtV9f+Ay4DjZ7hP06aqvgrct1nx8cBFbfki4ITp7NNMqao1VfWttvwg3T/+BczB8WhfUfOT9nLH9ijm4FgAJFkI/Cfggz3Fc3IstmDSYzFbA2EBcE/P65FWNpc9vqrWQPchCew7w/2ZdkkOBp4GfIM5Oh5tiuR6YB1wdVXN2bEA3ge8CfhlT9lcHYsCPp9kRfvqH+hjLKb7qysmakJfcaG5I8muwCeBM6vqgWSsX5Fff1W1EVicZA/giiS/McNdmhFJXgKsq6oVSY6Z4e7MBs+sqtVJ9gWuTnJbP43M1iMEv+LikdYm2Q+gPa+b4f5MmyQ70oXBJVX1qVY8Z8cDoKruB75Md65pLo7FM4GXJllFN6X8O0k+wtwcC6pqdXteB1xBN+0+6bGYrYHgV1w80nLg5LZ8MnDlDPZl2qQ7FPgQcGtVvadn1ZwbjyTz25EBSXYGng/cxhwci6o6q6oWVtXBdJ8P/6eq/pA5OBZJdkmy2+gy8ELgJvoYi1l7p3KSF9PNEY5+xcXZM9uj6ZPkUuAYYB9gLfA24NPA5cCBwN3AiVW1+YnnXztJngX8K3Ajm+aK30p3HmFOjUeSp9KdHJxH98fc5VX1F0n2Zo6NRa82ZfTGqnrJXByLJE+gOyqA7jTAR6vq7H7GYtYGgiRpes3WKSNJ0jQzECRJgIEgSWoMBEkSYCBIkhoDQZIEGAiSpOb/A1tM7J3zwnCkAAAAAElFTkSuQmCC\n", + "text/plain": [ + "
" + ] + }, + "metadata": { + "needs_background": "light" + }, + "output_type": "display_data" + } + ], + "source": [ "length = 50\n", "time_log = []\n", "for i in range(length):\n", @@ -229,14 +295,14 @@ "%matplotlib inline\n", "plt.plot(range(length), time_log, 'ro')\n", "plt.title('Bitstream loading time (ms)')\n", - "plt.axis([0, length, 0, 1000])\n", + "plt.axis([0, length, 0, 2000])\n", "plt.show()" ] } ], "metadata": { "kernelspec": { - "display_name": "Python 3", + "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, @@ -250,9 +316,9 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.6.5" + "version": "3.10.4" } }, "nbformat": 4, - "nbformat_minor": 1 + "nbformat_minor": 4 } diff --git a/pynq/notebooks/common/zynq_clocks.ipynb b/pynq/notebooks/common/zynq_clocks.ipynb index b67298ec75..36f4b0284a 100755 --- a/pynq/notebooks/common/zynq_clocks.ipynb +++ b/pynq/notebooks/common/zynq_clocks.ipynb @@ -44,7 +44,7 @@ "from pynq import PL\n", "from pynq import Overlay\n", "\n", - "if not os.path.exists(PL.bitfile_name):\n", + "if PL.bitfile_name == None or not os.path.exists(PL.bitfile_name):\n", " warnings.warn('There is no overlay loaded after boot.', UserWarning)" ] }, @@ -177,7 +177,7 @@ ], "metadata": { "kernelspec": { - "display_name": "Python 3", + "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, @@ -191,9 +191,9 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.6.5" + "version": "3.10.4" } }, "nbformat": 4, - "nbformat_minor": 1 + "nbformat_minor": 4 }