Eight projects and a full set of course notes from Machine Learning for Data Science, a graduate course at USC. The projects run from k-nearest neighbours and regression through trees, SVMs, and clustering to semi-supervised learning and transfer learning. Each is a standalone notebook with its own data, built around preparation, model selection, and honest evaluation.
| Project | Methods | Key result | Open |
|---|---|---|---|
| KNN and Distance Metrics Diagnose spinal abnormality from six biomechanical measurements. |
K-nearest neighbours · Euclidean, Manhattan, Minkowski, Chebyshev, and Mahalanobis metrics · distance-weighted voting | Test error 0.06 at k = 4; metric choice alone spans 0.06 to 0.17 | Open |
| Linear Regression on Power Plant Output Predict a power plant's hourly electrical output from ambient conditions. |
OLS · polynomial and interaction terms · backward elimination · KNN regression | Test MSE cut from 21.24 to 14.29 over the OLS baseline | Open |
| Time Series Activity Classification Recognize which of seven activities a person is doing from wireless sensor streams. |
Time-domain features · logistic regression with RFECV · L1 penalties · naive Bayes | 0.842 seven-class accuracy; the bending detector is exact on test | Open |
| Regularization and Decision Trees Make a clinical tree readable, then tame a 122-predictor crime regression. |
Cost-complexity pruning · ridge · LASSO · principal component regression · XGBoost | Ridge lowest of six models at 0.01732 test MSE | Open |
| Imbalanced Classification with SMOTE Detect failing air pressure systems in Scania trucks; failures are 1.67 percent of the training set. |
Random forest · class weights · SMOTE · XGBoost with L1 | Missed failures cut from 121 to 35 of 375 | Open |
| Multi-Label SVM and K-Means Clustering Label frog calls with family, genus, and species at once from 22 audio features. |
Gaussian-kernel SVM one-vs-all · L1 linear SVM · SMOTE · k-means with silhouette selection | All three labels right on 98.75 percent of test calls | Open |
| Semi-Supervised and Active Learning Measure how far models get when labels are scarce or chosen strategically. |
Supervised SVM · self-training · k-means and spectral clustering · margin-based active learning | Supervision holds the edge at 0.9708 over 30 fixed splits | Open |
| Transfer Learning for Fungi Image Classification Classify 9,114 microscopy images of fungal infections into five classes. |
Frozen ImageNet backbones · ResNet50 and ResNet101 · EfficientNetB0 · VGG16 · DenseNet201 | ResNet101 leads at 0.8476 test accuracy | Open |
I wrote these notes chapter by chapter through the course and assembled them into one book, from linear regression to deep learning. Every method gets its definitions, the formulas, a figure where one helps, and a plain explanation of why it works. Each chapter below opens the PDF at that chapter.
| Ch | Chapter | Topics | Open |
|---|---|---|---|
| 1 | Intro and Linear Regression | Learning paradigms, the bias-variance trade-off, nearest neighbors, OLS and inference, multicollinearity, interaction effects | Open |
| 2 | Classification | Logistic and multinomial regression, Bayes' rule, LDA and QDA, naive Bayes, error measures, class imbalance | Open |
| 3 | Linear Model Selection and Regularization | Subset selection, cross-validation, ridge, lasso, elastic net, principal components and partial least squares regression | Open |
| 4 | Tree-Based Methods | Regression and classification trees, pruning, bagging, random forests, boosting and AdaBoost, Extra Trees, stacking and mixtures of experts | Open |
| 5 | Support Vector Machines | Maximal and soft margins, kernels, multi-class and multi-label SVMs, hinge loss, VC dimension, support vector regression | Open |
| 6 | Unsupervised Learning | K-means and k-medoids, hierarchical clustering, choosing K with silhouette and gap statistics, PCA and the SVD, Fisher's LDA | Open |
| 7 | Semi-Supervised and Active Learning | Self-training, co-training, semi-supervised SVMs, cluster and label, uncertainty sampling, query by committee | Open |
| 8 | Neural Networks and Deep Learning | The perceptron, MLPs and backpropagation, dropout and regularization, CNNs, transfer learning, RNNs, LSTM and GRU | Open |