15-288 - Spring 2026

Machine Learning
in a Nutshell




Key Information

Lectures: TR 11:30am - 12:45pm, Room 1199

Labs/Recitations: (usually) U 11:30am - 12:45pm, Room 1199

9.0

12% Laboratories, 25% In-Class Quizzes, 15% Final Exam, 18% Homework, 30% Project

15-112 passed with a C or a higher letter grade

Dr. Mohammed Yusuf Ansari

Salman Hajizada


Overview

This course focuses on the application of machine learning (ML) concepts and models to solve challenging real-world problems.
The emphasis is on the methodological and practical aspects of designing, implementing, and utilizing ML solutions.
Course topics are structured around the concept of the ML process pipeline, which outlines the multi-stage process of building and deploying an ML solution. An ML pipeline includes:

  • Defining the problem, objectives, and performance metrics;
  • Collecting and managing relevant operational data;
  • Data wrangling (transforming, cleaning, filtering, scaling);
  • Performing feature engineering, including feature selection, extraction, and processing;
  • Selecting appropriate ML models based on problem requirements and available data;
  • Implementing, testing, and evaluating the selected model(s);
  • Deploying the final ML model.

The process iterates through these stages, proceeding forward and backward, until a satisfactory model is developed.
The workflow of an ML pipeline is illustrated in the figure below (source: Practical ML with Python).

This course covers all stages of the ML pipeline, offering conceptual insights and providing algorithmic and software tools to address challenges effectively at each stage.
The Python ecosystem for data science and ML, including tools like pandas, numpy, matplotlib, scikit-learn, keras, pytorch, and Jupyter Notebooks, will be introduced and used to retrieve, store, manipulate, visualize, and perform exploratory analysis of the data.

Course Topics:

  • From raw data to useful information for the learning task
    The first part of the course addresses the data aspects of the pipeline, covering data mining, collection, filtering, processing, and feature engineering for various types of data (numeric, categorical, textual, image, temporal).
  • Supervised machine learning models for classification and regression tasks
    A wide range of supervised ML techniques and models will be studied, including:
    • k-Nearest Neighbors,
    • Least Squares Linear Regression,
    • Decision Trees,
    • Linear Models,
    • Gradient Methods,
    • Cross-Validation Methods,
    • Regularization Techniques,
    • Naive Bayes,
    • Logistic Regression,
    • Support Vector Machines (SVMs),
    • Kernelization,
    • Bagging, Random Forests, Boosting,
    • Neural Networks: MLPs, CNNs, Deep Networks.
  • Unsupervised Learning Techniques
    We will introduce unsupervised machine learning methods for discovering structure in data without labeled examples. The focus will be on learning meaningful data representations, performing dimensionality reduction, and enabling data compression. Core topics include clustering methods, Principal Component Analysis (PCA), and autoencoders, supported by practical experiments and visualizations.
  • Transformers and Large Language Models
    We will study Transformer architectures for deep learning, focusing on the processing of sequential and structured data through self-attention mechanisms. Applications in Natural Language Processing and Computer Vision will be discussed, with particular emphasis on Large Language Models (LLMs) such as ChatGPT. The course will include hands-on activities using the OpenAI API, covering prompt engineering, controlled text generation, and model adaptation techniques. We will also introduce the foundations of agentic AI systems, where LLMs are used as autonomous or semi-autonomous agents capable of reasoning, planning, tool usage, and multi-step decision making.
  • Diffusion Models
    We will introduce Diffusion Models as a modern approach to generative modeling, focusing on their intuitive idea of gradually adding noise to data and learning to remove it. Without delving into advanced mathematical formalism, we will emphasize practical understanding through visualization and experimentation. Students will explore how diffusion models are used in image generation and text-to-image systems, and will work hands-on with simplified implementations and pre-trained models to understand the denoising process, sampling steps, and conditioning mechanisms.

The course introduces each model conceptually and provides algorithmic and software tools necessary for experimentation with different datasets.
Discussions on generalization, bias and variance, model evaluation, and selection using cross-validation techniques complete the ML pipeline.
Techniques will be tested in diverse problem domains and data types, including: natural language processing, computer vision, financial forecasting, logistics, production planning, and biomedical data analysis.

Learning Objectives

Students who successfully complete the course will have acquired a general knowledge of the main concepts and techniques of data science and ML, and will be adept to use ML in different fields of application.
The course will provide the students with a toolkit of different skills needed to effectively go through the entire ML pipeline. The students will acquire conceptual and practical knowledge about:

  • collecting, handling, exploring, and wrangling data in different formats and originating from different sources;
  • selecting, extracting and engineering data features using both manual and learning techiques;
  • identifying the most appropriate ML techniques for the problem and the data at hand;
  • implementing and using a set of core ML models;
  • testing and evaluating ML models;
  • using the Python ecosystem for ML and data science;
  • using the OpenAI API and exploiting the capabilities of ChatGPT and other LLMs;
  • using APIs exploiting the power of diffusion models for generative AI in image processing;
  • <
  • applying ML to problems from a range of different application domains.

Course Layout

  • Course is based on two lectures per week where the different problems, solution models, and algorithms are formally introduced. The introduction of a new concept is always accompanied by the presentation of practical use cases.

  • Each week, a third class is usually employed as a graded laboratory. Laboratory classes let the students aswering graded assignments that require both programming hands-on and conceptual understanding of course subjects. During the labs students can freely collaborate and check course material.

Prerequisites

Having passed 15-112 with a C (minimum).

The basic notions of linear algebra, calculus, and probability theory that are necessary for the understanding of the formal concepts will be explained assuming no or little previous knowledge.

Assignments and Grading

Assignments:

  • Laboratory Assessments: Students attend laboratory classes (LabTests) in which they answer questions involving both hands-on programming and conceptual aspects. LabTests are typically held weekly and require students to prepare a Jupyter notebook integrating code, plots, and written discussion. During the laboratory sessions, students may freely collaborate with one another and consult course material as well as external resources.
  • Quizzes: (Typically) at the beginning of a laboratory class, students take a (Quiz) consisting of multiple questions that combine conceptual understanding with programming and implementation aspects related to the topics covered during the week. Quizzes are intended as a way to periodically assess students’ understanding of course concepts, as well as to encourage adequate preparation for the laboratory sessions.
  • Homework: Outside of the classroom, students practice with multiple homework consisting of programming tasks integrated in Jupyter notebooks. In the homework, students implement and experiment with the different algorithmic solutions, are confronted with different types of data, answer to conceptual questions, learn how to present material and results combining text, data, images, and code.
  • Project: Students have to complete a project that addresses the full ML pipeline and iteration cycle. Project work is staged in two tasks and comprises four deliverables. The final report is in the form of a Jupyter notebook implementing a Query Answering Machine for an application domain selected by the student. The project is done in small groups and the results are presented and discussed at the end of the course.
  • Final Exam: At the end of the course, there will be a written exam that will summarize the concepts addressed during the course.

Grading scheme:

  • 25% Quizzes
  • 12% Laboratory Assessments
  • 15% Final Exam
  • 18% Homework
  • 30% Project

Readings

In addition to the lecture handouts and python notebooks (that will be made available after each lecture), during the course additional material will be provided by the instructor to cover specific parts of the course.

A number of (optional) textbooks can be consulted to ease the understanding of the different topics (the relevant chapters will be pointed out by the teacher), these include, but are not restricted to:

  • Machine Learning, Tom Mitchell (in the library)
  • Machine Learning: The Art and Science of Algorithms that Make Sense of Data, P. Flach
  • A Course in Machine Learning, Hal DaumĂ©, available online
  • Natural Language Processing with Transformers: Building Language Applications with Hugging Face, Lewis Tunstall, Leandro von Werra, Thomas Wolf

Schedule



-->
Date Topics Handouts Extra Material
1/6 Course introduction, General ML concepts, ML pipeline, ML & Data Science Software ecosystem

Introduction to software tools:
pdf (up to slide 18)
1/8 More on ML concepts, ML pipeline, ML & Data Science pdf (from slide 18)

1/11 Core ML tasks (supervised, unsupervised, and reinforcement learning), application problems pdf
1/13 Supervised Learning (SL) flow, model hypotheses, canonical SL problem. pdf
1/15 Generalization error, Empirical risk minimization pdf (up to slide 32)

1/18 Quiz 1 + LabTest 1: Fundamentals of ML, NumPy, Jupyter notebooks and Markdow Check software tools material from Lecture 1
1/20 More on Generalization error, Loss functions pdf (from slide 32)
1/22 Workflow for Regression, Generalization and Overfitting pdf (up to slide 22)

1/25 Quiz 2 + Generalization and Cross-Validation pdf (from slide 22)
1/27 From data to models with sklearn and pandas: a complete regression example, model selection, loss functions Notebook Datasets:
1/29 Break, no classes

2/1 Linear Regression: Ordinary Least Squares (OLSR) pdf
2/3 Scikit-learn methods for OLSR, Cross-Validation, Visualization Notebook
2/5 Quiz 3 + LabTest 3: Linear Regression, Cross-Validation, Model Selection

