-
Notifications
You must be signed in to change notification settings - Fork 442
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deployed 73a4b0e with MkDocs version: 1.5.3
- Loading branch information
Unknown
committed
Nov 9, 2023
1 parent
984a275
commit 310aae8
Showing
5 changed files
with
19 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1918,7 +1918,13 @@ <h2 id="exercises">❔ Exercises</h2> | |
<p>Move/copy the three files from yesterday into the repository (and any other that you made)</p> | ||
</li> | ||
<li> | ||
<p>Add the files to a commit by using <code>git add</code> command</p> | ||
<p class="annotate">Add the files to a commit by using <code>git add</code> command (1)</p> | ||
<ol> | ||
<li><img alt="🙋♂️" class="twemoji" src="https://cdn.jsdelivr.net/gh/jdecked/[email protected]/assets/svg/1f64b-200d-2642-fe0f.svg" title=":man_raising_hand:" /> Writing good commit message is a skill in itself. A commit message should be short but | ||
informative about the work you are trying to commit. Try to practise writing good commit messages | ||
throughout the course. You can see | ||
<a href="https://github.com/joelparkerhenderson/git-commit-message">this guideline</a> for help.</li> | ||
</ol> | ||
</li> | ||
<li> | ||
<p>Commit the files using <code>git commit</code></p> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2114,11 +2114,14 @@ <h3 id="exercises_2">❔ Exercises</h3> | |
</li> | ||
<li> | ||
<p>Try to prune the weights of the first convolutional layer by calling</p> | ||
<div class="language-python highlight"><pre><span></span><code><span id="__span-2-1"><a id="__codelineno-2-1" name="__codelineno-2-1" href="#__codelineno-2-1"></a><span class="n">prune</span><span class="o">.</span><span class="n">random_unstructured</span><span class="p">(</span><span class="n">module_1</span><span class="p">,</span> <span class="n">name</span><span class="o">=</span><span class="s2">"weight"</span><span class="p">,</span> <span class="n">amount</span><span class="o">=</span><span class="mf">0.3</span><span class="p">)</span> | ||
<div class="language-python highlight"><pre><span></span><code><span id="__span-2-1"><a id="__codelineno-2-1" name="__codelineno-2-1" href="#__codelineno-2-1"></a><span class="n">prune</span><span class="o">.</span><span class="n">random_unstructured</span><span class="p">(</span><span class="n">module_1</span><span class="p">,</span> <span class="n">name</span><span class="o">=</span><span class="s2">"weight"</span><span class="p">,</span> <span class="n">amount</span><span class="o">=</span><span class="mf">0.3</span><span class="p">)</span> <span class="c1"># (1)!</span> | ||
</span></code></pre></div> | ||
<ol> | ||
<li><img alt="🙋♂️" class="twemoji" src="https://cdn.jsdelivr.net/gh/jdecked/[email protected]/assets/svg/1f64b-200d-2642-fe0f.svg" title=":man_raising_hand:" /> You can read about the prune method | ||
<a href="https://pytorch.org/docs/stable/generated/torch.nn.utils.prune.random_unstructured.html#torch.nn.utils.prune.random_unstructured">here</a>.</li> | ||
</ol> | ||
<p>Try printing the <code>named_parameters</code>, <code>named_buffers</code> before and after the module is pruned. Can you explain the | ||
difference and what is the connection to the <code>module_1.weight</code> attribute. Hint: You can read about the prune | ||
method <a href="https://pytorch.org/docs/stable/generated/torch.nn.utils.prune.random_unstructured.html#torch.nn.utils.prune.random_unstructured">here</a>.</p> | ||
difference and what is the connection to the <code>module_1.weight</code> attribute.</p> | ||
</li> | ||
<li> | ||
<p>Try pruning the bias of the same module this time using the <code>l1_unstructured</code> function from the pruning module. Again | ||
|
@@ -2309,7 +2312,7 @@ <h3 id="exercises_3">❔ Exercises</h3> | |
<small> | ||
|
||
Last update: | ||
<span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">September 27, 2023</span> | ||
<span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">November 9, 2023</span> | ||
|
||
<br> | ||
Created: | ||
|
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.