Skip to content

20250811 jetson nano pytorch 1.10#628

Open
mcgrof wants to merge 3 commits intokarpathy:masterfrom
mcgrof:20250811-jetson-nano-pytorch-1.10
Open

20250811 jetson nano pytorch 1.10#628
mcgrof wants to merge 3 commits intokarpathy:masterfrom
mcgrof:20250811-jetson-nano-pytorch-1.10

Conversation

@mcgrof
Copy link

@mcgrof mcgrof commented Aug 12, 2025

With enthusiasm I got myself a Jetson Nano to try this repo out, only to my surprise I couldn't do anything with it as it was stuck on Pytorch 1.10 and the support for the device had EOL'd. So I decided it may be good to see if I could get it to work with the minimum amount of changes so the core code. This is what I've come up with. Granted the MFU is about mfu 0.02% ... my CPU gets better results (MFU 0.05%). However instead of leaving these EOL'd GPUs with no life to breathe -- this at least should help others experiment with a real small GPU.

mcgrof added 3 commits August 11, 2025 00:08
…lcontext

Some embedded GPUs like the NVIDIA Jetson nano are end of life already,
and its version of pytorch is stuck on really old versions, 1.10.0,
so there is no torch.amp.autocast() and contextlib nullcontext.

Add a simple library helpers which mask out the ugliness from the main code,
so to enable folks with these devices to keep tinkering with them.

Signed-off-by: Luis Chamberlain <[email protected]>
Add simple wrappers for DDP to make it easy to make the code easily
adaptable to run on old version fo pytorch, such as 1.10 where
DDP did not exist. Examples of devices stuck on this are the
NVIDIA Jetson nanos.

Signed-off-by: Luis Chamberlain <[email protected]>
The last library helper we need to provide a wrapper for to enable
NVIDIA Jetson Nano devices stuck on Pytorch 1.10 is for tiktoken.
We can *try* to compile it but it just fail, even on older releases,
and so let's just provide a helper which leverages the original
gpt2 encoder.py and its respective encoder.json and vocab.bpe.

To run on a Jetson nano, you can use the same exact instructions
as used for the mackbook on the README.md, just use --device=cuda

Signed-off-by: Luis Chamberlain <[email protected]>
gkielian added a commit to klei22/nanoGPT that referenced this pull request Oct 3, 2025
…istics-features

Add enhanced l2 norm statistics features
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant