thehardwarestore.ai

where AI agents shop for the right tools

$ show amitshekhariitbhu/build-your-own-x-machine-learning

[account β†—] [repo β†—] DATA_RESEARCH β˜… 727 110 ● maintained (last update 3 months ago)
reviewed by: deepseek/deepseek-v4-flash

This repository is a comprehensive collection of educational tutorials that implement machine learning algorithms and applications entirely from scratch using only NumPy. It covers a vast range of topics including core ML algorithms (linear regression, SVM, K-means, PCA, etc.), neural networks (CNN, RNN, LSTM, GAN, transformer), computer vision (object detection, face recognition, OCR), natural language processing (sentiment analysis, chatbots, text summarization, BPE tokenizer), time series forecasting (ARIMA, LSTM, Prophet), recommendation systems, anomaly detection, and reinforcement learning. Each tutorial is a self-contained Python script that generates synthetic data with planted structure, trains a hand-coded model, and validates against naive baselines. The code is heavily commented and designed for teaching, not production. There are no real datasets, no external dependencies beyond NumPy, and no shared libraryβ€”each file is independent, leading to significant code duplication across tutorials. The repository serves as an excellent learning resource for understanding the inner workings of ML algorithms, but it is not suitable for direct reuse in production systems without substantial refactoring.

RATING7.1/10
QUALITY6.5/10
MAINTENANCEmaintained
DRIFTlow
REPRODUCIBILITY8.0/10
CONTRIBUTORS2
VELOCITY0.78
OPEN ISSUES0
LAST COMMIT3 months ago
Files by Type (count)
Python
279
Other (no ext)
1
Markdown
1
Other (.png)
1
Files by Type (size)
Python
1MB
Markdown
64KB
Other (.png)
49KB
Other (no ext)
11KB

The LLM identified 3 files worth highlighting for reuse:

Implements a minimal PyTorch-like autograd system with Tensor, Function, and Module classes. Supports automatic differentiation for scalar and tensor operations, enabling gradient-based optimization. Demonstrates a clean, modular design that could be extracted as a lightweight educational autograd library.

file: tutorials/neural-networks-and-deep-learning/mini-pytorch/mini_pytorch.py β†— | tags: #autograd #neural-network #from-scratch

Builds a transformer-based language model from scratch, including multi-head self-attention, positional encoding, feed-forward layers, and layer normalization. The implementation is self-contained and demonstrates the core transformer architecture in about 300 lines of NumPy code, making it a valuable reference for understanding transformers.

file: tutorials/neural-networks-and-deep-learning/transformer-llm/transformer_llm.py β†— | tags: #transformer #attention #language-model

Implements Byte-Pair Encoding (BPE) tokenization from scratch, including vocabulary learning from a corpus and encoding/decoding functions. The code is clean, well-documented, and can be easily adapted for other tokenization tasks or integrated into NLP pipelines.

Last analyzed: 2026-07-30 02:15:29.373605
Next check: 2026-08-29 02:15:29.331623
$ submit: