Syllabus
Meeting times and location
Mondays 12:15pm-2:00pm, and Tuesdays, Wednesdays, and Thursdays 2:15pm-4:00pm at room 004.
Instructor
Pál Zsámboki zsamboki@renyi.hu
Course description
This is an introductory course to Deep Learning. We will learn to efficiently implement, train, and evaluate neural network models, building upon relevant Mathematics. We will use the PyTorch library, which will be introduced as we go. We will warm up by teaching a precursor model, logistic regression, a simple image classification task. Then after a brief introduction to Reinforcement Learning, we shall study Multilayer Perceptrons, the simplest Deep Learning architecture. Afterwards, we shall introduce the general approach of Geometric Deep Learning and investigate two very important realizations of it: Convolutional Neural Networks and Transformers, the current architecture of choice for most Large Language Models. We will finish with student presentations on additional topics (see below).
Prerequisites
Linear algebra, elementary probability, basic calculus, basic familiarity with Python or willingness to pick it up in the first few weeks.
If you need a refresher, or some introduction, here are some recommendations:
Genepy -- Python Exercises
Python on Exercism
Learn Python Basics on Programiz
Topics
- Basic Machine Learning: Linear regression and classification, dataset splits, metrics, losses, stochastic gradient descent.
- Evaluation and hyperparameter tuning: Confidence intervals, ensemble methods, early stopping, grid search.
- Reinforcement Learning: Markov Decision Processes, Bellmann Equation, dynamic programming, Monte Carlo methods, Q-Learning.
- Multilayer Perceptrons and Optimizers: Initialization, momentum, Adaptive Moment Estimation (Adam).
- Deep Reinforcement Learning: Policy Gradient Theorem, REINFORCE, Deep Q-Network.
- Introduction to Geometric Deep Learning: Symmetries, invariant and equivariant maps.
- Convolutional Neural Networks: Convolution, normalization, dropout, residual connections.
- Working with Text: Tokenization, handling sequential data of varying length, word vectors.
- Transformers: Attention, positional encodings, Masked Language Modeling, Next Token Prediction, alignment with human and AI preferences (eg. ChatGPT).
Final presentation topics
Part of class work is to develop a topic and give an oral and a written presentation of it. This can be presenting some area of Deep Learning not covered in class, for example:
- Bring Your Own Topic! It can be another area of Deep Learning or even independent research: I would be happy to help you get started on your own Deep Learning project.
- Attention Dispersion
- Decision Transformers
- Diffusion models
- Direct Preference Optimization
- Graph Neural Networks (GNN)
- Grokking
- Length Generalization
- Mechanistic Interpretability
- Point Cloud Learning
- Proximal Policy Optimization (PPO)
- Rainbow: Combining Improvements in Deep Reinforcement Learning
- Recurrent Neural Networks (RNN): Stateful Neural Networks, Long-Short Term Memory (LSTM), Gated Recurrent Unit (GRU)
-
SUNRISE: A Simple Unified Framework for Ensemble Learning in Deep Reinforcement Learning
-
Unbalanced datasets: Under- and oversampling, Focal loss.
Scoring
You final score will be the sum of your homework score, your written presentation score and your oral presentation score. Out of these three, the best score will weight 40%, the other two 30%.
Homeworks
You will get assigned homework roughly twice per week. Each homework will be due 1 week after the day it was announced, at 10:00 am. A precise schedule will be provided. You can expect me to answer a question related to a homework if asked at least 24 hours prior to this time.
Time-Based Multiplier
If you hand in your homework earlier than the deadline, you get a bonus, and if you hand it in at most 3 days late, you can still get some score for it, although with a penalty multiplier. The precise formula is as follows: let \(t\) denote the number of days you handed in your homework late. Then your homework score is going to be multiplied by
- \(1.1\), if \(t<-3\),
- \(1.1 - \frac{t + 3}{30}\), if \(-3\le t<0\),
- \(\cos\left(\frac{t}{3}\cdot\frac{\pi}{2}\right)\), if \(0\le t<3\), and
- \(0\), if \(3\le t\).
That is, for example:
- If you hand in your homework 3 days early, your score will be multiplied by \(1.1\).
- If you hand in your homework 2 days early, your score will be multiplied by \(1 + \frac{2}{30}\approx1.067\).
- If you hand in your homework 1 day early, your score will be multiplied by \(1 + \frac{1}{30}\approx1.033\).
- If you hand in your homework 3 hours late, your score will be multiplied by \(\cos\left(\frac{3}{24\cdot3}\cdot\frac{\pi}{2}\right)\approx0.998\).
- If you hand in your homework 12 hours late, your score will be multiplied by \(\cos\left(\frac{12}{24\cdot3}\cdot\frac{\pi}{2}\right)\approx0.966\).
- If you hand in your homework 1 day late, your score will be multiplied by \(\cos\left(\frac{1}{3}\cdot\frac{\pi}{2}\right)\approx0.866\).
- If you hand in your homework 2 days late, your score will be multiplied by \(\cos\left(\frac{2}{3}\cdot\frac{\pi}{2}\right)\approx0.500\).
Your worst homework score will be dropped.
Early Grading Requests
Since homeworks are due 1 week after they were announced, and they have a nonzero multiplier up to 3 days after the deadline, by default, I will start grading homeworks 10 days after they were announced. If you would like to have your homework graded earlier, you can write me an email where you state that:
- your most recent submission is final, and
- you will not discuss the feedback you received with any of your classmates until 3 days after the deadline,
and then I will try to grade your homework earlier.
Hand-In Instructions
Please hand in homework via email, in py files. The filename should have the pattern {name}-{homework id}.py. For example, I would submit the third homework as pal-zsamboki-3.py. If you import from a custom file, please include that in your submission too.
Please make sure that your homework file can be run as intended, using
python {name}-{homework id}.py
- Safest: Copy the full
pyfile contents to a single cell in a new notebook, and run it. - Less safe, but faster: Perform Reset and Run All on the notebook. This helps make sure that all variables are defined explicitly in the notebook.
In either case, if you can only test your submission in notebook format, make sure that you delete notebook-only commands such as
- Terminal commands starting with
!or - Magic commands starting with
%.
Collaboration and External Sources
You are strongly encouraged to discuss homework problems with other students in the course, however, you are required to write your own solutions. You are supposed to understand your own solutions in full detail.
If you rely on sources different from the course notes, it is expected that you name these sources and the extent you have made use of them. In particular, if you rely on a AI assistant (chatbot), please indicate the model name (eg. ChatGPT 5.5 or Gemini 3.5 Flash).
Final Project
The other two parts of your total score will come from a final project. Here, you'll explore and present a Deep Learning topic on your own. See Final presentation topics for a list of potentional topics. You are very welcome to bring your own topic! In that case, please write me your suggestion.
Topic selection: due 6/24
You are very welcome to work in groups! In that case, I'll ask you to make it clear who covered which part.
- If you are the first to choose a topic, please raise an issue in the class repository about it.
- If you want to work on a topic someone else already raised an issue about, please write a comment in the issue.
Please choose a topic by June 24, 6:00pm.
Presentation proposal: due 7/8
In this phase, I expect you to explore the topic you chose. By July 8, 6:00pm, please send me a presentation proposal of at least 200 words per group member. It should include:
- A brief description of the topic you chose.
- At least 3 references you'll use to prepare your presentation, and a description of what you'll use each reference for.
- An experiment proposal. Usually, this can be a simple modeling experiment, where you set up a model and train it on a relevant dataset.
Starting July 9, I'll meet with each group to discuss the presentations. To facilitate this, when you hand in your presentation proposal, please also tell me the times you will be available to meet July 9-15.
Written presentation: first version due 7/22, final version due 7/31
You should send me your written presentation of at least 500 words per group member by July 22, 6:00pm. This should include:
- A detailed description of the topic.
- At least 3 references, together with a description of what you used each reference for.
- Discussion of your experiment.
You should also send me the code you used to run your experiment.
Starting July 23, I'll meet with each group to discuss the written and oral presentations. To facilitate this, when you hand in your first version, please also tell me the times you will be available to meet July 23-29. Based on this discussion, you can change your written presentation and send me an updated version by July 31, 12:00pm. This is a hard deadline, no early or late multiplier. You'll get your written presentation score based on the final version.
Oral presentation: Exam period
You will have to present your topics in class during our allotted time in the exam period. The talks should be about 10-15 minutes long per group member. You'll get your oral presentation score based on your talk.
Grading
Grades will be calculated from the score via the following grading scale:
| Grade | Percentage |
|---|---|
| A+ | 97%-100% |
| A | 93%-96% |
| A- | 90%-92% |
| B+ | 87%-89% |
| B | 83%-86% |
| B- | 80%-82% |
| C+ | 77%-79% |
| C | 73%-76% |
| C- | 70%-72% |
| D+ | 67%-69% |
| D | 63%-66% |
| D- | 60%-62% |
| E / F | 0%-59% |
Office Hours
By appointment, online or in person. Write or tell me if you want to set up a meeting.
Suggested Reading
- François Fleuret: The Little Book of Deep Learning
In the author's words, "a short introduction to deep learning for readers with a STEM background, originally designed to be read on a phone screen". - Simon J. D. Prince: Understanding Deep Learning
A nicely paced textbook that can be followed as we go along the course. - Kevin Murphy: Probabilistic Machine Learning: An Introduction
A very detailed textbook that can be used as a reference.
