Skip to content

Commit

Permalink
Deploying to gh-pages from @ 72c38d5 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
asogaard committed Jul 1, 2024
1 parent c44b94b commit 6c03b8d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions _modules/graphnet/models/components/embedding.html
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,6 @@ <h1 id="modules-graphnet-models-components-embedding--page-root">Source code for
<span class="nb">super</span><span class="p">()</span><span class="o">.</span><span class="fm">__init__</span><span class="p">()</span>

<span class="bp">self</span><span class="o">.</span><span class="n">sin_emb</span> <span class="o">=</span> <span class="n">SinusoidalPosEmb</span><span class="p">(</span><span class="n">dim</span><span class="o">=</span><span class="n">seq_length</span><span class="p">,</span> <span class="n">scaled</span><span class="o">=</span><span class="n">scaled</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">aux_emb</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Embedding</span><span class="p">(</span><span class="mi">2</span><span class="p">,</span> <span class="n">seq_length</span> <span class="o">//</span> <span class="mi">2</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">sin_emb2</span> <span class="o">=</span> <span class="n">SinusoidalPosEmb</span><span class="p">(</span><span class="n">dim</span><span class="o">=</span><span class="n">seq_length</span> <span class="o">//</span> <span class="mi">2</span><span class="p">,</span> <span class="n">scaled</span><span class="o">=</span><span class="n">scaled</span><span class="p">)</span>

<span class="k">if</span> <span class="n">n_features</span> <span class="o">&lt;</span> <span class="mi">4</span><span class="p">:</span>
Expand All @@ -452,7 +451,7 @@ <h1 id="modules-graphnet-models-components-embedding--page-root">Source code for
<span class="sa">f</span><span class="s2">"</span><span class="si">{</span><span class="n">n_features</span><span class="si">}</span><span class="s2"> features."</span>
<span class="p">)</span>
<span class="k">elif</span> <span class="n">n_features</span> <span class="o">&gt;=</span> <span class="mi">6</span><span class="p">:</span>

<span class="bp">self</span><span class="o">.</span><span class="n">aux_emb</span> <span class="o">=</span> <span class="n">nn</span><span class="o">.</span><span class="n">Embedding</span><span class="p">(</span><span class="mi">2</span><span class="p">,</span> <span class="n">seq_length</span> <span class="o">//</span> <span class="mi">2</span><span class="p">)</span>
<span class="n">hidden_dim</span> <span class="o">=</span> <span class="mi">6</span> <span class="o">*</span> <span class="n">seq_length</span>
<span class="k">else</span><span class="p">:</span>
<span class="n">hidden_dim</span> <span class="o">=</span> <span class="nb">int</span><span class="p">((</span><span class="n">n_features</span> <span class="o">+</span> <span class="mf">0.5</span><span class="p">)</span> <span class="o">*</span> <span class="n">seq_length</span><span class="p">)</span>
Expand Down

0 comments on commit 6c03b8d

Please sign in to comment.