Files
TinyTorch/modules/source
Vijay Janapa Reddi 1cbf3972c1 fix: resolve 06_dataloader external test failures completely
🎯 Issues Fixed:
1. MockTensor Scalar Handling: Fix np.array([data]) → np.array(data) for scalar shape ()
2. Index Bounds Validation: Add negative index check (index < 0) to MockDataset.__getitem__
3. DataLoader Input Validation: Add proper validation for batch_size > 0 and dataset ≠ None

 Impact: 06_dataloader external tests now pass 28/28 (was 19/28)

🔧 Technical Changes:
- MockTensor: Handle scalars correctly to create shape () instead of (1,)
- MockDataset: Validate negative indices to raise IndexError as expected
- DataLoader: Add robust input validation with proper error messages
- All issues were legitimate implementation problems, not test issues

This completes the systematic external test fixing across all 4 modules with failures.
2025-07-13 22:20:54 -04:00
..