Skip to content

Commit 376d6d4

Browse files
committed
eq upd
1 parent 74e7669 commit 376d6d4

2 files changed

Lines changed: 34 additions & 4 deletions

File tree

docs/equations/pymle-equations.pdf

5.32 KB
Binary file not shown.

docs/equations/pymle-equations.tex

Lines changed: 34 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
\title{Python Machine Learning\\ Equation Reference}
1414
\author{Sebastian Raschka \\ \texttt{mail@sebastianraschka.com}}
15-
\date{ \vspace{2cm} 05\slash 04\slash 2015 (last updated: 06\slash 15\slash 2016) \\\begin{flushleft} \vspace{2cm} \noindent\rule{10cm}{0.4pt} \\ Code Repository and Resources:: \href{https://github.com/rasbt/python-machine-learning-book}{https://github.com/rasbt/python-machine-learning-book} \vspace{2cm} \endgraf @book\{raschka2015python,\\
15+
\date{ \vspace{2cm} 05\slash 04\slash 2015 (last updated: 06\slash 19\slash 2016) \\\begin{flushleft} \vspace{2cm} \noindent\rule{10cm}{0.4pt} \\ Code Repository and Resources:: \href{https://github.com/rasbt/python-machine-learning-book}{https://github.com/rasbt/python-machine-learning-book} \vspace{2cm} \endgraf @book\{raschka2015python,\\
1616
title=\{Python Machine Learning\},\\
1717
author=\{Raschka, Sebastian\},\\
1818
year=\{2015\},\\
@@ -333,12 +333,13 @@ \subsection{Minimizing cost functions with gradient descent}
333333
\begin{split}
334334
& \frac{\partial J}{\partial w_j} = \frac{\partial}{\partial w_j} \frac{1}{2} \sum_i \bigg( y^{(i)} - \phi \big( z^{(i)} \big) \bigg)^2 \\
335335
& = \frac{1}{2} \frac{\partial}{\partial w_j} \sum_i \bigg( y^{(i)} - \phi \big( z^{(i)} \big) \bigg)^2 \\
336-
& = \frac{1}{2} \sum_i 2 \bigg( y^{(i)} - \phi \big( z^{(i)} \big) \bigg) \frac{\partial J}{\partial w_j} \Bigg( y^{(i)} - \sum_i \bigg( w_{j}^{(i)} x_{j}^{(i)} \bigg)\Bigg) \\
336+
& = \frac{1}{2} \sum_i 2 \big( y^{(i)} - \phi(z^{(i)})\big) \frac{\partial}{\partial w_j} \Big( y^{(i)} - \phi({z^{(i)}}) \Big) \\
337+
& = \sum_i \big( y^{(i)} - \phi (z^{(i)}) \big) \frac{\partial}{\partial w_j} \Big( y^{(i)} - \sum_i \big(w^{(i)}_{j} x^{(i)}_{j} \big) \Big) \\
337338
& = \sum_i \bigg( y^{(i)} - \phi \big( z^{(i)} \big) \bigg) \bigg( - x_{j}^{(i)} \bigg) \\
338339
& = - \sum_i \bigg( y^{(i)} - \phi \big( z^{(i)} \big) \bigg) x_{j}^{(i)} \\
339340
\end{split}
340341
\end{equation*}
341-
342+
?
342343
Performing a matrix-vector multiplication is similar to calculating a vector dot product where each row in the matrix is treated as a single row vector. This vectorized approach represents a more compact notation and results in a more efficient computation using NumPy. For example:
343344

344345
\[
@@ -409,7 +410,7 @@ \subsection{Logistic regression intuition and conditional probabilities}
409410
event. The term positive event does not necessarily mean good, but refers to the event that we want to predict, for example, the probability that a patient has a certain disease; we can think of the positive event as class label $y =1$. We can then further define the logit function, which is simply the logarithm of the odds ratio (log-odds):
410411

411412
\[
412-
logit(p) = log \frac{p}{1-p}
413+
logit(p) = \log \frac{p}{1-p}
413414
\]
414415

415416
The logit function takes input values in the range 0 to 1 and transforms them to values over the entire real number range, which we can use to express a linear relationship between feature values and the log-odds:
@@ -1180,6 +1181,35 @@ \section{Summary}
11801181

11811182

11821183

1184+
%%%%%%%%%%%%%%%
1185+
% CHAPTER 6
1186+
%%%%%%%%%%%%%%%
1187+
1188+
\chapter{Learning Best Practices for Model Evaluation and Hyperparameter Tuning}
1189+
1190+
\section{Streamlining workflows with pipelines}
1191+
\subsection{Loading the Breast Cancer Wisconsin dataset}
1192+
\subsection{Combining transformers and estimators in a pipeline}
1193+
\section{Using k-fold cross-validation to assess model performance}
1194+
\subsection{The holdout method}
1195+
\subsection{K-fold cross-validation}
1196+
\section{Debugging algorithms with learning and validation curves}
1197+
\subsection{Diagnosing bias and variance problems with learning curves}
1198+
\subsection{Addressing overfitting and underfitting with validation curves}
1199+
\section{Fine-tuning machine learning models via grid search}
1200+
\subsection{Tuning hyperparameters via grid search}
1201+
\subsection{Algorithm selection with nested cross-validation}
1202+
\section{Looking at different performance evaluation metrics}
1203+
\subsection{Reading a confusion matrix}
1204+
\subsection{Optimizing the precision and recall of a classification model}
1205+
1206+
\[
1207+
ERR = \frac{FP + FN}{FP + FN + TP + TN}
1208+
\]
1209+
1210+
\subsection{Plotting a receiver operating characteristic}
1211+
\subsection{The scoring metrics for multiclass classification}
1212+
\section{Summary}
11831213

11841214

11851215
\newpage

0 commit comments

Comments
 (0)