This commit is contained in:
Morten Hjorth-Jensen
2024-11-25 08:12:27 +01:00
parent d63cb194d5
commit c8f2aa3dc1
181 changed files with 13447 additions and 2592 deletions
+43 -30
View File
@@ -257,6 +257,9 @@
<li class="toctree-l1"><a class="reference internal" href="week47.html">Week 47: From Decision Trees to Ensemble Methods, Random Forests and Boosting Methods</a></li>
<li class="toctree-l1"><a class="reference internal" href="exercisesweek47.html">Exercise week 47</a></li>
<li class="toctree-l1"><a class="reference internal" href="week48.html">Week 48: Gradient boosting and summary of course</a></li>
<li class="toctree-l1"><a class="reference internal" href="exercisesweek48.html">Exercises week 48</a></li>
</ul>
<p aria-level="2" class="caption" role="heading"><span class="caption-text">Projects</span></p>
<ul class="nav bd-sidenav">
@@ -1005,8 +1008,8 @@ developed in the 1970s, namely EISPACK and LINPACK. We describe them shortly he
</div>
</div>
<div class="cell_output docutils container">
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>[ 0.17506058 -1.14302491 0.63485898 1.1235978 0.38873383 -0.17169218
0.88719525 -0.01015838 -0.27342837 -1.80652926]
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>[ 2.05896588 0.43642532 -0.21096409 0.40779804 -1.13963886 -0.53677418
0.83572684 0.58831595 0.30882611 -2.07060477]
</pre></div>
</div>
</div>
@@ -1231,26 +1234,36 @@ lowercase letters for vectors and uppercase letters for matrices)</p>
</div>
</div>
<div class="cell_output docutils container">
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>[[0.3418169 0.08757698 0.45405198 0.04340609 0.58148701 0.14855269
0.07347117 0.79453819 0.78257332 0.91637778]
[0.81517637 0.35341707 0.55717092 0.03395449 0.79320614 0.22562101
0.65971268 0.64276252 0.49192086 0.91375988]
[0.10740566 0.77091954 0.10656055 0.36547141 0.83190714 0.25533245
0.40632604 0.48183592 0.22261204 0.16509611]
[0.47804768 0.92388196 0.85585927 0.38675536 0.30896123 0.22930735
0.78408961 0.30789787 0.58654863 0.5228503 ]
[0.35826417 0.13768194 0.41982096 0.32226801 0.39507682 0.76931267
0.97369602 0.12082909 0.97147296 0.30115792]
[0.72544872 0.9789659 0.98184665 0.98596221 0.68564602 0.80794793
0.66307293 0.83836165 0.98251519 0.63387948]
[0.21352978 0.27418384 0.91865691 0.36851668 0.0525856 0.7259156
0.83058696 0.99696669 0.83207908 0.32633042]
[0.10500719 0.64631695 0.2220673 0.5920376 0.85070792 0.84332209
0.73691262 0.06028861 0.62436053 0.00758035]
[0.13963148 0.11686929 0.34936681 0.14068659 0.59525417 0.83232065
0.32968695 0.3371494 0.85006441 0.96828809]
[0.88555932 0.25272278 0.26684239 0.38777146 0.73658394 0.81886022
0.01409764 0.23749007 0.26368616 0.10068772]]
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>[[4.62790954e-01 3.05355909e-01 4.36307837e-01 5.75663043e-01
8.47455900e-01 8.88156953e-01 3.41214900e-01 4.80217592e-01
3.51294625e-01 4.55894547e-01]
[9.36928932e-01 1.34614286e-01 1.68706337e-01 5.12168283e-01
1.82057187e-01 5.04384702e-01 3.90807328e-01 7.21325310e-01
6.82139912e-04 7.75656839e-01]
[7.39975586e-01 7.28371709e-02 4.47008569e-01 1.48689896e-01
8.77801149e-01 8.77111122e-01 6.14302755e-01 3.05347541e-01
5.22304438e-01 1.19480182e-01]
[3.75927527e-01 1.79526117e-01 1.10245050e-01 2.14621443e-02
2.18149821e-01 6.60754644e-01 7.14889592e-01 2.00365236e-01
1.87081411e-01 8.98532247e-01]
[9.76246245e-01 7.27600064e-02 6.40428736e-01 2.44633057e-01
2.13315320e-01 9.04923596e-01 1.01278843e-01 1.60040487e-02
9.57338433e-01 4.54609970e-01]
[9.70716394e-01 8.19560587e-01 8.00696646e-01 8.50286966e-01
6.01413231e-01 5.35401167e-01 5.09318595e-01 7.50871033e-01
1.77320278e-01 1.41563755e-01]
[5.58999323e-01 8.27823274e-02 2.45162718e-01 9.35805174e-01
3.97967922e-01 6.41998971e-01 2.85999165e-01 9.42305845e-01
6.51639460e-01 2.40037335e-01]
[2.07463601e-01 6.36551310e-01 3.74118364e-01 9.48754846e-01
6.84043753e-01 8.69630846e-01 2.90701292e-01 3.73794006e-01
9.56898405e-01 7.53969725e-01]
[8.69421667e-01 9.16907984e-01 2.60498453e-01 1.05394015e-01
8.28209931e-01 2.18273724e-01 5.70725653e-01 5.90412777e-01
3.15706255e-01 1.00031589e-01]
[3.13129360e-02 9.74280470e-01 1.56927535e-01 2.05412497e-01
3.29614274e-01 1.32235211e-01 9.66580589e-01 6.25369588e-01
5.91506268e-01 3.63969272e-01]]
</pre></div>
</div>
</div>
@@ -1305,13 +1318,13 @@ covariance matrix through the <strong>np.linalg.eig()</strong> function.</p>
</div>
</div>
<div class="cell_output docutils container">
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>0.12144818928795939
4.458165594343705
0.07083732341182088
[[ 1.01630108 3.10680954 3.23143243]
[ 3.10680954 10.41130925 9.90126156]
[ 3.23143243 9.90126156 15.84271739]]
[24.2481237 0.07228932 2.94991469]
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>-0.022796599742659046
4.026047728952776
-0.08626455960524361
[[ 1.07037904 3.23910863 3.46675556]
[ 3.23910863 10.63080397 10.39964939]
[ 3.46675556 10.39964939 18.1421739 ]]
[26.31853116 0.06730967 3.45751608]
</pre></div>
</div>
</div>
@@ -1536,7 +1549,7 @@ Name: Aragorn, dtype: object
<div class="cell_output docutils container">
<div class="output traceback highlight-ipythontb notranslate"><div class="highlight"><pre><span></span><span class="gt">---------------------------------------------------------------------------</span>
<span class="ne">AttributeError</span><span class="g g-Whitespace"> </span>Traceback (most recent call last)
<span class="nn">/var/folders/td/3yk470mj5p931p9dtkk0y6jw0000gn/T/ipykernel_58960/1326197715.py</span> in <span class="ni">?</span><span class="nt">()</span>
<span class="nn">/var/folders/td/3yk470mj5p931p9dtkk0y6jw0000gn/T/ipykernel_23270/1326197715.py</span> in <span class="ni">?</span><span class="nt">()</span>
<span class="ne">----&gt; </span><span class="mi">6</span> <span class="n">new_hobbit</span> <span class="o">=</span> <span class="p">{</span><span class="s1">&#39;First Name&#39;</span><span class="p">:</span> <span class="p">[</span><span class="s2">&quot;Peregrin&quot;</span><span class="p">],</span>
<span class="g g-Whitespace"> </span><span class="mi">7</span> <span class="s1">&#39;Last Name&#39;</span><span class="p">:</span> <span class="p">[</span><span class="s2">&quot;Took&quot;</span><span class="p">],</span>
<span class="g g-Whitespace"> </span><span class="mi">8</span> <span class="s1">&#39;Place of birth&#39;</span><span class="p">:</span> <span class="p">[</span><span class="s2">&quot;Shire&quot;</span><span class="p">],</span>