Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions _lamd/_lamd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ url: https://inverseprobability.com/
talkcss: https://inverseprobability.com/assets/css/talks.css
bibdir: $HOME/lawrennd/bibliography
postsdir: ../_lectures/
slidesdir: $HOME/lawrennd/slides/
slidesdir: ../slides/ # Where compiled slides go
notesdir: ../_notes/
notebooksdir: ../_notebooks/
practicalsdir: ../_practicals/
snippetsdir: $HOME/lawrennd/snippets
macrosdir: $HOME/lawrennd/lamd/lamd/macros
writediagramsdir: .
scriptsdir: https://inverseprobability.com/talks/scripts/
diagramsdir: ../slides/diagrams/
diagramsdir: $HOME/lawrennd/slides/diagrams/ # Shared figure library (copy_web_diagrams reads from here)
slidesheader: slides-header.html
notation: talk-notation.tex
posts: True
Expand Down
24 changes: 18 additions & 6 deletions _lamd/bayesian-regression.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,20 +83,31 @@ $$}

\addreading{@Bishop:book06}{Section 1.2.3 (pg 21–24)}
\addreading{@Rogers:book11}{Sections 3.1-3.4 (pg 95-117)}
\addreading{@Bishop:book06}{Section 1.2.3 (pg 21–24)}
\addreading{@Bishop:book06}{Section 1.2.6 (start from just past eq 1.64 pg 30-32)}

\reading

\include{_physics/includes/gauss-least-squares.md}
\include{_ml/includes/the-bayesian-approach.md}
\include{_ml/includes/bayesian-regression1d.md}
\include{_ml/includes/bayesian-1d-maths.md}
\include{_ml/includes/bayesian-regression1d-short.md}
\include{_ml/includes/bayesian-regression1d-maths.md}

\notes{
\subsection{Bayesian Inference in the Univariate Case}

This video talks about Bayesian inference across the single parameter, the offset $c$, illustrating how the prior and the likelihood combine in one dimension to form a posterior.

\figure{\includeyoutube{AvlnFnvFw_0}{600}{450}{15}}{Univariate Bayesian inference. Lecture 10 from 2012 MLAI Course.}{univariate-bayesian-inference-video}
}

\subsection{The Joint Density}

\slides{
* Really want to know the *joint* posterior density over the parameters $c$ *and* $m$.
* Could now integrate out over $m$, but it’s easier to consider the multivariate case.
* Could now consider $m$, but it is easier to consider the multivariate case.
}
\notes{This gives us the distribution over $c$, but in reality we want to know the *joint* posterior density over the parameters $c$ and $m$. We could find this by now considering $m$, but it is easier to consider the multivariate case.}

\include{_ml/includes/the-bayesian-approach.md}

\include{_ml/includes/two-d-gaussian.md}

Expand Down Expand Up @@ -147,7 +158,7 @@ sigma2 = 0.01}
* Revisit maximum likelihood solution with validation set.
}

\newslide{Regularized Mean}
\newslide{Regularised Mean}

\slides{
* Validation fit here based on mean solution for $\mappingVector$ only.
Expand All @@ -164,6 +175,7 @@ sigma2 = 0.01}
* In other cases $\alpha \eye$ *regularizes* the system (keeps parameters smaller).
}
\include{_ml/includes/posterior-sampling-basis.md}

\include{_ml/includes/polynomial-marginal-likelihood.md}
\include{_ml/includes/compute-output-expectations.md}

Expand Down
54 changes: 43 additions & 11 deletions _lamd/compile.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,43 @@
#/bin/bash

FILES=""
SKIP=true
while read stub; do
if $SKIP; then
SKIP=false
else
maketalk $stub
fi
done < lectures.csv
#!/bin/bash
# Compile lectures and worksheets listed in the CSVs (skip header row).
set -euo pipefail

cd "$(dirname "$0")"

compile_list() {
local csv="$1"
local skip=true
local stub
while IFS= read -r stub || [[ -n "$stub" ]]; do
stub="${stub//$'\r'/}"
[[ -z "$stub" ]] && continue
if $skip; then
skip=false
continue
fi
echo "maketalk ${stub}.md"
maketalk "${stub}.md"
done < "$csv"
}

compile_list lectures.csv
if [[ -f worksheets.csv ]]; then
compile_list worksheets.csv
fi

# Printable assessment handouts (pandoc), not LaMD.
handouts_dir="../assessments/handouts"
if [[ -f "${handouts_dir}/handouts.csv" ]]; then
skip=true
while IFS= read -r stub || [[ -n "$stub" ]]; do
stub="${stub//$'\r'/}"
[[ -z "$stub" ]] && continue
if $skip; then
skip=false
continue
fi
echo "pandoc ${stub}.md -> tex/pdf"
pandoc "${handouts_dir}/${stub}.md" -s -o "${handouts_dir}/${stub}.tex"
pandoc "${handouts_dir}/${stub}.md" -o "${handouts_dir}/${stub}.pdf"
done < "${handouts_dir}/handouts.csv"
fi
12 changes: 8 additions & 4 deletions _lamd/dimensionality-reduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ youtube: 0mtK2_rc0IY
\notes{So far in our classes we have focussed mainly on regression
problems, which are examples of supervised learning. We have considered the
relationship between the likelihood and the objective function and we have shown
how we can find paramters by maximizing the likelihood (equivalent to minimizing
the objective function) and in the last session we saw how we can *marginalize*
how we can find parameters by maximising the likelihood (equivalent to minimising
the objective function) and in the last session we saw how we can *marginalise*
the parameters in a process known as Bayesian inference.}


Expand All @@ -30,10 +30,14 @@ the parameters in a process known as Bayesian inference.}

\include{_dimred/includes/probabilistic-pca.md}

\include{_dimred/includes/mocap-ppca.md}
\include{_dimred/includes/osu-run1-ppca.md}
\include{_dimred/includes/robot-wireless-ppca.md}

\include{_dimred/includes/ppca-interpretations.md}
\include{_dimred/includes/pca-in-practice.md}
\include{_dimred/includes/pca-effectiveness.md}

\section{Derivation of PPCA}

\include{_dimred/includes/ppca-marginal-likelihood.md}
\include{_dimred/includes/ppca-reconstruction.md}

Expand Down
5 changes: 1 addition & 4 deletions _lamd/linear-regression.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,11 @@ youtube: 5VPr6NbHHjg
* This time: explore least squares for regression.

\include{_ml/includes/regression-examples.md}

\include{_datasets/includes/olympic-100m-data.md}


\include{_datasets/includes/olympic-marathon-data.md}
\include{_ml/includes/what-is-ml.md}
\include{_ml/includes/sum-of-squares-error.md}
\include{_ml/includes/linear-algebra-regression.md}
\include{_ml/includes/linear-regression-hessian.md}

\thanks

Expand Down
Loading
Loading