gradient_descent
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
gradient_descent [2025/08/01 13:47] – hkimscil | gradient_descent [2025/08/01 18:57] (current) – [R output] hkimscil | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Gradient Descent ====== | ====== Gradient Descent ====== | ||
+ | ====== explanation ====== | ||
점차하강 = 조금씩 깍아서 원하는 기울기 (미분값) 찾기 | 점차하강 = 조금씩 깍아서 원하는 기울기 (미분값) 찾기 | ||
prerequisite: | prerequisite: | ||
Line 22: | Line 23: | ||
& = & \sum{2 \frac{1}{N} (Y_i - (a + bX_i))} * (-1) \;\;\;\; \\ | & = & \sum{2 \frac{1}{N} (Y_i - (a + bX_i))} * (-1) \;\;\;\; \\ | ||
& \because & \dfrac{\text{d}}{\text{dv for a}} (Y_i - (a+bX_i)) = -1 \\ | & \because & \dfrac{\text{d}}{\text{dv for a}} (Y_i - (a+bX_i)) = -1 \\ | ||
- | & = & -2 \frac{1}{N} \sum{(Y_i - (a + bX_i))} \\ | + | & = & -2 \frac{\sum{(Y_i - (a + bX_i))}}{N} \\ |
+ | & = & -2 * \text{mean of residuals} \\ | ||
\end{eqnarray*} | \end{eqnarray*} | ||
+ | 아래 R code에서 gradient function을 참조. | ||
</ | </ | ||
+ | <WRAP box> | ||
+ | \begin{eqnarray*} | ||
+ | \text{for b, (coefficient)} \\ | ||
+ | \\ | ||
+ | \dfrac{\text{d}}{\text{dv}} \frac{\sum{(Y_i - (a + bX_i))^2}}{N} | ||
+ | & = & \sum{2 \frac{1}{N} (Y_i - (a + bX_i))} * (-X_i) \;\;\;\; \\ | ||
+ | & \because & \dfrac{\text{d}}{\text{dv for b}} (Y_i - (a+bX_i)) = -X_i \\ | ||
+ | & = & -2 X_i \frac{\sum{(Y_i - (a + bX_i))}}{N} \\ | ||
+ | & = & -2 * X_i * \text{mean of residuals} \\ | ||
+ | \\ | ||
+ | \end{eqnarray*} | ||
+ | (미분을 이해한다는 것을 전제로) 위의 식은 b값이 변할 때 msr (mean square residual) 값이 어떻게 변하는가를 알려주는 것이다. 그리고 그것은 b값에 대한 residual의 총합에 (-2/ | ||
+ | </ | ||
+ | ====== R code ====== | ||
< | < | ||
- | library(tidyverse) | + | # d statquest explanation |
- | # a simple example | + | # x <- c(0.5, 2.3, 2.9) |
- | # statquest explanation | + | # y <- c(1.4, 1.9, 3.2) |
- | x <- c(0.5, 2.3, 2.9) | + | |
- | y <- c(1.4, 1.9, 3.2) | + | |
rm(list=ls()) | rm(list=ls()) | ||
# set.seed(191) | # set.seed(191) | ||
- | n <- 500 | + | n <- 300 |
x <- rnorm(n, 5, 1.2) | x <- rnorm(n, 5, 1.2) | ||
y <- 2.14 * x + rnorm(n, 0, 4) | y <- 2.14 * x + rnorm(n, 0, 4) | ||
Line 43: | Line 57: | ||
# data <- data.frame(x, | # data <- data.frame(x, | ||
data <- tibble(x = x, y = y) | data <- tibble(x = x, y = y) | ||
- | data | ||
mo <- lm(y~x) | mo <- lm(y~x) | ||
Line 52: | Line 65: | ||
b1 = rnorm(1) | b1 = rnorm(1) | ||
b0 = rnorm(1) | b0 = rnorm(1) | ||
+ | |||
+ | b1.init <- b1 | ||
+ | b0.init <- b0 | ||
# Predict function: | # Predict function: | ||
Line 72: | Line 88: | ||
loss = loss_mse(predictions, | loss = loss_mse(predictions, | ||
- | temp.sum | + | data <- tibble(data.frame(x, |
- | temp.sum | + | |
print(paste0(" | print(paste0(" | ||
Line 94: | Line 109: | ||
# Record Loss for each epoch: | # Record Loss for each epoch: | ||
- | logs = list() | + | # logs = list() |
- | bs=list() | + | # bs=list() |
b0s = c() | b0s = c() | ||
b1s = c() | b1s = c() | ||
Line 106: | Line 121: | ||
loss = loss_mse(predictions, | loss = loss_mse(predictions, | ||
mse = append(mse, loss) | mse = append(mse, loss) | ||
- | | + | |
- | | + | |
| | ||
if (epoch %% 10 == 0){ | if (epoch %% 10 == 0){ | ||
Line 122: | Line 136: | ||
b1s <- append(b1s, b1) | b1s <- append(b1s, b1) | ||
} | } | ||
- | # I must unscale coefficients to make them comprehensible | + | |
+ | # unscale coefficients to make them comprehensible | ||
b0 = b0 - (mean(x) / sd(x)) * b1 | b0 = b0 - (mean(x) / sd(x)) * b1 | ||
b1 = b1 / sd(x) | b1 = b1 / sd(x) | ||
+ | # changes of estimators | ||
b0s <- b0s - (mean(x) /sd(x)) * b1s | b0s <- b0s - (mean(x) /sd(x)) * b1s | ||
b1s <- b1s / sd(x) | b1s <- b1s / sd(x) | ||
Line 131: | Line 147: | ||
parameters <- tibble(data.frame(b0s, | parameters <- tibble(data.frame(b0s, | ||
- | cat(paste0(" | + | cat(paste0(" |
summary(lm(y~x))$coefficients | summary(lm(y~x))$coefficients | ||
Line 137: | Line 153: | ||
geom_point(size = 2) + | geom_point(size = 2) + | ||
geom_abline(aes(intercept = b0s, slope = b1s), | geom_abline(aes(intercept = b0s, slope = b1s), | ||
- | data = parameters, linewidth = 0.5, color = 'red') + | + | data = parameters, linewidth = 0.5, |
+ | | ||
theme_classic() + | theme_classic() + | ||
geom_abline(aes(intercept = b0s, slope = b1s), | geom_abline(aes(intercept = b0s, slope = b1s), | ||
data = parameters %>% slice_head(), | data = parameters %>% slice_head(), | ||
- | linewidth = 0.5, color = ' | + | linewidth = 1, color = ' |
geom_abline(aes(intercept = b0s, slope = b1s), | geom_abline(aes(intercept = b0s, slope = b1s), | ||
data = parameters %>% slice_tail(), | data = parameters %>% slice_tail(), | ||
- | linewidth = 1, color = 'green') + | + | linewidth = 1, color = 'red') + |
- | labs(title = ' | + | labs(title = ' |
+ | |||
+ | b0.init | ||
+ | b1.init | ||
data | data | ||
parameters | parameters | ||
+ | |||
</ | </ | ||
+ | ====== R output ===== | ||
< | < | ||
- | > # d statquest explanation | ||
- | > x <- c(0.5, 2.3, 2.9) | ||
- | > y <- c(1.4, 1.9, 3.2) | ||
- | > | ||
> rm(list=ls()) | > rm(list=ls()) | ||
> # set.seed(191) | > # set.seed(191) | ||
- | > n <- 500 | + | > n <- 300 |
> x <- rnorm(n, 5, 1.2) | > x <- rnorm(n, 5, 1.2) | ||
> y <- 2.14 * x + rnorm(n, 0, 4) | > y <- 2.14 * x + rnorm(n, 0, 4) | ||
Line 163: | Line 182: | ||
> # data <- data.frame(x, | > # data <- data.frame(x, | ||
> data <- tibble(x = x, y = y) | > data <- tibble(x = x, y = y) | ||
- | > data | ||
- | # A tibble: 500 × 2 | ||
- | | ||
- | < | ||
- | | ||
- | | ||
- | | ||
- | | ||
- | | ||
- | | ||
- | | ||
- | | ||
- | | ||
- | 10 5.27 13.9 | ||
- | # ℹ 490 more rows | ||
- | # ℹ Use `print(n = ...)` to see more rows | ||
> | > | ||
> mo <- lm(y~x) | > mo <- lm(y~x) | ||
Line 187: | Line 190: | ||
Residuals: | Residuals: | ||
- | | + | Min |
- | -10.474 | + | -9.754 -2.729 -0.135 |
Coefficients: | Coefficients: | ||
Estimate Std. Error t value Pr(> | Estimate Std. Error t value Pr(> | ||
- | (Intercept) | + | (Intercept) |
- | x 1.9828 0.1427 13.890 <2e-16 *** | + | x 2.2692 0.1793 12.658 <2e-16 *** |
--- | --- | ||
Signif. codes: | Signif. codes: | ||
- | Residual standard error: 3.929 on 498 degrees of freedom | + | Residual standard error: 3.951 on 298 degrees of freedom |
- | Multiple R-squared: | + | Multiple R-squared: |
- | F-statistic: | + | F-statistic: |
> | > | ||
Line 206: | Line 209: | ||
> b1 = rnorm(1) | > b1 = rnorm(1) | ||
> b0 = rnorm(1) | > b0 = rnorm(1) | ||
+ | > | ||
+ | > b1.init <- b1 | ||
+ | > b0.init <- b0 | ||
> | > | ||
> # Predict function: | > # Predict function: | ||
Line 226: | Line 232: | ||
> loss = loss_mse(predictions, | > loss = loss_mse(predictions, | ||
> | > | ||
- | > temp.sum | + | > data <- tibble(data.frame(x, |
- | > temp.sum | + | |
- | x y b0 b1 predictions | + | |
- | 1 | + | |
- | 2 | + | |
- | 3 | + | |
- | 4 | + | |
- | 5 | + | |
- | 6 | + | |
- | 7 | + | |
- | 8 | + | |
- | 9 | + | |
- | 10 5.2672548 13.9111428 -1.264277 -0.5262407 | + | |
- | 11 5.5156223 11.2320867 -1.264277 -0.5262407 | + | |
- | 12 3.1799040 | + | |
- | 13 6.7547841 10.0729772 -1.264277 -0.5262407 | + | |
- | 14 7.2250923 | + | |
- | 15 5.6642827 | + | |
- | 16 6.4099293 16.6274813 -1.264277 -0.5262407 | + | |
- | 17 4.2914899 11.2173980 -1.264277 -0.5262407 | + | |
- | 18 4.6413358 | + | |
- | 19 5.6684969 | + | |
- | 20 5.3803989 10.4308559 -1.264277 -0.5262407 | + | |
- | 21 4.0240137 | + | |
- | 22 5.0816903 | + | |
- | 23 6.4856995 | + | |
- | 24 4.1315971 15.0691180 -1.264277 -0.5262407 | + | |
- | 25 4.3975735 10.0977703 -1.264277 -0.5262407 | + | |
- | 26 3.6800792 14.8057519 -1.264277 -0.5262407 | + | |
- | 27 5.9063058 14.7436966 -1.264277 -0.5262407 | + | |
- | 28 4.0259638 | + | |
- | 29 5.6966522 | + | |
- | 30 3.8406098 10.1716630 -1.264277 -0.5262407 | + | |
- | 31 3.7738837 10.1961941 -1.264277 -0.5262407 | + | |
- | 32 4.8977716 14.6487758 -1.264277 -0.5262407 | + | |
- | 33 3.5182859 -0.6639891 -1.264277 -0.5262407 | + | |
- | 34 6.7555953 18.3109425 -1.264277 -0.5262407 | + | |
- | 35 5.3450800 | + | |
- | 36 4.6063392 | + | |
- | 37 3.3150851 10.6463845 -1.264277 -0.5262407 | + | |
- | 38 2.1438875 | + | |
- | 39 6.7867082 14.4541469 -1.264277 -0.5262407 | + | |
- | 40 7.1651170 16.0295592 -1.264277 -0.5262407 | + | |
- | 41 6.0068801 | + | |
- | 42 3.8429583 | + | |
- | 43 6.6963199 14.9606533 -1.264277 -0.5262407 | + | |
- | 44 5.9766522 17.5076500 -1.264277 -0.5262407 | + | |
- | 45 3.4139235 | + | |
- | 46 7.1468347 15.4958432 -1.264277 -0.5262407 | + | |
- | 47 2.9413548 | + | |
- | 48 2.7033044 | + | |
- | 49 5.6384145 15.7331403 -1.264277 -0.5262407 | + | |
- | 50 3.6549025 13.8667532 -1.264277 -0.5262407 | + | |
- | 51 2.4549093 -3.2303197 -1.264277 -0.5262407 | + | |
- | 52 3.4177686 | + | |
- | 53 8.5165648 25.6896235 -1.264277 -0.5262407 | + | |
- | 54 5.6089046 | + | |
- | 55 3.3871150 | + | |
- | 56 4.4518647 | + | |
- | 57 5.5052891 | + | |
- | 58 4.6203097 | + | |
- | 59 5.4313621 11.1323523 -1.264277 -0.5262407 | + | |
- | 60 4.6889464 15.0880915 -1.264277 -0.5262407 | + | |
- | 61 6.0363099 | + | |
- | 62 5.9834349 15.5984185 -1.264277 -0.5262407 | + | |
- | 63 6.1256065 | + | |
- | 64 4.7770683 | + | |
- | 65 3.0977662 | + | |
- | 66 7.2582566 10.1658760 -1.264277 -0.5262407 | + | |
- | 67 4.4274063 10.5254164 -1.264277 -0.5262407 | + | |
- | 68 4.4224093 15.3288304 -1.264277 -0.5262407 | + | |
- | 69 7.9562345 15.8094793 -1.264277 -0.5262407 | + | |
- | 70 6.1605765 17.6226869 -1.264277 -0.5262407 | + | |
- | 71 4.8811933 11.4006073 -1.264277 -0.5262407 | + | |
- | 72 5.8458839 | + | |
- | 73 5.4176401 17.9873603 -1.264277 -0.5262407 | + | |
- | 74 5.1877292 10.0773562 -1.264277 -0.5262407 | + | |
- | 75 4.4385788 | + | |
- | 76 6.5079686 16.8845586 -1.264277 -0.5262407 | + | |
- | 77 5.8326041 12.8972544 -1.264277 -0.5262407 | + | |
- | 78 4.7833622 10.1946848 -1.264277 -0.5262407 | + | |
- | 79 5.9256779 16.6025871 -1.264277 -0.5262407 | + | |
- | 80 4.9860307 12.9422586 -1.264277 -0.5262407 | + | |
- | 81 5.2401527 17.2049456 -1.264277 -0.5262407 | + | |
- | 82 6.7570239 13.8736266 -1.264277 -0.5262407 | + | |
- | 83 5.4384563 14.1770698 -1.264277 -0.5262407 | + | |
- | 84 5.4498287 12.0591785 -1.264277 -0.5262407 | + | |
- | 85 5.9643832 13.8220440 -1.264277 -0.5262407 | + | |
- | 86 4.4057387 | + | |
- | 87 3.6834860 15.4963951 -1.264277 -0.5262407 | + | |
- | 88 6.4421163 | + | |
- | 89 6.5442359 13.3216053 -1.264277 -0.5262407 | + | |
- | 90 5.9329826 | + | |
- | 91 6.3086002 | + | |
- | 92 6.6894199 | + | |
- | 93 4.3681693 | + | |
- | 94 6.6461515 12.5441888 -1.264277 -0.5262407 | + | |
- | 95 5.1824709 | + | |
- | 96 2.1875381 | + | |
- | 97 5.6086270 10.8605436 -1.264277 -0.5262407 | + | |
- | 98 5.4158031 | + | |
- | 99 0.8135196 | + | |
- | 100 3.7676048 | + | |
- | 101 3.7048040 | + | |
- | 102 4.5848668 | + | |
- | 103 4.6436020 | + | |
- | 104 5.5137839 19.8317442 -1.264277 -0.5262407 | + | |
- | 105 5.5460450 11.7004649 -1.264277 -0.5262407 | + | |
- | 106 2.6322855 | + | |
- | 107 4.8768933 | + | |
- | 108 4.2582660 15.6448394 -1.264277 -0.5262407 | + | |
- | 109 5.3263384 11.2636384 -1.264277 -0.5262407 | + | |
- | 110 4.7875378 | + | |
- | 111 3.6879691 | + | |
- | 112 4.2645818 | + | |
- | 113 5.7080723 11.4807855 -1.264277 -0.5262407 | + | |
- | 114 4.4170445 11.9510702 -1.264277 -0.5262407 | + | |
- | 115 4.7051114 15.0610402 -1.264277 -0.5262407 | + | |
- | 116 3.2868115 | + | |
- | 117 4.9496883 11.1438762 -1.264277 -0.5262407 | + | |
- | 118 5.3579592 10.4867567 -1.264277 -0.5262407 | + | |
- | 119 3.4340821 | + | |
- | 120 7.5112322 15.4265323 -1.264277 -0.5262407 | + | |
- | 121 7.4090157 17.2211544 -1.264277 -0.5262407 | + | |
- | 122 5.3807003 12.0371465 -1.264277 -0.5262407 | + | |
- | 123 5.9982219 12.2743501 -1.264277 -0.5262407 | + | |
- | 124 3.0991733 | + | |
- | 125 4.9540596 12.7552638 -1.264277 -0.5262407 | + | |
- | 126 5.4521347 13.9911543 -1.264277 -0.5262407 | + | |
- | 127 4.2101665 11.0247402 -1.264277 -0.5262407 | + | |
- | 128 2.1382146 | + | |
- | 129 4.7861186 | + | |
- | 130 4.6243029 12.1062901 -1.264277 -0.5262407 | + | |
- | 131 4.7045999 21.6574011 -1.264277 -0.5262407 | + | |
- | 132 5.0353365 | + | |
- | 133 5.7684327 14.9482380 -1.264277 -0.5262407 | + | |
- | 134 5.4650414 11.1578444 -1.264277 -0.5262407 | + | |
- | 135 6.3983266 12.7511754 -1.264277 -0.5262407 | + | |
- | 136 5.1054629 12.2676585 -1.264277 -0.5262407 | + | |
- | 137 5.4727620 15.7361092 -1.264277 -0.5262407 | + | |
- | 138 4.7336163 10.1946145 -1.264277 -0.5262407 | + | |
- | 139 5.2480093 | + | |
- | 140 3.0004377 | + | |
- | 141 3.6651683 | + | |
- | 142 4.5906320 | + | |
- | 143 5.8844053 19.4617765 -1.264277 -0.5262407 | + | |
- | 144 3.5734761 14.9494035 -1.264277 -0.5262407 | + | |
- | 145 4.1928815 11.5554015 -1.264277 -0.5262407 | + | |
- | 146 6.8910946 12.6820411 -1.264277 -0.5262407 | + | |
- | 147 5.7008138 | + | |
- | 148 3.6069183 14.5345051 -1.264277 -0.5262407 | + | |
- | 149 5.4279511 12.5578155 -1.264277 -0.5262407 | + | |
- | 150 5.6139766 11.8074150 -1.264277 -0.5262407 | + | |
- | 151 5.6023394 11.5063542 -1.264277 -0.5262407 | + | |
- | 152 6.2157176 | + | |
- | 153 5.6589077 | + | |
- | 154 2.8113763 | + | |
- | 155 4.5806760 | + | |
- | 156 5.6392284 13.7001285 -1.264277 -0.5262407 | + | |
- | 157 5.2827326 14.4966648 -1.264277 -0.5262407 | + | |
- | 158 4.4994363 | + | |
- | 159 5.2554305 | + | |
- | 160 5.5622164 | + | |
- | 161 7.0995953 12.5898387 -1.264277 -0.5262407 | + | |
- | 162 5.6046834 12.2369786 -1.264277 -0.5262407 | + | |
- | 163 3.9260205 | + | |
- | 164 6.6192734 16.2775842 -1.264277 -0.5262407 | + | |
- | 165 5.2875993 | + | |
- | 166 4.3956646 | + | |
- | [ reached ' | + | |
> | > | ||
> print(paste0(" | > print(paste0(" | ||
- | [1] "Loss is: 228" | + | [1] "Loss is: 393" |
> | > | ||
> gradient <- function(x, y, predictions){ | > gradient <- function(x, y, predictions){ | ||
Line 411: | Line 248: | ||
> print(gradients) | > print(gradients) | ||
$db1 | $db1 | ||
- | [1] -149.8879 | + | [1] -200.6834 |
$db0 | $db0 | ||
- | [1] -28.50182 | + | [1] -37.76994 |
> | > | ||
Line 423: | Line 260: | ||
> | > | ||
> # Record Loss for each epoch: | > # Record Loss for each epoch: | ||
- | > logs = list() | + | > # logs = list() |
- | > bs=list() | + | > # bs=list() |
> b0s = c() | > b0s = c() | ||
> b1s = c() | > b1s = c() | ||
Line 435: | Line 272: | ||
+ loss = loss_mse(predictions, | + loss = loss_mse(predictions, | ||
+ mse = append(mse, loss) | + mse = append(mse, loss) | ||
- | + | + | + # logs = append(logs, |
- | + logs = append(logs, | + | |
+ | + | ||
+ if (epoch %% 10 == 0){ | + if (epoch %% 10 == 0){ | ||
Line 451: | Line 287: | ||
+ b1s <- append(b1s, b1) | + b1s <- append(b1s, b1) | ||
+ } | + } | ||
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | [1] " | + | [1] " |
- | > # I must unscale coefficients to make them comprehensible | + | > |
+ | > # unscale coefficients to make them comprehensible | ||
> b0 = b0 - (mean(x) / sd(x)) * b1 | > b0 = b0 - (mean(x) / sd(x)) * b1 | ||
> b1 = b1 / sd(x) | > b1 = b1 / sd(x) | ||
> | > | ||
+ | > # changes of estimators | ||
> b0s <- b0s - (mean(x) /sd(x)) * b1s | > b0s <- b0s - (mean(x) /sd(x)) * b1s | ||
> b1s <- b1s / sd(x) | > b1s <- b1s / sd(x) | ||
Line 468: | Line 306: | ||
> parameters <- tibble(data.frame(b0s, | > parameters <- tibble(data.frame(b0s, | ||
> | > | ||
- | > cat(paste0(" | + | > cat(paste0(" |
- | Inclination: 1.98275951151325, | + | Slope: 2.26922511738252, |
- | Intercept: 0.461293071825862 | + | Intercept: |
> summary(lm(y~x))$coefficients | > summary(lm(y~x))$coefficients | ||
- | Estimate Std. Error t value | + | |
- | (Intercept) 0.4612931 | + | (Intercept) |
- | x 1.9827596 | + | x 2.2692252 |
> | > | ||
> ggplot(data, | > ggplot(data, | ||
+ | + | ||
+ | + | ||
- | + data = parameters, linewidth = 0.5, color = 'red') + | + | + data = parameters, linewidth = 0.5, |
+ | + color = 'green') + | ||
+ | + | ||
+ | + | ||
+ data = parameters %>% slice_head(), | + data = parameters %>% slice_head(), | ||
- | + | + | + |
+ | + | ||
+ data = parameters %>% slice_tail(), | + data = parameters %>% slice_tail(), | ||
- | + | + | + |
- | + | + | + |
+ | > | ||
+ | > b0.init | ||
+ | [1] -1.67967 | ||
+ | > b1.init | ||
+ | [1] -1.323992 | ||
+ | > | ||
> data | > data | ||
- | # A tibble: | + | # A tibble: |
- | | + | |
- | < | + | < |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | 7 4.05 16.8 | + | |
- | 8 7.27 16.5 | + | 8 4.84 12.8 -8.09 20.9 |
- | | + | |
- | 10 | + | 10 |
- | # ℹ 490 more rows | + | # ℹ 290 more rows |
# ℹ Use `print(n = ...)` to see more rows | # ℹ Use `print(n = ...)` to see more rows | ||
> parameters | > parameters | ||
# A tibble: 80 × 3 | # A tibble: 80 × 3 | ||
- | b0s b1s mse | + | b0s b1s mse |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | 5 0.604 1.19 39.5 | + | |
- | 6 0.577 1.35 30.8 | + | |
- | 7 0.555 1.48 25.3 | + | |
- | 8 0.538 1.58 21.7 | + | |
- | 9 0.523 1.66 19.4 | + | |
- | 10 0.511 1.72 | + | 10 -0.303 1.91 18.5 |
# ℹ 70 more rows | # ℹ 70 more rows | ||
- | # ℹ Use `print(n = ...)` to see more rows | + | # |
- | > | + | |
- | > | + | |
</ | </ | ||
- | {{: | + | |
+ | {{: | ||
gradient_descent.1754023638.txt.gz · Last modified: 2025/08/01 13:47 by hkimscil