From b44387aa833e0044bb386ad918ecc0ff193eb392 Mon Sep 17 00:00:00 2001 From: Matthew Neeley Date: Wed, 25 Aug 2021 13:51:50 -0700 Subject: [PATCH] Bring back nest-asyncio to allow running notebooks with latest release (#4472) Fixes #4470 Review: @viathor --- docs/operators_and_observables.ipynb | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/docs/operators_and_observables.ipynb b/docs/operators_and_observables.ipynb index 5ef5a53995c..842b7b16f3b 100644 --- a/docs/operators_and_observables.ipynb +++ b/docs/operators_and_observables.ipynb @@ -800,6 +800,21 @@ "The pattern for computing $\\text{Tr} [ \\rho O ]$ is shown below." ] }, + { + "cell_type": "code", + "execution_count": null, + "metadata": { + "id": "7d55b4675db8" + }, + "outputs": [], + "source": [ + "# Install nest-asyncio to run collector inside jupyter.\n", + "# This will no longer be necessary in cirq 0.13+.\n", + "!pip install nest-asyncio\n", + "import nest_asyncio\n", + "nest_asyncio.apply() " + ] + }, { "cell_type": "code", "execution_count": null,