comments (10)

  • Thanks for this! I've been trying to get local training working on Fedora with ROCm for a while now, and this is the first project that ran end-to-end on my RX 7600 XT 16GB.

    The whole reason for me buying the card was to play around with deep learning and models, so it's awesome to have a stepping off point now!

    No CUDA meant ROCm surprisingly just worked with JAX.

    Gotchas for anyone with a 7600 XT: it needed two env vars, HSA_OVERRIDE_GFX_VERSION=11.0.0 because JAX's plugin rejects gfx1102, and XLA_FLAGS=--xla_gpu_enable_triton_gemm=false to stop a GPU hang.

    I'm on Fedora 45 with the in-kernel amdgpu driver, rootless podman and AMD's rocm/jax image (ROCm 10.1, JAX 0.11.1). Nothing ROCm is installed on the host, which is nice.

    Container setup is in a PR if it helps anyone: https://github.com/Vaibhaav-Tiwari/deepseek-v3-jax/pull/1

    joebarbere

  • I love this, there is nothing like recreating a model from first principles, plus makes me want to revisit Jax again (I'll do it after I spend enough time with Zig). Thanks for this!

    armcat

  • Post like these always drives a motivation to understand how inference or what OP did.

    For folks who are more familiar in this space, is there a good road map how to build and understand the intuition behind this? I’m comfortable in Java and Python and do vanilla SWE work.

    mattfrommars

  • > to asking a language model to create a 3D end-to-end working model for me to capture the nuances

    Love this! Yes, having a visual of the system makes it a lot easier to reason about and understand

    I wish all AI models came with interactive animated workflows of their architecture

    > so I wanted it to be different just for the sake of it and used various books by…

    That’s cool and great for your own project. At the same time it helps to use datasets that others have used, because then you can compare results more directly

    Excellent write up, I really appreciate all the detail and the sample outputs at the end. Excited to see what I could apply for this to the small <10M models I’ve been training

    nico

  • I am just starting Raschka's book to write an llm from scratch in C++ with zero dependencies with avx-512 on a 9950x, and then I'd like to go through the literature for more advanced stuff.

    I don't know what Jax is exactly but while I am aware that the algorithm implementation is not something terribly complicated, 200 lines still sounds impressive.

    If anyone wants to share any tips, they're welcome.

    d_tr

  • Could you build and train a V4.1 the same way?

    try-working

  • fun nugget: if you grab our (zml) PJRT Metal plugin and point JAX to it, it should just work

    steeve

  • thank you so so much for writing this, I will recreate it for learning

    itsthecourier

  • Does this work on CPU only hardware (Intel Core Ultra 7)?

    madduci

  • anyone got a c++ version of this?

    vivzkestrel