[PR #1117] [MERGED] fix: fix module import in Transformers module test #1127

Closed
opened 2026-03-22 16:01:21 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/harvard-edge/cs249r_book/pull/1117
Author: @minhdang26403
Created: 1/19/2026
Status: Merged
Merged: 1/19/2026
Merged by: @profvjreddi

Base: devHead: fix/transformers-test


📝 Commits (2)

  • 3bbb0ae fix: fix GPT model to use Embedding Layer created in module 11 instead of re-defining token embedding and positional embedding
  • a673625 fix: fix module import in Transformers module test

📊 Changes

3 files changed (+32 additions, -41 deletions)

View changed files

📝 tinytorch/src/13_transformers/13_transformers.py (+17 -27)
📝 tinytorch/tests/13_transformers/test_training_simple.py (+8 -8)
📝 tinytorch/tests/13_transformers/test_transformers_core.py (+7 -6)

📄 Description

The current tests for Transformers module have wrong import path for Transformers, which lead to test failure. This Pull Request attempts to fix that issue.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/harvard-edge/cs249r_book/pull/1117 **Author:** [@minhdang26403](https://github.com/minhdang26403) **Created:** 1/19/2026 **Status:** ✅ Merged **Merged:** 1/19/2026 **Merged by:** [@profvjreddi](https://github.com/profvjreddi) **Base:** `dev` ← **Head:** `fix/transformers-test` --- ### 📝 Commits (2) - [`3bbb0ae`](https://github.com/harvard-edge/cs249r_book/commit/3bbb0ae27aa85d8da10b591ec5323a18f86d4728) fix: fix GPT model to use Embedding Layer created in module 11 instead of re-defining token embedding and positional embedding - [`a673625`](https://github.com/harvard-edge/cs249r_book/commit/a6736258446746d4aeeb9406b3a57ffd482b739f) fix: fix module import in Transformers module test ### 📊 Changes **3 files changed** (+32 additions, -41 deletions) <details> <summary>View changed files</summary> 📝 `tinytorch/src/13_transformers/13_transformers.py` (+17 -27) 📝 `tinytorch/tests/13_transformers/test_training_simple.py` (+8 -8) 📝 `tinytorch/tests/13_transformers/test_transformers_core.py` (+7 -6) </details> ### 📄 Description The current tests for Transformers module have wrong import path for Transformers, which lead to test failure. This Pull Request attempts to fix that issue. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-03-22 16:01:21 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/cs249r_book#1127