mirror of
https://github.com/harvard-edge/cs249r_book.git
synced 2026-05-06 17:49:07 -05:00
[PR #1337] [MERGED] test(tinytorch): add coverage tests for Module 08 training infrastructure #7283
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/harvard-edge/cs249r_book/pull/1337
Author: @Shashank-Tripathi-07
Created: 4/16/2026
Status: ✅ Merged
Merged: 4/16/2026
Merged by: @profvjreddi
Base:
dev← Head:test/training-module-coverage📝 Commits (2)
6b42b75test(tinytorch): add coverage tests for Module 08 training infrastructure13972d6fix(tests/08_training): correct scheduler lr assertion to use epoch 0 not epoch 1📊 Changes
1 file changed (+480 additions, -0 deletions)
View changed files
➕
tinytorch/tests/08_training/test_training_coverage.py(+480 -0)📄 Description
Summary
Six areas of Module 08 were fully implemented but had zero test coverage. This PR fills those gaps with a dedicated
test_training_coverage.py.Coverage
CosineScheduleclip_grad_normsave/load_checkpointTrainer.evaluateoptimizer.lrupdated to match schedule, decreases over epochsmodel.trainingcorrect aftertrain_epoch,evaluate, and train/eval/train cycleFiles
tinytorch/tests/08_training/test_training_coverage.py🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.