added additional material
This commit is contained in:
@@ -333,6 +333,11 @@ const thebe_selector_output = ".output, .cell_output"
|
||||
Week 42 Constructing a Neural Network code with examples
|
||||
</a>
|
||||
</li>
|
||||
<li class="toctree-l1">
|
||||
<a class="reference internal" href="additionweek42.html">
|
||||
Exercises Week 42: Logistic Regression and Optimization, reminders from week 38 and week 40
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<p aria-level="2" class="caption" role="heading">
|
||||
<span class="caption-text">
|
||||
@@ -1315,10 +1320,10 @@ 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.014394967608286841
|
||||
4.011594819155615
|
||||
[[ 1.24508783 3.8595836 ]
|
||||
[ 3.8595836 12.92663007]]
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>0.10454793727627841
|
||||
4.330660516571777
|
||||
[[0.89100924 2.77618181]
|
||||
[2.77618181 9.5086728 ]]
|
||||
</pre></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1355,10 +1360,10 @@ a more brute force way. Here we scale the mean values for each column of the des
|
||||
</div>
|
||||
</div>
|
||||
<div class="cell_output docutils container">
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>0.07630326327869198
|
||||
1.6893421391051477
|
||||
[[1. 0.6373454]
|
||||
[0.6373454 1. ]]
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>0.08559230156092426
|
||||
1.6576130374029565
|
||||
[[1. 0.71664506]
|
||||
[0.71664506 1. ]]
|
||||
</pre></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1388,30 +1393,32 @@ this matrix we easily see that it is a positive definite matrix.</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cell_output docutils container">
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>[[ 0.20396326 0.93053605]
|
||||
[ 0.51936974 2.03440431]
|
||||
[-0.53851084 -1.2527027 ]
|
||||
[-0.50429483 0.72966563]
|
||||
[ 0.71314288 1.60421343]
|
||||
[-0.29995377 -2.31356849]
|
||||
[-0.14484831 -2.19932442]
|
||||
[-0.00570826 -0.32643011]
|
||||
[-0.22821607 0.56775345]
|
||||
[ 0.28505619 0.22545286]]
|
||||
0 1
|
||||
0 0.203963 0.930536
|
||||
1 0.519370 2.034404
|
||||
2 -0.538511 -1.252703
|
||||
3 -0.504295 0.729666
|
||||
4 0.713143 1.604213
|
||||
5 -0.299954 -2.313568
|
||||
6 -0.144848 -2.199324
|
||||
7 -0.005708 -0.326430
|
||||
8 -0.228216 0.567753
|
||||
9 0.285056 0.225453
|
||||
0 1
|
||||
0 1.0000 0.6373
|
||||
1 0.6373 1.0000
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>[[-0.34732758 -0.3068659 ]
|
||||
[ 1.21333606 3.23015412]
|
||||
[-0.54442191 -0.07166646]
|
||||
[ 0.51470773 1.33570831]
|
||||
[-0.31568288 -1.20511614]
|
||||
[-0.14218838 0.19488947]
|
||||
[ 1.15599422 2.35798999]
|
||||
[-0.91029443 -3.07195418]
|
||||
[-0.92262217 -3.09512539]
|
||||
[ 0.29849933 0.63198618]]
|
||||
</pre></div>
|
||||
</div>
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span> 0 1
|
||||
0 -0.347328 -0.306866
|
||||
1 1.213336 3.230154
|
||||
2 -0.544422 -0.071666
|
||||
3 0.514708 1.335708
|
||||
4 -0.315683 -1.205116
|
||||
5 -0.142188 0.194889
|
||||
6 1.155994 2.357990
|
||||
7 -0.910294 -3.071954
|
||||
8 -0.922622 -3.095125
|
||||
9 0.298499 0.631986
|
||||
0 1
|
||||
0 1.00000 0.94652
|
||||
1 0.94652 1.00000
|
||||
</pre></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1468,40 +1475,37 @@ this matrix we easily see that it is a positive definite matrix.</p>
|
||||
<div class="cell_output docutils container">
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span> 0 1 2 3 4 5 6 7 \
|
||||
0 0.0 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
|
||||
1 0.0 0.072835 0.076616 0.071253 0.074193 0.077337 0.063283 0.065305
|
||||
2 0.0 0.076616 0.082149 0.073794 0.077643 0.081811 0.064373 0.066929
|
||||
3 0.0 0.071253 0.073794 0.075423 0.077534 0.079745 0.070414 0.071978
|
||||
4 0.0 0.074193 0.077643 0.077534 0.080199 0.083034 0.071575 0.073483
|
||||
5 0.0 0.077337 0.081811 0.079745 0.083034 0.086576 0.072733 0.075028
|
||||
6 0.0 0.063283 0.064373 0.070414 0.071575 0.072733 0.068008 0.068984
|
||||
7 0.0 0.065305 0.066929 0.071978 0.073483 0.075028 0.068984 0.070181
|
||||
8 0.0 0.067523 0.069754 0.073667 0.075563 0.077550 0.070010 0.071459
|
||||
9 0.0 0.069964 0.072888 0.075496 0.077839 0.080330 0.071092 0.072826
|
||||
10 0.0 0.055866 0.055925 0.064324 0.064790 0.065183 0.063660 0.064182
|
||||
11 0.0 0.057298 0.057682 0.065508 0.066192 0.066830 0.064471 0.065139
|
||||
12 0.0 0.058866 0.059624 0.066786 0.067719 0.068637 0.065330 0.066162
|
||||
13 0.0 0.060590 0.061775 0.068171 0.069388 0.070625 0.066241 0.067260
|
||||
14 0.0 0.062489 0.064164 0.069675 0.071217 0.072820 0.067209 0.068440
|
||||
1 0.0 0.081845 0.082878 0.080997 0.085369 0.089785 0.071580 0.075878
|
||||
2 0.0 0.082878 0.084934 0.080301 0.085150 0.090174 0.070017 0.074524
|
||||
3 0.0 0.080997 0.080301 0.084987 0.088609 0.092062 0.077953 0.082043
|
||||
4 0.0 0.085369 0.085150 0.088609 0.092703 0.096690 0.080658 0.085099
|
||||
5 0.0 0.089785 0.090174 0.092062 0.096690 0.101288 0.083092 0.087909
|
||||
6 0.0 0.071580 0.070017 0.077953 0.080658 0.083092 0.073392 0.076829
|
||||
7 0.0 0.075878 0.074524 0.082043 0.085099 0.087909 0.076829 0.080576
|
||||
8 0.0 0.080448 0.079369 0.086306 0.089761 0.093004 0.080353 0.084440
|
||||
9 0.0 0.085295 0.084568 0.090721 0.094630 0.098371 0.083930 0.088390
|
||||
10 0.0 0.062310 0.060384 0.069636 0.071646 0.073349 0.066841 0.069680
|
||||
11 0.0 0.066030 0.064186 0.073411 0.075677 0.077641 0.070178 0.073270
|
||||
12 0.0 0.070021 0.068289 0.077414 0.079967 0.082230 0.073684 0.077053
|
||||
13 0.0 0.074301 0.072721 0.081652 0.084531 0.087135 0.077358 0.081031
|
||||
14 0.0 0.078889 0.077510 0.086130 0.089377 0.092374 0.081194 0.085201
|
||||
|
||||
8 9 10 11 12 13 14
|
||||
0 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
|
||||
1 0.067523 0.069964 0.055866 0.057298 0.058866 0.060590 0.062489
|
||||
2 0.069754 0.072888 0.055925 0.057682 0.059624 0.061775 0.064164
|
||||
3 0.073667 0.075496 0.064324 0.065508 0.066786 0.068171 0.069675
|
||||
4 0.075563 0.077839 0.064790 0.066192 0.067719 0.069388 0.071217
|
||||
5 0.077550 0.080330 0.065183 0.066830 0.068637 0.070625 0.072820
|
||||
6 0.070010 0.071092 0.063660 0.064471 0.065330 0.066241 0.067209
|
||||
7 0.071459 0.072826 0.064182 0.065139 0.066162 0.067260 0.068440
|
||||
8 0.073021 0.074713 0.064703 0.065823 0.067032 0.068341 0.069761
|
||||
9 0.074713 0.076776 0.065219 0.066524 0.067943 0.069492 0.071186
|
||||
10 0.064703 0.065219 0.060678 0.061187 0.061707 0.062241 0.062786
|
||||
11 0.065823 0.066524 0.061187 0.061793 0.062424 0.063082 0.063768
|
||||
12 0.067032 0.067943 0.061707 0.062424 0.063180 0.063978 0.064823
|
||||
13 0.068341 0.069492 0.062241 0.063082 0.063978 0.064935 0.065960
|
||||
14 0.069761 0.071186 0.062786 0.063768 0.064823 0.065960 0.067192
|
||||
</pre></div>
|
||||
</div>
|
||||
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>
|
||||
1 0.080448 0.085295 0.062310 0.066030 0.070021 0.074301 0.078889
|
||||
2 0.079369 0.084568 0.060384 0.064186 0.068289 0.072721 0.077510
|
||||
3 0.086306 0.090721 0.069636 0.073411 0.077414 0.081652 0.086130
|
||||
4 0.089761 0.094630 0.071646 0.075677 0.079967 0.084531 0.089377
|
||||
5 0.093004 0.098371 0.073349 0.077641 0.082230 0.087135 0.092374
|
||||
6 0.080353 0.083930 0.066841 0.070178 0.073684 0.077358 0.081194
|
||||
7 0.084440 0.088390 0.069680 0.073270 0.077053 0.081031 0.085201
|
||||
8 0.088680 0.093045 0.072551 0.076411 0.080493 0.084801 0.089338
|
||||
9 0.093045 0.097873 0.075416 0.079566 0.083970 0.088636 0.093572
|
||||
10 0.072551 0.075416 0.061795 0.064667 0.067662 0.070774 0.073993
|
||||
11 0.076411 0.079566 0.064667 0.067758 0.070991 0.074360 0.077857
|
||||
12 0.080493 0.083970 0.067662 0.070991 0.074482 0.078131 0.081931
|
||||
13 0.084801 0.088636 0.070774 0.074360 0.078131 0.082085 0.086218
|
||||
14 0.089338 0.093572 0.073993 0.077857 0.081931 0.086218 0.090717
|
||||
</pre></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user