Skip to content

Commit

Permalink
make html
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-rijsketic committed Jul 3, 2024
1 parent eab05e0 commit aad7c6e
Show file tree
Hide file tree
Showing 11 changed files with 73 additions and 35 deletions.
Binary file modified unravel/docs/_build/doctrees/environment.pickle
Binary file not shown.
Binary file modified unravel/docs/_build/doctrees/unravel/register/reg.doctree
Binary file not shown.
Binary file modified unravel/docs/_build/doctrees/unravel/warp/warp.doctree
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ <h1>Source code for unravel.image_tools.pad</h1><div class="highlight"><pre>
<span class="n">ort_code</span> <span class="o">=</span> <span class="n">nii_axis_codes</span><span class="p">(</span><span class="n">ref_nii</span><span class="p">)</span>
<span class="n">fixed_img_padded_nii</span> <span class="o">=</span> <span class="n">reorient_nii</span><span class="p">(</span><span class="n">fixed_img_padded_nii</span><span class="p">,</span> <span class="n">ort_code</span><span class="p">,</span> <span class="n">zero_origin</span><span class="o">=</span><span class="n">args</span><span class="o">.</span><span class="n">zero_origin</span><span class="p">,</span> <span class="n">apply</span><span class="o">=</span><span class="kc">False</span><span class="p">,</span> <span class="n">form_code</span><span class="o">=</span><span class="mi">1</span><span class="p">)</span>
<span class="k">else</span><span class="p">:</span>
<span class="n">fixed_img_padded_nii</span> <span class="o">=</span> <span class="n">reorient_nii</span><span class="p">(</span><span class="n">fixed_img_padded_nii</span><span class="p">,</span> <span class="n">nii_axis_codes</span><span class="p">(</span><span class="n">nii</span><span class="p">),</span> <span class="n">zero_origin</span><span class="o">=</span><span class="kc">True</span><span class="p">,</span> <span class="n">apply</span><span class="o">=</span><span class="kc">False</span><span class="p">,</span> <span class="n">form_code</span><span class="o">=</span><span class="mi">1</span><span class="p">)</span>
<span class="n">fixed_img_padded_nii</span> <span class="o">=</span> <span class="n">reorient_nii</span><span class="p">(</span><span class="n">fixed_img_padded_nii</span><span class="p">,</span> <span class="n">nii_axis_codes</span><span class="p">(</span><span class="n">nii</span><span class="p">),</span> <span class="n">zero_origin</span><span class="o">=</span><span class="n">args</span><span class="o">.</span><span class="n">zero_origin</span><span class="p">,</span> <span class="n">apply</span><span class="o">=</span><span class="kc">False</span><span class="p">,</span> <span class="n">form_code</span><span class="o">=</span><span class="mi">1</span><span class="p">)</span>

