mirror of
https://github.com/rasbt/LLMs-from-scratch.git
synced 2026-04-11 14:21:41 +08:00
* Fix MHAEinsum weight dimension bug when d_in != d_out (#857) Previously MHAEinsum initialized weight matrices with shape (d_out, d_in) and used inappropriate einsum notation, causing failures for non-square input-output dimensions. This commit corrects weight initialization to shape (d_in, d_out), updates einsum notation to 'bnd,do->bno', and adds three unit tests to verify parity across different d_in and d_out settings. All tests pass successfully. * use pytest * Update .gitignore --------- Co-authored-by: rasbt <mail@sebastianraschka.com> |
||
|---|---|---|
| .. | ||
| basic-tests-latest-python.yml | ||
| basic-tests-linux-uv.yml | ||
| basic-tests-macos-uv.yml | ||
| basic-tests-old-pytorch.yml | ||
| basic-tests-pip.yml | ||
| basic-tests-pixi.yml | ||
| basic-tests-pytorch-rc.yml | ||
| basic-tests-windows-uv-pip.yml | ||
| basic-tests-windows-uv-pip.yml.disabled | ||
| basic-tests-windows-uv.yml.disabled | ||
| check-links.yml | ||
| check-spelling-errors.yml | ||
| pep8-linter.yml | ||