         <span class="k">if</span> <span class="n">smiles</span> <span class="ow">in</span> <span class="n">categories</span><span class="p">:</span>
                <span class="n">this_subgraph</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">molgraph</span><span class="o">.</span><span class="n">graph</span><span class="o">.</span><span class="n">subgraph</span><span class="p">(</span><span class="nb">list</span><span class="p">(</span><span class="n">gr