TrenTorch: free machine learning practice that runs Python in your browser, with no import torch in sight
- Developer Tools

Most machine learning tutorials end the same way: you import a library, call one function, and a result appears. You learn what to type, not what happens. TrenTorch takes the opposite approach. Its pitch is to learn machine learning by building it: write the code for each step yourself, run it, and see it graded instantly. The site's footer says: "We don't charge users and we don't sell your data. TrenTorch runs entirely on sponsorships and donations." The homepage counted 1,639 practice problems across 74 topics when we visited.
What we actually did
We opened the problem of the day, "The Retrieval MRR Score," a problem tagged Hard on information-retrieval metrics. The page opens straight into an in-browser editor: a story, the math, input and output format, constraints and a worked example on the left, a Python editor with starter code on the right. No install. We wrote a short solution (loop over each query, find the first relevant result, add one over its rank, divide by the number of queries) and pressed Run. The console answered "2/2 sample checks passed."
That is all we tested: one problem, solved on desktop. We did not try the hidden-test Submit button, the discussion tab, any of the research-paper problems, or the GPU programming material. And we did this without an account, which is not how the rest of the site works.
Where the sign-in appears
The problem of the day opened for us signed out. But when we visited signed out, the Modules page, the structured paths of theory and problems, showed "Sign in to open" on the cards we saw: AI Systems (12 modules, 976 questions), GPU Programming (39 chapters, 53 problems), Software Engineering (21 steps, 454 questions). The GitHub README confirms the flow: sign in with GitHub, Google or email, then start a question. On Hacker News, one commenter objected to the sign-in and the sponsor ads shown on it, and another replied that the site runs untrusted code, so an auth layer makes sense. We did not sign in, so we cannot say what the account step collects.
The from-scratch framework
There is a second, separate product in the repository: a command-line curriculum, described in the README as "a from-scratch machine learning framework in NumPy" with 20 framework modules and "0 import torch needed." Its README says every operation traces back to raw NumPy, so that "you know what loss.backward() does because you wrote it." The README adds that the CLI curriculum is its own implementation of TinyTorch, Harvard's CS249r course, "rebuilt and extended in our own style," and that the browser version was built independently. It needs Python 3.11.5 or newer. We did not install the CLI.
The fine print
The repository is public with 925 stars and 86 forks at the time of our visit. The latest commit message on the LICENSE file says the project was relicensed to PolyForm Noncommercial, so treat it as source-available rather than open source: you can read and learn from it, but commercial reuse is a different matter and worth checking in the license itself. The same Hacker News thread also had a commenter doubting that the text read like it was written by a person; we cannot judge that, and the problem we solved was clear and correct.
Who it is for
If you can write Python and want to understand ML by implementing it instead of importing it, the open-in-browser problems are a low-friction way to start, and the fact that a Hard problem opened and graded without an account is a good sign. If you want the guided modules, plan on creating an account.
Cover: real screenshot of TrenTorch (trentorch.com), our solution to "The Retrieval MRR Score" passing its sample checks.





