Skip to content

Commit

Permalink
Deploying to gh-pages from @ 49b4513 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
qpavsmi committed Nov 6, 2023
1 parent e42132b commit d470345
Show file tree
Hide file tree
Showing 13 changed files with 121 additions and 50 deletions.
39 changes: 21 additions & 18 deletions _modules/kqcircuits/elements/chip_frame.html

Large diffs are not rendered by default.

40 changes: 26 additions & 14 deletions _modules/kqcircuits/junctions/manhattan.html

Large diffs are not rendered by default.

38 changes: 29 additions & 9 deletions _modules/kqcircuits/simulations/simulation.html
Original file line number Diff line number Diff line change
Expand Up @@ -650,6 +650,7 @@ <h1>Source code for kqcircuits.simulations.simulation</h1><div class="highlight"
<span class="n">upper_box_height</span> <span class="o">=</span> <span class="n">Param</span><span class="p">(</span><span class="n">pdt</span><span class="o">.</span><span class="n">TypeDouble</span><span class="p">,</span> <span class="s2">&quot;Height of vacuum above top substrate&quot;</span><span class="p">,</span> <span class="mf">1000.0</span><span class="p">,</span> <span class="n">unit</span><span class="o">=</span><span class="s2">&quot;µm&quot;</span><span class="p">)</span>
<span class="n">lower_box_height</span> <span class="o">=</span> <span class="n">Param</span><span class="p">(</span><span class="n">pdt</span><span class="o">.</span><span class="n">TypeDouble</span><span class="p">,</span> <span class="s2">&quot;Height of vacuum below bottom substrate&quot;</span><span class="p">,</span> <span class="mi">0</span><span class="p">,</span> <span class="n">unit</span><span class="o">=</span><span class="s2">&quot;µm&quot;</span><span class="p">,</span>
<span class="n">docstring</span><span class="o">=</span><span class="s2">&quot;Set &gt; 0 to start face counting from substrate bottom layer.&quot;</span><span class="p">)</span>
<span class="n">fixed_level_stackup</span> <span class="o">=</span> <span class="n">Param</span><span class="p">(</span><span class="n">pdt</span><span class="o">.</span><span class="n">TypeBoolean</span><span class="p">,</span> <span class="s2">&quot;Use fixed level multi-face stack-up&quot;</span><span class="p">,</span> <span class="kc">True</span><span class="p">)</span>
<span class="n">face_stack</span> <span class="o">=</span> <span class="n">Param</span><span class="p">(</span><span class="n">pdt</span><span class="o">.</span><span class="n">TypeList</span><span class="p">,</span> <span class="s2">&quot;Face IDs on the substrate surfaces from bottom to top&quot;</span><span class="p">,</span> <span class="p">[</span><span class="s2">&quot;1t1&quot;</span><span class="p">],</span>
<span class="n">docstring</span><span class="o">=</span><span class="s2">&quot;The parameter can be set as list of lists to enable multi-face stack-up on substrate &quot;</span>
<span class="s2">&quot;surfaces. Set term to empty list to not have metal on the surface.&quot;</span><span class="p">)</span>
Expand Down Expand Up @@ -1050,21 +1051,40 @@ <h1>Source code for kqcircuits.simulations.simulation</h1><div class="highlight"
<span class="n">ground_region</span> <span class="o">-=</span> <span class="n">tsv_region</span>
<span class="n">dielectric_region</span> <span class="o">-=</span> <span class="n">tsv_region</span>

<span class="c1"># Insert signal, ground, and dielectric layers to model via splitter</span>
<span class="c1"># Insert vertical over etching layer</span>
<span class="k">if</span> <span class="n">j</span> <span class="o">==</span> <span class="mi">0</span> <span class="ow">and</span> <span class="bp">self</span><span class="o">.</span><span class="n">vertical_over_etching</span> <span class="o">&gt;</span> <span class="mf">0.0</span><span class="p">:</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">etch_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_etch&quot;</span><span class="p">,</span>
<span class="n">thickness</span><span class="o">=-</span><span class="n">sign</span> <span class="o">*</span> <span class="bp">self</span><span class="o">.</span><span class="n">vertical_over_etching</span><span class="p">)</span>

