Short answer: study the calculations before borrowing them
Our source installation step succeeded in 28 seconds, while a separate PyPI attempt stopped after 1.9 seconds with a missing-file error. Use ML-From-Scratch if you want to inspect machine-learning calculations in Python alongside their mathematics. Skip it as an unquestioned production training dependency: the README favors transparency over computational efficiency, and our repository scan recorded no tests directory or CI workflows. The installation results and correctness discussions answer different parts of that decision.
The README describes the project's purpose as presenting algorithm internals transparently and accessibly. That makes one implementation and a small, independently calculated input a useful starting point. A learner can follow the operations that produce a coefficient, prediction or weight update rather than beginning with an entire application. The issue history also supplies concrete calculations to examine, including an author-confirmed AdaBoost correction and a reported linear-regression transpose problem.
What people use ML-From-Scratch for
GitHub participants describe using ML-From-Scratch to reimplement algorithms, learn XGBoost and run classical classifiers. These are named users' accounts of their own work, with different outcomes across examples and environments. They give a more specific picture of the collection's educational uses than a list of algorithm names alone: reading an implementation sometimes leads to a successful example, and sometimes to a question about the calculation or its dependencies.
| Person and task | What happened | What you can take from it |
|---|---|---|
| The opener of issue #55 used the implementations to reimplement ML algorithms. | JonathanBechtel later reported incorrect pseudoinverse results and submitted a correction. | Issue #55 connects source reading with checking a matrix calculation. |
| shorey used the project to learn XGBoost. | They questioned the gain formula's multiplication by the labels. | Issue #68 identifies the split calculation they wanted to understand. |
| goodhamgupta ran polynomial regression in a fresh Python 3 environment. | They posted cross-validation output; edchepen reported success with the same steps on Ubuntu 16.04. | Issue #45 records historical example execution. |
| indrajithi tried classical classifiers. | They reported working logistic regression, KNN, naive Bayes and AdaBoost examples, followed by an SVM error. | Issue #8 distinguishes the working examples from the cvxopt failure. |
The README also documents polynomial regression, CNN classification, DBSCAN clustering and handwritten-digit generation. Its examples connect implementation files with recognizable tasks. For source reading, that organization lets you choose a calculation before following its supporting code. For teaching, the useful distinction is between an author's demonstration and an issue participant's account: the former illustrates the project, while the latter describes an outcome in a particular environment.
What happened when we ran it
Our November 27 PyPI installation attempt failed in 1.9 seconds before an example ran. The November 27 run used commit reference a2806c6732ee and a fresh, unprivileged container with 2 CPUs and 4 GB RAM. It had no published ports or secrets. Its installation command fetched mlfromscratch from PyPI at the latest version rather than installing the checked-out repository source.
The clone step completed in 1 second, and uv pip install mlfromscratch exited 1 after 1.9 seconds. The traceback passed through a package-build setup call and file opening, ending with FileNotFoundError: [Errno 2] No such file or directory:. The recorded hint referred to the package or build environment as possible sources of the failure. The sandbox teardown completed successfully.
| Recorded route | Result | What the result covers |
|---|---|---|
| November 27: PyPI quickstart | Install failed in 1.9 seconds, exit 1 | Package installation stopped before example execution. |
| November 15: source sandbox, a2806c6 | Install succeeded in 28 seconds | The recorded source-install step completed. |
| November 15: build | Succeeded in 1 second | The recorded build step completed. |
| November 15: tests | Skipped: no tests script or target | The harness recorded a skipped test step. |
| November 15: dependencies and footprint | 35 dependencies recorded, 38 MB on disk | Environment inventory. |
| November 15: pip-audit | 0 known vulnerabilities | The recorded dependency-audit result. |
| November 15: repository signals | 0 CI workflows, no Dockerfile, no tests directory | Repository-scan observations. |
In our November 15 run at commit a2806c6, the sandbox configuration specified 3 CPUs, 8 GB RAM and image ghcr.io/astral-sh/uv:python3.12-bookworm. The checkout contained 89 files, approximately 6,954 source lines and 0.3 MB. Installation completed in 28 seconds and the build in 1 second, with 35 dependencies recorded and 38 MB on disk. These figures describe the checkout, installation and build steps that the harness recorded.
Where people get stuck: cvxopt imports can block an unrelated example
Issue #45 reports a polynomial-regression failure while importing cvxopt through the supervised-learning package. The reporter's intended task was regression, but the issue traces the import through support_vector_machine.py to a cvxopt DLL load error. That path is useful when matching a traceback: an SVM-related dependency can appear before the polynomial-regression example reaches its own calculation. Other installation discussions describe separate symptoms and attempted remedies.
| Symptom | What people tried | Outcome in the discussion |
|---|---|---|
| Windows 10 installation failed despite Visual Studio build tools | jaircastruita used a fresh Anaconda installation; fivejjs used Anaconda plus PyCharm | Both reported success; pfbox later requested help with Windows 10 installation. |
| Polynomial regression raised a DLL load error | goodhamgupta used a fresh Python 3 environment and ran the installation steps | They posted output; edchepen reported success on Ubuntu 16.04; the author closed the issue for inactivity. |
| Windows warned that Py_DEBUG was unset | The reporter switched operating systems | Issue #44 records that change of operating system. |
| SVM raised an error that cvxopt had no solvers attribute | An upgrade was discussed; the author suggested commenting out the line hiding solver output | A participant reported the error after upgrading, and the author explained the line's purpose. |
These discussions distinguish a DLL import failure, an ABI-tag warning and an attribute error at cvxopt.solvers.options. They are different points of failure, even though several involve Windows or cvxopt. The reported remedies belong with those symptoms: Anaconda appears in issue #34, a fresh Python 3 environment appears in issue #45, and the output-suppression suggestion appears in issue #8. Keeping those pairings intact makes the issue history usable as a troubleshooting index.
AdaBoost has a confirmed historical fix; linear regression has a reported correction
The author confirmed a sample-weight update fix in AdaBoost issue #17. Contributor whcn observed that the exponent's dot product produced a scalar, leaving all weights equal after the update. The author acknowledged the mistake and reported that replacing the dot product with the Hadamard product fixed the issue. The replacement line in that historical explanation is w *= np.exp(-clf.alpha * y * predictions).
The same discussion explains why that operation matters. The author says misclassified samples should receive higher weights and correctly classified samples lower weights. Applying the same scalar to every sample fails to make that distinction. The report is especially useful for learning because whcn initially noted that classification accuracy looked acceptable while questioning the implementation. A displayed accuracy and a correct update rule are separate things to examine in the code.
In issue #55, JonathanBechtel reported incorrect pseudoinverse results and submitted a pull request. Their explanation concerns the orientation of the matrix returned by NumPy's singular-value decomposition and the transpose used in subsequent calculations. They also preferred showing the explicit calculation for educational purposes over replacing it with np.linalg.pinv(X). That gives the reader a precise study question: follow the matrix operations and compare the result with an independent calculation.
XGBoost here is a simplified example to investigate
A commenter in issue #68 described the XGBoost example as simplified and said it lacked all of the original library's regularization mechanisms. The commenter named min_samples_split, min_impurity and max_depth as available controls. Their account separates tree controls present in the example from the broader regularization question raised by another participant. It is an attributed description of this implementation, rather than a comparison measured in our sandbox.
For regression, chyunsu3 suggested replacing LogisticLoss with squared error and supplied loss, gradient and Hessian methods. Later, shorey asked about the multiplication by labels in the gain numerator in supervised_learning/decision_tree.py. Those are distinct questions within issue #68's XGBoost discussion: one concerns adapting the loss for regression, and the other concerns the calculation used to choose splits. Each points to a particular operation a learner can inspect.
A small checkout is not a production training recommendation
The README prioritizes transparent algorithm internals over computational efficiency, and our scan recorded 0 CI workflows and no tests directory. The checkout's 89 files and approximately 6,954 source lines make its size concrete, but the project's stated purpose is the stronger reason to choose it for source study. The installation and disk-footprint figures describe setup work; a production training decision requires evidence about the workload that will actually run.
The GitHub metadata observed on November 27, 2026 records a last push on October 15, 2023. It records 33,464 stars and 82 open issues and pull requests. These are dated repository facts. The historical discussions provide more specific information for selecting a lesson: issue #17 contains an acknowledged correction, issue #55 discusses a transpose, and issue #68 raises questions about the simplified boosting implementation.
ML-From-Scratch vs micrograd, ML-For-Beginners and Made With ML
Choose micrograd to study backward gradient propagation, ML-For-Beginners for a lesson sequence, and Made With ML for software engineering around ML applications. Their own documentation supports those differences in scope. ML-From-Scratch's distinguishing use here is selecting an algorithm and inspecting its explicit calculations across a broad catalog. The table compares the learning tasks described by each project, so readers can choose the material that answers their next question.
| Project | What its documentation emphasizes | Pick it when |
|---|---|---|
| ML-From-Scratch | Transparent implementations of fundamental ML models and algorithms | You have a topic and want to inspect its calculations. |
| micrograd | Reverse-mode autodiff and a small neural-network library operating over scalar values | You want to follow gradients backward through individual operations. |
| Microsoft ML-For-Beginners | Classic ML lessons with quizzes, instructions, solutions and assignments | You want a sequence that tells you what to learn next. |
| Made With ML | Combining machine learning with software engineering to develop and deploy applications | You want to learn the work surrounding an ML application. |
The documented lesson structure is a practical distinction for a first-time learner. Microsoft's curriculum explicitly includes assignments and quizzes, while micrograd narrows attention to automatic differentiation. Made With ML follows development through deployment and iteration. A learner choosing ML-From-Scratch instead takes responsibility for selecting the implementation and pairing it with mathematical instruction. That choice fits directed study of regression, clustering or boosting better than a request for a prescribed course sequence.
What the other reviews get wrong
Whatisgithub labels setup easy and estimates roughly five minutes to a successful first run. Its setup estimate is a different claim from our timed installation steps: November 15 recorded a successful 28-second source-install step, while November 27 recorded a failed 1.9-second PyPI attempt. A first successful example run includes more than installation. The Windows issue discussions also describe different outcomes for different users and environments.
Search results introduce a separate identity problem. ml-from-scratch-book/code describes itself as a book's companion repository, while mk2427/ml-from-scratch describes an interactive Jupyter notebook course. This review concerns eriklindernoren/ML-From-Scratch. The owner name distinguishes the implementation collection from those other projects, so their exercises, course structure and installation instructions belong with their respective repositories rather than this one.
Questions people ask
The README installs ML-From-Scratch from a cloned repository with python setup.py install, then documents individual example commands. Installation, Windows dependency errors and algorithm calculations recur in the project's issue discussions. The answers below keep the README's commands separate from historical user reports and the author's explanations, including the complete explanation of why AdaBoost concatenates classifier predictions before combining them.
What is eriklindernoren/ML-From-Scratch, and which GitHub repository is the intended project?
Erik Linder-Noren's ML-From-Scratch is a Python collection of fundamental machine-learning implementations at eriklindernoren/ML-From-Scratch. The README prioritizes transparent and accessible internals over computational efficiency. Its catalog includes supervised, unsupervised, reinforcement and deep learning. Including the owner name in a search distinguishes this collection from the similarly named book companion and interactive notebook course discussed above, which have their own teaching structures.
How do I install ML-From-Scratch and run an example successfully?
The README instructs readers to clone the repository, enter ML-From-Scratch and run python setup.py install. Its polynomial-regression example command is python mlfromscratch/examples/polynomial_regression.py. In issue #45, goodhamgupta described starting with a fresh Python 3 virtual environment and posted cross-validation output; edchepen reported success with the same steps on Ubuntu 16.04. These are the documented command and historical example accounts, respectively.
Are there special installation instructions for Windows 10, and does Anaconda help?
A fresh Anaconda installation solved jaircastruita's reported Windows 10 installation problem in issue #34. The reporter had previously tried Visual Studio build tools without success. Another participant reported success with Anaconda plus PyCharm, and pfbox later asked how to resolve the same Windows installation problem. The discussion records the environments and outcomes of those individual participants rather than one shared installation recipe.
How do I resolve the cvxopt DLL load failure when running polynomial regression?
Issue #45 identifies a failure importing cvxopt while starting polynomial regression, and later participants describe successful fresh Python 3 environments. edchepen reported using Ubuntu 16.04 and following goodhamgupta's steps, including the setup.py installation step. The author eventually closed the discussion for inactivity. The useful details for tracing the report are the DLL import error, the supervised-learning import path and the installation steps associated with the later example output.
Why does Windows installation warn that Py_DEBUG is unset, and has that warning been resolved?
The warning in issue #44 says Py_DEBUG is unset and the Python ABI tag may be incorrect. The reporter said installation completed but emitted the warning repeatedly. When another participant asked whether it was solved, the reporter said they had switched operating systems. That sequence distinguishes this discussion from the DLL import failure in issue #45 and the Anaconda workaround reported in issue #34.
Why does the SVM example report that cvxopt has no solvers attribute even after installation?
Issue #8 records the attribute error at cvxopt.solvers.options, the line used to suppress solver progress output. A participant reported having upgraded cvxopt and still encountering the error. The author suggested commenting out that line and explained that it only hides cvxopt output. That identifies both the failing expression and the purpose of the proposed edit, rather than treating every cvxopt problem as the same installation failure.
Which cvxopt version should I use?
Issue #8 discusses upgrading cvxopt rather than naming an exact version to install. The participant asking about versions reported that they had upgraded to the latest version, and the author's subsequent suggestion concerned the output-suppression line. The version discussion and proposed edit appear together in issue #8. For an environment record, keep the actual installed version beside the particular example and its observed outcome.
Why do the AdaBoost classifiers appear identical, and are the sample weights being updated correctly?
The author acknowledged an incorrect weight update and confirmed a historical fix in issue #17. The exponent used a dot product where elementwise multiplication was intended. The author explained that the old update failed to give misclassified samples higher weights and correctly classified samples lower weights. The replacement line was w *= np.exp(-clf.alpha * y * predictions), and the author said the latest commit resolved the issue.
Why does the AdaBoost predict function concatenate y_pred?
The author explains that concatenation puts each classifier's predictions in a separate column. In the complete issue #17 explanation, those columns receive the corresponding classifier's alpha weight, are summed, and determine classification by the sign of the sum. The explanation connects the array layout with the voting calculation: each column represents one classifier, while its alpha controls that classifier's contribution to the final prediction.
Does comparing a random number with the mutation rate produce the intended mutation probability?
The author describes mutation rate as a probability implemented by comparing a random value with the rate parameter in issue #49. Their demonstration counted 59,966 successful comparisons in 100,000 draws at a rate of 0.6. That demonstration addresses the participant's objection about how often the comparison succeeds. The 59,966 result belongs to the author's example in the discussion, rather than to our installation runs.
Can I adapt the XGBoost classifier implementation for regression?
chyunsu3 proposed replacing LogisticLoss with squared error and supplied loss, gradient and Hessian methods in issue #68. The regression proposal appears in the XGBoost discussion alongside questions about regularization and split gain. It identifies a particular implementation change for a learner to examine: the objective and its derivatives. That is more specific than assuming classification and regression can share the existing loss unchanged.
Does the XGBoost example implement the original algorithm's regularization?
chyunsu3 described the example as simplified and said it lacked all of the original library's regularization mechanisms. The commenter listed min_samples_split, min_impurity and max_depth when discussing the controls available in the example. That distinction helps interpret the shared XGBoost name: the discussion concerns this educational implementation and its particular tree controls, while another participant asks about the complexity penalty used in the original algorithm.
What we have not tested yet
Our runs cover a recorded source-install step, a build and a failed PyPI installation attempt; they contain no independently checked model predictions. Accuracy, large-data performance, training memory, GPU use and production reliability are outside those measurements. The image labels do not identify the actual runtime versions, and the November 15 installation command is unavailable. The runs used different installation routes and sandbox configurations; these records do not establish why their outcomes differed.
The captured PyPI error omits the missing filename, so it cannot identify the file or establish the cause of the installation failure. The dependency audit recorded 0 known vulnerabilities; that result is neither a numerical-correctness check nor a general security assurance. The repository scan describes the files its detectors found. The timed steps also provide no measurement of a first successful example run, including the five-minute estimate made by Whatisgithub.
We did not reproduce current AdaBoost concatenation behavior, the historical weight-update repair, the pseudoinverse correction, the XGBoost adaptation or the Windows and SVM workarounds. Issue #55 records a submitted correction without confirming its merge; issue #68 leaves the gain question unresolved. Issues #44, #45 and #8 provide no demonstrated general repair for their respective warning, original Windows DLL failure and SVM error, and issue #8 provides no reliable exact cvxopt pin.
The preprocessing request in issue #42 and print-syntax discussion in issue #11 also contain no demonstrated repair. Empty YouTube extracts and unrelated Scratch-programming results contribute no project-specific usage account, and the research contains no Reddit or X account to weigh. Rendered layout, resolved evidence links, related links, recommendation modules and template content were outside this text review. A useful next step is one chosen example with recorded dependencies and an independently calculated expected answer.