2/8 K-Nearest Neighbors (K-NN) classifier, model selection with CV, measures of performance in classification Notebook1
Notebook2
Datasets:
2/10 National Sports Day, no classes
2/12 Data wrangling 1 - Fill in and Drop out: Missing values Notebook Datasets:

2/15 Quiz 4
Data Wrangling 2 - Outliers 1
Notebook
2/17 Data Wrangling 3 - Outliers 2
2/19 Labtest 3: k-NN, Data Wrangling

2/22 Spring break
2/24 Spring break
2/26 Spring break

3/1 Data Wrangling 4 - Data Scaling Notebook
3/3 Feature engineering 1 - Feature Selection, Correlations, Feature Transformations Notebook Datasets:
3/5 Feature engineering 2 - Feature Transformations Lecture interrupted and cancelled because of war Notebook of 3/3

3/8 Feature engineering 2 - Feature Transformations, Sklearn methods Notebook of 3/3
3/10 Feature engineering 3 - Feature extraction methods for different data types Notebook Datasets:
3/12 Feature engineering 4 - Image data 1 Notebook Cat image
Dog image
Panda image
Sea image
Lena b/w
Petra image
Imperia image
Palm tree image
Coder survey

3/15 Feature engineering 5 - Image data 2 Notebook
3/17 Feature engineering 6 - Image data 3 Notebook
3/17 Linear Models 1 pdf

3/22 Eid al-Fitr, no classes
3/24 Eid al-Fitr, no classes
3/26 Eid al-Fitr, no classes

3/29 Linear Models 2, Gradient Methods for Model Optimization pdf Gradient descent notebook
3/31 Linear Models 3 - Examples of gradient methods for linear classifiers, SVM 1
Introduction to Project assignment
pdf (SVM 1+2) Gradient descent notebook
4/2 Linear Models 4 - SVM 2 Notebook

4/5 Probabilistic Models, Linear Models 5: Logistic Regression pdf
4/7 Kernelization of Linear Models pdf Notebook
4/9 Quiz 5: Feature engineering for Image data, Gradient methods, Linear models
Non-Linear and Non-Parametric Models - Decision Trees

4/12 Neural Networks 1 - Multi-Layer Perceptrons (MLPs), Designing and running a neural model.
4/14 Neural Networks 2 - Convolutional Neural Networks (CNNs)
Project checkpoint
4/16 From Text Sequences to Generative AI: Attention, Transformers, and LLMs

4/19 From Image Data to Generative AI: Diffusion Model and Vision Transformers
4/21 Agentic AI
Course review
4/23 Quiz 6: Neural Networks, Transformers, and Generative AI
Project checkpoint

Homework Assignments

(Schedule and topics are subject to changes)
Topic Files Due Dates
Homework 1: A Classification task: from data ingestion to model selection and testing
Homework 2: Data wrangling and Feature engineering for regression tasks
Homework 3: Comparison of ML models for supervised classification
Homework 4: Neural networks and unsupervised learning for image and time series data


Quizzes + LabTests

(Schedule and topics are subject to changes)
Topic Files Due Dates
LabTest 1: Fundamentals of ML, NumPy, Jupyter notebooks and Markdow
LabTest 2: ML pipeline and python tools for a regression task
LabTest 3: Classification pipeline using K-NN
LabTest 4: Missing values, Outliers, Scaling
LabTest 5: Feature engineering
LabTest 6: Linear models, Gradient methods
LabTest 7: Neural networks
LabTest 8: Unsupervised learning
LabTest 9: Generative AI


Project

A Query Answering Machine (QuAM)

Deliverables Files Due Dates
D1 [Report]: Initial Proposal and Dataset
D2 [Dataset and Notebook]: Final Dataset
D3 [Software and Notebook]: Query Answering Machine (QuAM)
D4 [Presentation]: Final report


Policies for Assignments

  • Homework is due on Gradescope by the posted deadline. Assignments submitted past the deadline will incur the use of late days.

  • You have 2 late days in total, but cannot use more than 1 late day per homework. No credit will be given for homework submitted more than 2 days after the due date. After the 2 late days have been used you will receive 30% off for each additional day late.

  • For homework, you can discuss the exercises with your classmates, but you should write up your own solutions. If you find a solution in any source other than the material provided on the course website or the textbook, you must mention the source.

  • In general, for all types of assignments and tests, CMU's directives for academic integrity apply and must be duly followed.

Office Hours

Name Email Hours Location
Gianni Di Caro gdicaro@cmu.edu By appointment, drop by M 1007
Yusuf Ansari ma1@andrew.cmu.edu TBD Office
Salman Hajizada shajizad@andrew.cmu.edu TBD ARC