<span class="k">if</span> <span class="n">args</span><span class="o">.</span><span class="n">output</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span>
<span class="n">padded_img_path</span> <span class="o">=</span> <span class="n">args</span><span class="o">.</span><span class="n">input</span><span class="o">.</span><span class="n">replace</span><span class="p">(</span><span class="s1">&#39;.nii.gz&#39;</span><span class="p">,</span> <span class="s1">&#39;_pad.nii.gz&#39;</span><span class="p">)</span>
Expand Down
56 changes: 31 additions & 25 deletions unravel/docs/_build/html/_modules/unravel/register/reg.html

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion unravel/docs/_build/html/_modules/unravel/warp/warp.html
Original file line number Diff line number Diff line change
Expand Up @@ -364,6 +364,9 @@ <h1>Source code for unravel.warp.warp</h1><div class="highlight"><pre>

<span class="sd">Prereq: </span>
<span class="sd"> ``reg``</span>

<span class="sd">Note: </span>
<span class="sd"> This warps padded images in ./reg_outputs (i.e., images that match the padded fixed reg input). For unpadded final images, use ``warp_to_fixed`` and ``warp_to_atlas``.</span>
<span class="sd">&quot;&quot;&quot;</span>

<span class="kn">import</span> <span class="nn">ants</span>
Expand Down Expand Up @@ -403,7 +406,7 @@ <h1>Source code for unravel.warp.warp</h1><div class="highlight"><pre>
<span class="sd"> Applies the transformations to an image using ANTsPy.</span>

<span class="sd"> Parameters:</span>
<span class="sd"> reg_outputs_path (str): Path to the reg_outputs folder (contains transformation files)</span>
<span class="sd"> reg_outputs_path (Path): Path to the reg_outputs folder (contains transformation files)</span>
<span class="sd"> moving_img_path (str): Path to the image to be transformed.</span>
<span class="sd"> fixed_img_path (str): Path to the reference image for applying the transform.</span>
<span class="sd"> output_path (str): Path where the transformed image will be saved.</span>
Expand Down
2 changes: 1 addition & 1 deletion unravel/docs/_build/html/searchindex.js

Large diffs are not rendered by default.

29 changes: 25 additions & 4 deletions unravel/docs/_build/html/unravel/register/reg.html
Original file line number Diff line number Diff line change
Expand Up @@ -489,10 +489,22 @@
<section id="module-unravel.register.reg">
<span id="unravel-register-reg-module"></span><span id="unravel-register-reg"></span><h1>unravel.register.reg module<a class="headerlink" href="#module-unravel.register.reg" title="Link to this heading">#</a></h1>
<p>Use <code class="docutils literal notranslate"><span class="pre">reg</span></code> from UNRAVEL to register an average template brain/atlas to a resampled autofl brain.</p>
<section id="usage">
<h2>Usage:<a class="headerlink" href="#usage" title="Link to this heading">#</a></h2>
<section id="usage-for-tissue-registration">
<h2>Usage for tissue registration:<a class="headerlink" href="#usage-for-tissue-registration" title="Link to this heading">#</a></h2>
<blockquote>
<div><p>reg -m &lt;path/template.nii.gz&gt; -bc -pad -sm 0.4 -ort &lt;3 letter orientation code&gt;</p>
<div><p>reg -m &lt;path/template.nii.gz&gt; -bc -sm 0.4 -ort &lt;3 letter orientation code&gt;</p>
</div></blockquote>
</section>
<section id="usage-for-atlas-to-atlas-registration">
<h2>Usage for atlas to atlas registration:<a class="headerlink" href="#usage-for-atlas-to-atlas-registration" title="Link to this heading">#</a></h2>
<blockquote>
<div><p>reg -m &lt;path/atlas1.nii.gz&gt; -f &lt;path/atlas2.nii.gz&gt; -m2 &lt;path/atlas2.nii.gz&gt;</p>
</div></blockquote>
</section>
<section id="usage-for-template-to-template-registration">
<h2>Usage for template to template registration:<a class="headerlink" href="#usage-for-template-to-template-registration" title="Link to this heading">#</a></h2>
<blockquote>
<div><p>reg -m &lt;path/template1.nii.gz&gt; -f &lt;path/template2.nii.gz&gt; -m2 &lt;path/template2.nii.gz&gt; -inp linear</p>
</div></blockquote>
<dl class="simple">
<dt>ort_code letter options:</dt><dd><ul class="simple">
Expand All @@ -507,6 +519,13 @@ <h2>Usage:<a class="headerlink" href="#usage" title="Link to this heading">#</a>
<dt>Next steps:</dt><dd><p><code class="docutils literal notranslate"><span class="pre">reg_check</span></code> and <code class="docutils literal notranslate"><span class="pre">vstats_prep</span></code></p>
</dd>
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<ul class="simple">
<li><p>Images in reg_inputs are not padded.</p></li>
<li><p>Images in reg_outputs have 15% padding.</p></li>
</ul>
</div>
</section>
<dl class="py function">
<dt class="sig sig-object py" id="unravel.register.reg.parse_args">
Expand Down Expand Up @@ -583,7 +602,9 @@ <h2>Usage:<a class="headerlink" href="#usage" title="Link to this heading">#</a>
</div>
<nav class="bd-toc-nav page-toc" aria-labelledby="pst-page-navigation-heading-2">
<ul class="visible nav section-nav flex-column">
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#usage">Usage:</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#usage-for-tissue-registration">Usage for tissue registration:</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#usage-for-atlas-to-atlas-registration">Usage for atlas to atlas registration:</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#usage-for-template-to-template-registration">Usage for template to template registration:</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#unravel.register.reg.parse_args"><code class="docutils literal notranslate"><span class="pre">parse_args()</span></code></a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#unravel.register.reg.bias_correction"><code class="docutils literal notranslate"><span class="pre">bias_correction()</span></code></a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#unravel.register.reg.main"><code class="docutils literal notranslate"><span class="pre">main()</span></code></a></li>
Expand Down
4 changes: 3 additions & 1 deletion unravel/docs/_build/html/unravel/register/toc.html
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,9 @@ <h1>unravel.register package<a class="headerlink" href="#unravel-register-packag
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="reg.html">unravel.register.reg module</a><ul>
<li class="toctree-l2"><a class="reference internal" href="reg.html#usage">Usage:</a></li>
<li class="toctree-l2"><a class="reference internal" href="reg.html#usage-for-tissue-registration">Usage for tissue registration:</a></li>
<li class="toctree-l2"><a class="reference internal" href="reg.html#usage-for-atlas-to-atlas-registration">Usage for atlas to atlas registration:</a></li>
<li class="toctree-l2"><a class="reference internal" href="reg.html#usage-for-template-to-template-registration">Usage for template to template registration:</a></li>
<li class="toctree-l2"><a class="reference internal" href="reg.html#unravel.register.reg.parse_args"><code class="docutils literal notranslate"><span class="pre">parse_args()</span></code></a></li>
<li class="toctree-l2"><a class="reference internal" href="reg.html#unravel.register.reg.bias_correction"><code class="docutils literal notranslate"><span class="pre">bias_correction()</span></code></a></li>
<li class="toctree-l2"><a class="reference internal" href="reg.html#unravel.register.reg.main"><code class="docutils literal notranslate"><span class="pre">main()</span></code></a></li>
Expand Down
4 changes: 3 additions & 1 deletion unravel/docs/_build/html/unravel/toc.html
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,9 @@ <h2>Subpackages<a class="headerlink" href="#subpackages" title="Link to this hea
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="register/reg.html">unravel.register.reg module</a><ul>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#usage">Usage:</a></li>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#usage-for-tissue-registration">Usage for tissue registration:</a></li>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#usage-for-atlas-to-atlas-registration">Usage for atlas to atlas registration:</a></li>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#usage-for-template-to-template-registration">Usage for template to template registration:</a></li>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#unravel.register.reg.parse_args"><code class="docutils literal notranslate"><span class="pre">parse_args()</span></code></a></li>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#unravel.register.reg.bias_correction"><code class="docutils literal notranslate"><span class="pre">bias_correction()</span></code></a></li>
<li class="toctree-l3"><a class="reference internal" href="register/reg.html#unravel.register.reg.main"><code class="docutils literal notranslate"><span class="pre">main()</span></code></a></li>
Expand Down
6 changes: 5 additions & 1 deletion unravel/docs/_build/html/unravel/warp/warp.html
Original file line number Diff line number Diff line change
Expand Up @@ -504,6 +504,10 @@ <h2>Usage for inverse warping tissue to atlas space:<a class="headerlink" href="
<dt>Prereq:</dt><dd><p><code class="docutils literal notranslate"><span class="pre">reg</span></code></p>
</dd>
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>This warps padded images in ./reg_outputs (i.e., images that match the padded fixed reg input). For unpadded final images, use <code class="docutils literal notranslate"><span class="pre">warp_to_fixed</span></code> and <code class="docutils literal notranslate"><span class="pre">warp_to_atlas</span></code>.</p>
</div>
</section>
<dl class="py function">
<dt class="sig sig-object py" id="unravel.warp.warp.parse_args">
Expand All @@ -515,7 +519,7 @@ <h2>Usage for inverse warping tissue to atlas space:<a class="headerlink" href="
<span class="sig-prename descclassname"><span class="pre">unravel.warp.warp.</span></span><span class="sig-name descname"><span class="pre">warp</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">reg_outputs_path</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">moving_img_path</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">fixed_img_path</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">output_path</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">inverse</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">interpol</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="../../_modules/unravel/warp/warp.html#warp"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#unravel.warp.warp.warp" title="Link to this definition">#</a></dt>
<dd><p>Applies the transformations to an image using ANTsPy.</p>
<p>Parameters:
reg_outputs_path (str): Path to the reg_outputs folder (contains transformation files)
reg_outputs_path (Path): Path to the reg_outputs folder (contains transformation files)
moving_img_path (str): Path to the image to be transformed.
fixed_img_path (str): Path to the reference image for applying the transform.
output_path (str): Path where the transformed image will be saved.
Expand Down

0 comments on commit aad7c6e

Please sign in to comment.