Last updated: April 04, 2026
By M. Ali Yousuf
[Disclaimer: The code on this page is NOT written by me and comes from the original author/website mentioned in each Google Colab notebook. I have made modifications, when needed, to make them run from within Google Colab, and some extra comments/text added to explain the code.]
This course introduces Generative AI (GenAI) by focusing on practical applications and hands-on experience with cutting-edge GenAI models. Students will learn to implement and apply GenAI models to generate text, images, music, and videos while addressing the ethical challenges inherent in GenAI.
DATA 602 or CMSC 478/678 - Introduction to Machine Learning. Completion required.
Students will also need access to a powerful laptop, or preferably, a paid Google Colab Professional account.
The course will use Python 3. It is the student’s responsibility to have a working environment. If you’d like the environment installed locally, Anaconda is a Python distribution with all the required libraries. The recommended option is to use Google’s Colab, which is available from your UMBC account. Both options are a search away.
Class participation: 10%
Homework 40%
Quizzes 20%
Project: 40 %
The final grade will be computed as follows:
• >=95, A
• 88 <= A– <95
• 83 <= B+ <98
• 77 <= B < 83
• 71 <= B– < 77
• 66 <= C+ < 71
• 60 <= C < 66
• 50 <= D < 60
• F <= 49
Students who cheat will get an F (no excuse is acceptable), and the incident reported to the UMBC Central.
Late/incomplete assignments will be accepted only if an extension is agreed to before the deadline. Emergencies will be handled case-by-case with appropriate justification or documentation. Incomplete grades are granted only for extenuating circumstances and your request is made before the last week of class.
Deduction for late submission in all other cases:
10% deduction for late submissions up to 24 hours after the deadline, 20% for late submissions up to 48 hours after the deadline, and 40% for late submissions up to 72 hours after the deadline. Beyond 72 hours, marks will be 0. You can get ONE exception to this during the semester. This applies to all submissions put together – homework + quizzes + Project.
You will get all the lectures in Google Colab format. Rather than giving you the files, I will be providing links to ipynb files (inside Blackboard) so that I can keep updating and fine-tuning them and you will always get the latest version. Some of these files depend upon other ".py" files which must be in the same directory. One way was to give you all those files and tell you which one goes with which file. That could have confused you. The current versions are stand-alone in the sense that any .py file that is needed, is generated within the ipynb file and that section of the code is hidden (but you can open it) so as not to confuse the main flow. Many lectures are from the book by Raschka, chapter by chapter. He himself created a series of videos for each chapter. These can be found here:
Foster Chapter 3 - Variational Autoencoders
Code - Autoencoder - Fashon Database: https://github.com/davidADSP/Generative_Deep_Learning_2nd_Edition/blob/main/notebooks/03_vae/01_autoencoder/autoencoder.ipynb
Code - Variational Autoencoders - Fashion Database: https://github.com/davidADSP/Generative_Deep_Learning_2nd_Edition/blob/main/notebooks/03_vae/02_vae_fashion/vae_fashion.ipynb
Code - Variational Autoencoders - Celebrity Face Database: https://github.com/davidADSP/Generative_Deep_Learning_2nd_Edition/blob/main/notebooks/03_vae/03_vae_faces/vae_faces.ipynb
Raschka Chapter 1 - Understanding Large Language Models.ipynb.
Watch Video (Not required as the video talks about how to setup a python enviornment whereas we'll use Google Colab. https://youtu.be/yAcWnfsZhzo?si=AcxzYiJCvXvOiJVb)
Raschka Chapter 2 - Working with Text Data.ipynb.
Raschka Chapter 3 - Coding Attention Mechanisms.ipynb.
Raschka Chapter 4 - Implementing a GPT model from Scratch To Generate Text.ipynb.
Raschka Chapter 5 - Pretraining on Unlabeled Data.ipynb.
Raschka Chapter 6 - Finetuning for Classification.ipynb.
Raschka Chapter 7 - Finetuning to Follow Instructions.ipynb.
Additional Material (to be covered if time permits): Implementing DoRA (an Improved LoRA) from Scratch. A powerful LoRA-variant explained in a beginner-friendly way and implemented in PyTorch, https://www.dailydoseofds.com/implementing-dora-an-improved-lora-from-scratch/
None. Students will get access to Jupyter Notebooks with all the necessary theory, equations and diagrams built-in. However, the book by Raschka is highly recommended.
Sebastian Raschka, “Build a Large Language Model (From Scratch)”, Manning Publications 2024.
The corresponding GitHub page (with information to buy the book) can be found here: https://github.com/rasbt/LLMs-from-scratch/tree/main. This book is used for most of the lectures.
There is a (paid, $47.99) course by the same author called "Master and Build Large Language Models - Code with Sebastian Raschka" available at https://www.manning.com/livevideo/master-and-build-large-language-models (The video links above for each chapter, also cover the same material).
Some additional books are:
David Foster, “Generative Deep Learning: Teaching Machines to Paint, Write, Compose, and Play”. 2nd Edition. O'Reilly Media, Incorporated 2023.
The corresponding GitHub page (with information to buy the book) can be found here: https://github.com/davidADSP/Generative_Deep_Learning_2nd_Edition. The image and music generation parts come from this book.
Alammar and Grootendorst, "Hands-On Large Language Models".
Github repo, https://github.com/HandsOnLLM/Hands-On-Large-Language-Models (all code runs in Google Colab)
For a review of Deep Learning, see Deep Learning - An MIT Press book (free) by Ian Goodfellow and Yoshua Bengio and Aaron Courville, https://www.deeplearningbook.org/)
For an NLP Review, see Speech and Language Processing (free), https://web.stanford.edu/~jurafsky/slp3/ Or Natural Language Processing with Python (free), https://www.nltk.org/book/
(For a 2.5-hour class offered in Fall or Spring, total 150 minutes)
45 Minutes – Lecture + Break 1 (+10 Minutes)
45 Minutes – Lecture/Class Work/Lab + Break 2 (+10 Minutes)
40 Minutes – Class Work / Group Discussion