<span class="c1"># Insert signal, ground and dielectric layers</span>
<span class="n">metal_thickness</span> <span class="o">=</span> <span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">1</span><span class="p">]</span> <span class="o">-</span> <span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">0</span><span class="p">]</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">signal_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_signal&quot;</span><span class="p">,</span> <span class="n">thickness</span><span class="o">=</span><span class="n">metal_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">ground_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_ground&quot;</span><span class="p">,</span> <span class="n">thickness</span><span class="o">=</span><span class="n">metal_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="n">dielectric_thickness</span> <span class="o">=</span> <span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">2</span><span class="p">]</span> <span class="o">-</span> <span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">1</span><span class="p">]</span>
<span class="k">if</span> <span class="n">dielectric_thickness</span> <span class="o">!=</span> <span class="mf">0.0</span><span class="p">:</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">dielectric_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_dielectric&quot;</span><span class="p">,</span>
<span class="n">thickness</span><span class="o">=</span><span class="n">dielectric_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">ith_value</span><span class="p">(</span><span class="n">dielectric_material</span><span class="p">,</span> <span class="n">j</span><span class="p">))</span>
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">fixed_level_stackup</span><span class="p">:</span>
<span class="c1"># Use fixed level stack-up</span>
<span class="bp">self</span><span class="o">.</span><span class="n">insert_layer</span><span class="p">(</span><span class="n">signal_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_signal&quot;</span><span class="p">,</span> <span class="n">z</span><span class="o">=</span><span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">0</span><span class="p">],</span> <span class="n">thickness</span><span class="o">=</span><span class="n">metal_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">insert_layer</span><span class="p">(</span><span class="n">ground_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_ground&quot;</span><span class="p">,</span> <span class="n">z</span><span class="o">=</span><span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">0</span><span class="p">],</span> <span class="n">thickness</span><span class="o">=</span><span class="n">metal_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="k">if</span> <span class="n">dielectric_thickness</span> <span class="o">!=</span> <span class="mf">0.0</span><span class="p">:</span>
<span class="bp">self</span><span class="o">.</span><span class="n">insert_layer</span><span class="p">(</span><span class="n">ground_box_region</span> <span class="o">-</span> <span class="n">dielectric_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_via&quot;</span><span class="p">,</span> <span class="n">z</span><span class="o">=</span><span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">1</span><span class="p">],</span>
<span class="n">thickness</span><span class="o">=</span><span class="n">dielectric_thickness</span><span class="p">,</span> <span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="n">subtract</span> <span class="o">=</span> <span class="p">[</span><span class="n">n</span> <span class="k">for</span> <span class="n">n</span> <span class="ow">in</span> <span class="p">[</span><span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_signal&quot;</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_ground&quot;</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_via&quot;</span><span class="p">]</span>
<span class="k">if</span> <span class="n">n</span> <span class="ow">in</span> <span class="bp">self</span><span class="o">.</span><span class="n">layers</span> <span class="ow">and</span> <span class="bp">self</span><span class="o">.</span><span class="n">layers</span><span class="p">[</span><span class="n">n</span><span class="p">]</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s1">&#39;thickness&#39;</span><span class="p">,</span> <span class="mf">0.0</span><span class="p">)</span> <span class="o">!=</span> <span class="mf">0.0</span><span class="p">]</span>
<span class="bp">self</span><span class="o">.</span><span class="n">insert_layer</span><span class="p">(</span><span class="n">dielectric_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_dielectric&quot;</span><span class="p">,</span> <span class="n">z</span><span class="o">=</span><span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">0</span><span class="p">],</span>
<span class="n">thickness</span><span class="o">=</span><span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">2</span><span class="p">]</span> <span class="o">-</span> <span class="n">z</span><span class="p">[</span><span class="n">face_id</span><span class="p">][</span><span class="mi">0</span><span class="p">],</span>
<span class="n">material</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">ith_value</span><span class="p">(</span><span class="n">dielectric_material</span><span class="p">,</span> <span class="n">j</span><span class="p">),</span>
<span class="o">**</span><span class="p">({</span><span class="s1">&#39;subtract&#39;</span><span class="p">:</span> <span class="n">subtract</span><span class="p">}</span> <span class="k">if</span> <span class="n">subtract</span> <span class="k">else</span> <span class="nb">dict</span><span class="p">()))</span>

<span class="k">else</span><span class="p">:</span>
<span class="c1"># Use splitter to produce drop-down stack-up</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">signal_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_signal&quot;</span><span class="p">,</span> <span class="n">thickness</span><span class="o">=</span><span class="n">metal_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">ground_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_ground&quot;</span><span class="p">,</span> <span class="n">thickness</span><span class="o">=</span><span class="n">metal_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="s1">&#39;pec&#39;</span><span class="p">)</span>
<span class="k">if</span> <span class="n">dielectric_thickness</span> <span class="o">!=</span> <span class="mf">0.0</span><span class="p">:</span>
<span class="bp">self</span><span class="o">.</span><span class="n">add_layer_to_splitter</span><span class="p">(</span><span class="n">splitter</span><span class="p">,</span> <span class="n">dielectric_region</span><span class="p">,</span> <span class="n">face_id</span> <span class="o">+</span> <span class="s2">&quot;_dielectric&quot;</span><span class="p">,</span>
<span class="n">thickness</span><span class="o">=</span><span class="n">dielectric_thickness</span><span class="p">,</span>
<span class="n">material</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">ith_value</span><span class="p">(</span><span class="n">dielectric_material</span><span class="p">,</span> <span class="n">j</span><span class="p">))</span>

<span class="c1"># Insert gap layer only on the first face of the stack-up (no material)</span>
<span class="k">if</span> <span class="n">j</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
Expand Down
8 changes: 8 additions & 0 deletions _sources/developer/setup.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,14 @@ pull`` just run :git_url:`setup_within_klayout.py` again. This will take care of
KQCircuit's Python dependencies and installing new ones, as needed. Running KLayout will similarly
update KQCircuits' dependencies in its own Python environment.

If the above didn't work (usually in case of downgrading dependencies), there is an alternative way.
If you see warnings displaying
``WARNING: Target directory xyz already exists. Specify --upgrade to force replacement.``,
this usually indicates that KQCircuits's Python dependencies were not properly upgraded (or downgraded).
In that case run the following:

python3 setup_within_klayout.py --force-package-reinstall

.. note::
If a new version of KQCircuits has stopped using a certain Python dependency that will **not**
be removed automatically. The user has to remove that manually if it causes any problem.
Expand Down
7 changes: 7 additions & 0 deletions _sources/user_guide/xsection.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@ generation for simulation files.
An example of using XSection tool to produce cross-section simulation files is
demonstrated in :git_url:`klayout_package/python/scripts/simulations/waveguides_sim_xsection.py`

.. note::
XSection 1.7 does not work immediately after package install due to the improvement
to backwards compatibility with older Ruby versions. To mitigate the issue,
you need to make a change in the XSection code. From you KLayout environment directory,
open ``KLayout/salt/xsetion/ruby/xsection.rb`` file in editor and change line 200
from ``pts << [[[ p1, p2 ]]]`` to ``pts << [[ p1, p2 ]]``

Process files (.xs)
-------------------

Expand Down
5 changes: 3 additions & 2 deletions api/kqcircuits.chips.junction_test2.html
Original file line number Diff line number Diff line change
Expand Up @@ -595,10 +595,11 @@
<li><p><strong>include_base_metal_gap</strong><em> (Boolean)</em><span> - Include base metal gap layer</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">True</span></code></p></li>
<li><p><strong>shadow_margin</strong><em> (Double)</em><span> - Shadow layer margin near the the pads</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">1.0</span></code><em>, unit=</em><code class="docutils literal notranslate"><span class="pre">μm</span></code></p></li>
<li><p><strong>compact_geometry</strong><em> (Boolean)</em><span> - Compact geometry for metal addition.</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">False</span></code></p></li>
<li><p><strong>separate_junctions</strong><em> (Boolean)</em><span> - Junctions to separate layer.</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">False</span></code></p></li>
<li><p><strong>separate_junctions</strong><em> (Boolean)</em><span> - Junctions to separate layer</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">False</span></code></p></li>
<li><p><strong>offset_compensation</strong><em> (Double)</em><span> - Junction lead offset from junction width</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">0</span></code><em>, unit=</em><code class="docutils literal notranslate"><span class="pre">μm</span></code></p></li>
<li><p><strong>mirror_offset</strong><em> (Boolean)</em><span> - Move the junction lead offset to the other lead</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">False</span></code></p></li>
<li><p><strong>finger_overlap</strong><em> (Double)</em><span> - Length of fingers inside the pads.</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">0.2</span></code><em>, unit=</em><code class="docutils literal notranslate"><span class="pre">μm</span></code></p></li>
<li><p><strong>finger_overlap</strong><em> (Double)</em><span> - Length of fingers inside the pads</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">0.2</span></code><em>, unit=</em><code class="docutils literal notranslate"><span class="pre">μm</span></code></p></li>
<li><p><strong>single_junction</strong><em> (Boolean)</em><span> - Disable the second junction</span><em>, default=</em><code class="docutils literal notranslate"><span class="pre">False</span></code></p></li>
</ul>
<img alt="../_images/kqcircuits.chips.junction_test2.png" src="../_images/kqcircuits.chips.junction_test2.png" />
</div>
Expand Down
Loading

0 comments on commit d470345

Please sign in to comment.