/span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span>
        <span class="c1"># Set multi-device safe mode back to old mode in Python</span>
        <span class="k">global</span> <span class="n">_PY_RT_MULTI_DEVICE_SAFE_MODE</span>
        <span class="n">_PY_RT_MULTI_DEVICE_SAFE_MODE</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">old_mode</span>

        <span class="c1"># Set multi-device safe 