Auto RIFE TensorRT
The node that puts your missing frames back — at TensorRT speed
- frames
- rife_trt_model
- IMAGE
Video models hand you chunky, low-fps clips. Wan ships at 16fps, LTX at 24, and neither looks like real motion - fast stuff stutters, and slow-motion is just off the table. AutoRifeTensorrt is the node that fixes that: it takes your frame sequence and synthesizes the in-between frames so your 16fps output becomes buttery 48 or 64fps. Feed it a 2x multiplier and a 24fps clip comes out at 48fps. Feed it 4x and you get slow motion that actually looks smooth.
It's the compute half of the ComfyUI-RIFE-TensorRT-Auto pack. The loader node builds and loads the TensorRT engine; this node runs it over every adjacent frame pair.
How it actually works
RIFE stands for Real-time Intermediate Flow Estimation (ECCV 2022, from the hzwer repo). Instead of guessing a new frame from scratch, it estimates the optical flow between frame A and frame B, then uses that motion field to warp and synthesize the middle frame. "Where did the pixels move?" - that's the whole trick, and it's why RIFE is both fast and temporally stable compared to generating frames independently.
Under the hood, AutoRifeTensorrt feeds each frame pair into the TensorRT engine along with a timestep - 0.5 for 2x, 0.25/0.75 for 4x - and splices the engine's outputs back into a longer sequence. A few things worth knowing:
- Frames bigger than your engine profile don't crash. The node auto-tiles them with a feathered 128px overlap. That's a life-saver, but tiling is slower and disables CUDA graphs, so pick a loader profile that covers your resolution instead of relying on it.
- CUDA graphs are only enabled on CUDA 13. The code auto-detects your CUDA version and disables graphs on CUDA 12 or in cloud containers for stability. It's a silent optimization, not something you configure.
- The engine runs on the GPU via a CUDA stream, and output always comes back as float32 CPU tensors, so it plays nice with every downstream video node.
The inputs that matter
- frames - your
IMAGEtensor (a batch of frames). Drop in whatever a video loader or video model outputs. - rife_trt_model - the
RIFE_TRT_MODELoutput from AutoLoadRifeTensorrtModel. Wire it up once and forget it. - multiplier - default 2. 2 doubles the frame count, 4 quadruples. This is the knob you'll actually touch.
- clear_cache_after_n_frames - default 100. It empties CUDA cache every N frames so long clips don't balloon VRAM. Lower it (say 20–30) if a long run OOMs.
- keep_model_loaded - default off. Leave it off unless you're looping the node; keeping the engine resident saves reload time at the cost of permanent VRAM.
The single output is IMAGE: your longer frame sequence. Wire it into VHS_VideoCombine or a SaveVideo node to write it out.
Installing it
Via ComfyUI Manager, search ComfyUI-RIFE-TensorRT-Auto, or:
cd ComfyUI/custom_nodes
git clone https://github.com/huchukato/ComfyUI-RIFE-TensorRT-Auto.git
Restart ComfyUI. On first load the pack auto-installs its base deps plus the TensorRT wheels that match your CUDA version - cu12 for RTX 30/40 series, cu13 for RTX 50 series. The catch: you need the NVIDIA CUDA Toolkit installed already (nvcc on your PATH, or CUDA_PATH/CUDA_HOME set). The pack doesn't install that for you.
Where people get burned
- "CUDA initialization failure: 35" - the classic. Usually a driver/CUDA mismatch. Check
nvidia-smiandnvcc --version, then restart. A system restart fixes a surprisingly large share of these. - Your first run takes minutes and pegs VRAM - that's the engine build, which actually happens in the loader node. Not a hang. It's cached afterwards.
- OOM on long clips - lower
clear_cache_after_n_framesor use a smaller resolution profile on the loader. - Frames come out but it's slow - your resolution is outside the engine profile and you're silently tiling. Resize first or pick a bigger profile.
One honest take: the community's verdict on RIFE-TRT is "fast and good enough most of the time" - if you need flawless interpolation (bad flicker, heavy detail), GIMM-VFI is the quality pick, at much higher cost. RIFE-TRT wins when you need speed. Also note the pack is CC BY-NC-SA licensed - fine for personal use, not for a paid product.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| frames | IMAGE | Input frames for video frame interpolation | |
| rife_trt_model | RIFE_TRT_MODEL | Tensorrt model built and loaded | |
| clear_cache_after_n_frames | INT | 1001–1000 | Clear CUDA cache after processing this many frames |
| multiplier | INT | 2 | Frame interpolation multiplier |
| use_cuda_graph | BOOLEAN | true | Use CUDA graph for better performance |
| keep_model_loaded | BOOLEAN | false | Keep model loaded in memory after processing |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |