nowfound

AI · April 21, 2025

Keep your PyTorch model in VRAM by hot swapping code

Pytorch script hot swap: Change code without unloading your LLM from VRAM - valine/training-hot-swap

Keep your PyTorch model in VRAM by hot swapping code launched on April 21, 2025 with 77 votes, #553 of 7,818 launches that month and more than 95% of that year's launches. The site was still online in September 2026, 1 year on.

Visit github.com ↗Alternativestop 7% of April 2025

In plain words

This tool helps developers manage PyTorch model memory by automatically swapping code in and out of VRAM during execution. It's designed for machine learning engineers working with large models who need to optimize GPU memory usage without manually managing model loading and unloading. The software enables keeping models active while reducing memory overhead through intelligent code hot-swapping techniques.

written from the facts on this page · September 2026

From the sources

This is an example of how to hotswap PyTorch training code without unloading your model weights from VRAM. For large LLMs it can take upwards of 30 seconds to load a model from disk to VRAM. Waiting 30 seconds every time you want to rerun your script slows down development. This is a barebones implementation of a method to keep large models in VRAM even after your training script exits. If a model reload is necessary, it happens in the background after exit ensuring the model will be ready immediately the next time your script is run. This works by spawning a second process that stays active after your target script exits. The script you change is not run directly. Instead, this background…from github.com

Does a similar job

all alternatives →
  • Magicam2025 · magicam.ai · ▲306

    Real time face swapping for any stream or meeting

  • PMBJun 2026 · pmbai.dev · ▲211

    PMB gives Claude Code, Cursor, Codex and Zed a real memory. Decisions, lessons and facts in one SQLite file on your disk. Offline, no API keys, no cloud.

  • LeanRL: Fast PyTorch RL with Torch.compile and CUDA Graphs2024 · github.com · ▲53

    We're excited to announce that we've open-sourced LeanRL, a lightweight PyTorch reinforcement learning library that provides recipes for fast RL training using torch.compile and CUDA graphs. By leveraging these tools, we've achieved significant speed-ups compared to the original CleanRL implementations - up to 6x faster! Reinforcement learning is notoriously CPU-bound due to the high frequency of small CPU operations. PyTorch's powerful compiler can help alleviate these issues, but comes with its own costs. LeanRL addresses this challenge by providing simple recipes to accelerate your…

  • Forge AgentJan 2026 · rightnowai.co · ▲113

    Swarm Agents That Turn Slow PyTorch Into Fast GPU Kernels

  • IM
  • Rgpu – a PyTorch device whose tensors live on a remote GPU15d ago · github.com · ▲57

    Keep Python on your laptop. Run PyTorch operations and hold tensors on a remote GPU, including from a Mac with no CUDA installation. - ymcrcat/rgpu

More ai this month

the category →
  • Video model that turns script into viral social media videos

    AI · 17d ago · spira.ai

  • The browser where Claude Code and Codex work beside you

    AI · 17d ago · rill.love

  • Kolibri is Aleph Alpha

    AI · 19d ago · tej.as

  • Paintings by AI models: programs run through a simulation of oil paint.

    AI · 20d ago · stillwet.art

  • A real-time world model you can explore and change

    AI · 29d ago · world.pixverse.video

  • Hemory▲381

    Keep listening. Searchable memory for your AI agents.

    AI · 30d ago · hemory.com

Source: Show HN post ↗

Launched alongside, April 2025

the whole month →
  • Hi everyone, I built PyXL — a hardware processor that executes a custom assembly generated from Python programs, without using a traditional interpreter or virtual machine. It compiles Python -> CPython Bytecode -> Instruction set designed for direct hardware execution. I’m sharing an early benchmark: a GPIO test where PyXL achieves a 480ns round-trip toggle — compared to 14-25 micro seconds on a MicroPython Pyboard - even though PyXL runs at a lower clock (100MHz vs. 168MHz). The design is stack-based, fully pipelined, and preserves Python's dynamic typing without static type restrictions.…

    Dev tools · 2025 · runpyxl.com

  • The Unsure Calculator is an online tool that lets you calculate with numbers you’re not sure about.

    Life & fun · 2025 · filiph.github.io

  • https://the-pocket.github.io/Tutorial-Codebase-Knowledge/

    AI · 2025 · github.com

  • Whatting▲898

    The iPad diary, just for you

    Work · 2025 · whatting.com

  • Browser with AI companions that automate web tasks

    AI · 2025 · strawberrybrowser.com

  • Peek▲828

    AI personal finance coach that guides you through decisions

    Work · 2025 · peek.money