Generating Character Sprites with H3Anim and MiniMax H3 on EVO-X2 ROCm
Contents

I wanted to see if MiniMax H3 video generation could run on a 64GB GMKtec EVO-X2, and if so, whether I could turn my character Kana into sprite animations using the ComfyUI custom node H3Anim.
Given a single character image, H3Anim generates a short walking or idle video, removes the background, aligns the frames, and exports a game-ready sprite sheet (a single image with animation frames arranged in a grid) in one node.
Target and Environment
The node is named H3Anim One-Node Studio, and the commit I pulled was 9189234e71c130a20008faebfc2664d47664b308 (November 29, 2026). The bundled presets.json included 51 animation presets, 6 art styles, and 4 background options.
According to the README, the node requires no extra Python packages and relies solely on ComfyUI’s built-in nodes and existing dependencies.
From reading the source, it internally calls built-in nodes such as UNETLoader, CLIPLoader, MiniMaxH3ReferenceToVideo, and BlockSparseAttention, and I found no external network calls or subprocess launches in h3_one_node.py or matting.py.
At the time of the commit I pulled, the README only stated “free” with no license file included, though checking the GitHub repository info on November 30, 2026 showed it listed as Apache License 2.0.
| Item | Details |
|---|---|
| Machine | GMKtec EVO-X2 (Ryzen AI Max+ 395, Radeon 8060S, 64GB unified memory shared between CPU and GPU) |
| GPU Memory Limit | 56GiB (approx. 60GB, raised via ttm.pages_limit) |
| OS | Linux (Kernel 7.0.0-44-generic) |
| ComfyUI | 0.46.0, comfy-kitchen 0.2.42, comfy-aimdo 0.6.0 |
| PyTorch | 2.12.0a0+rocm7.13.0a20260411 (ROCm 7.13) |
I left my daily ComfyUI setup untouched and launched the same installation on a separate port.
I pointed the custom nodes, input, and output directories to a working folder and loaded H3Anim via custom_nodes in extra_model_paths.yaml. I launched it as an isolated unit with systemd-run --user so an out-of-memory kill on ComfyUI would not take down my terminal session.
After cloning into custom_nodes and starting up, the node registered without errors. ComfyUI 0.46.0 already includes MiniMaxH3ReferenceToVideo, MiniMaxH3ImageToVideo, and BlockSparseAttention, so everything the node needed was already present.
Models
I downloaded the MiniMax H3 video files from Comfy-Org/MiniMax-H3.
| Role | File | Size |
|---|---|---|
| Diffusion model (image-to-video) | minimax_h3_ref2va_pruned_int8_convrot.safetensors | 20.97GB |
| Text encoder | qwen3vl_32b_minimax_h3_int8_convrot.safetensors | 27.14GB |
| Video VAE (compresses and decodes video frames) | minimax_h3_video_vae_fp16.safetensors | 5.21GB |
| 4-step LoRA (lightweight adapter weights) | minimax_h3_ref2v_turbo_4step_v0.1_comfyui_bf16.safetensors | 1.96GB |
The text encoder reads the prompt text and reference image and converts them into conditioning inputs for the diffusion model; for MiniMax H3, it is 27GB, larger than the diffusion model itself.
The model page states that if cu130 PyTorch is available, int8_convrot should be preferred for the diffusion model, falling back to fp8_scaled only when int8_convrot cannot be used.
Although this machine runs ROCm rather than CUDA, ComfyUI’s startup log listed INT8 ConvRot operations under “Native ops”, so I went with int8_convrot.
Reference Image
I generated the reference image using Anima-Base v1.0 and Kana’s character LoRA (kanachan-animabase-v2_epoch150, weight 1.0) at 30 steps, CFG 4.5, shift 3, er_sde / simple, and 832×1248 resolution, which took 72–81 seconds per image.
The prompt used the same hairstyle (side ponytail, blue scrunchie, ahoge) and outfit (white shirt, red necktie, dark navy skirt, black tights) from the T2I condition in Reproducing Blender Poses with Anima i2i, changing only the pose to standing, arms at sides, full body, facing viewer. I picked seed 424246 out of three generated seeds.
Testing with Minimal Settings
First, I tested whether the node could complete end-to-end at a small 512×768, 22-frame, 4-step setting.
I enabled the 4-step LoRA and set the animation to “Interact - Wave / Greet”, the style to “2D Anime / VN Cel-Shaded”, the background to “Green Screen (#00FF00)”, and sparse attention (which restricts attention calculation to reduce load) to the node’s default sla.
| Run | Changes | Progress | Result |
|---|---|---|---|
| 1 | Default ComfyUI launch options | Loaded VAE (4,966MB) and text encoder (25,884MB) onto GPU; text encoding passed. Loading diffusion model | CUDA out of memory, followed by the Linux kernel OOM killer terminating ComfyUI |
| 2 | Added --disable-smart-memory --reserve-vram 16 | Text encoder stayed loaded; only 9,071MB of the diffusion model fit on GPU with 10,926MB left outside. Sampling started | 58GB RAM and 4GB swap used; stuck at 0/4 steps for ~13 minutes before manual stop |
| 3 | Reverted launch options to default; patched 1 spot in the node | Entire 19,996MB diffusion model fit on GPU; completed 4 sampling steps, VAE decode, background removal, and sprite sheet export | Succeeded in 235.7s from queue to finish (including initial model load). 6.2s per step |
In runs 1 and 2, ComfyUI tried to load the diffusion model while the text encoder was still occupying GPU memory. Even under ROCm, PyTorch reports memory exhaustion as CUDA out of memory, and because 64GB is shared between CPU and GPU, the 5GB VAE, 26GB text encoder, and 21GB diffusion model could not stay resident at the same time.
For run 3, since the text encoder is no longer needed once conditioning finishes, I added logic to unload it immediately after encoding the reference image and prompt. Because the node caches the text encoder in _MODEL_CACHE, I inserted the following 7 lines right before RandomNoise is called in h3_one_node.py to drop it and call comfy.model_management.unload_all_models():
import gc
import comfy.model_management as _mm
_MODEL_CACHE.pop("clip", None)
del clip
_mm.unload_all_models()
gc.collect()
_mm.soft_empty_cache()
Run 3 produced 22 frames at 512×768 and one 1640×3860 sprite sheet (5 columns, 22 cells, transparent background). Below are the top two rows of the sprite sheet composited over a dark background.
Her side ponytail, blue scrunchie, ahoge, white shirt, red necktie, dark navy skirt, and black tights stayed intact across all 22 frames.
While the background became transparent, some green fringe remained between her side ponytail and body and along the edge of her skirt under the node’s default matting settings (bg_mode set to auto_border, no background removal model).
Memory Usage During Text Encoder Loading
Although run 3 succeeded, peak memory usage logged at 10-second intervals hit 58,704MB, nearly exhausting the 64GB total.
| Phase (Run 3) | Total Memory Used | GPU Portion |
|---|---|---|
| Start | 3,266MB | 270MB |
| Loading text encoder | 57,477MB | 30,378MB |
| Right after loading | 35,459MB | 31,504MB |
| Sampling diffusion model | 51,353–52,699MB | 21,154–26,049MB |
While transferring the 26GB text encoder to the GPU, total memory usage spiked to around 57GB, likely because both the CPU-loaded copy and the GPU-transferred copy existed simultaneously during transfer, though this is just an inference.
Scaling Up to 768×768 and 56 Frames
Next, I generated at the node’s default 768×768 resolution for 2 seconds. Because the node rounds frame counts to 17n + 5, this came out to 56 frames; all other settings matched the minimal test. Note that while H3Anim exports the sprite sheet and individual frames itself, runs 1 through 8 also had a SaveVideo node attached after H3Anim.
| Run | Changes | Time | Peak Memory | Result |
|---|---|---|---|---|
| 4 | Changed only resolution and frame count from run 3 (sparse attention sla) | 323.1s (25.25s/step) | 60,530MB | ComfyUI reported success, but all 56 frames were solid black. Logs showed RuntimeWarning: invalid value encountered in cast, indicating NaN output |
| 5 | Changed sparse attention to none; kept same ComfyUI process from run 3 | N/A | 60,776MB | Kernel OOM killer terminated ComfyUI while loading the text encoder |
| 6 | Restarted ComfyUI; switched text encoder to qwen3vl_32b_minimax_h3_nvfp4_awq.safetensors (15.69GB); sparse attention none | N/A | Steady ~27GB | Text encoder loaded, but text encoding did not finish after 43 minutes; stopped manually |
| 7 | Reverted to 512×768, 22 frames, and INT8 text encoder; added --disable-pinned-memory | 216.4s | 59,217MB | Succeeded; peak memory was unchanged from run 3 |
| 8 | Removed run 7 option, restarted ComfyUI; 768×768, 56 frames, sparse attention none (with SaveVideo) | N/A | 59,409MB | Hung after loading the text encoder at ~35GB memory; auto-stopped at 60-minute timeout |
| 9 | Same as run 8, except SaveVideo node removed | 342.3s (25.17s/step) | 58,624MB | Succeeded; all 56 frames rendered properly |
Run 5 was the third job queued on the same ComfyUI process; starting memory was already 14.7GB (compared to 3.3GB on a fresh start in run 3), so the text encoder loading spike pushed it over the limit. From this point on, I restarted ComfyUI between every generation.
In run 6, I switched to the lighter 4-bit nvfp4_awq text encoder to lower that loading spike. The model page notes that this NVFP4 text encoder does not require Blackwell GPUs, and ComfyUI’s startup log placed NVFP4 under “emulated ops” on this machine.
At run 6, I suspected emulated ops were simply slow, while run 7 with --disable-pinned-memory did not reduce peak memory, and run 8 hung in the exact same way using the INT8 encoder, disproving that guess. Both hung runs had SaveVideo attached, yet run 4 completed with it, and removing SaveVideo in run 9 finished without hanging.
At 768×768 and 56 frames, sla sparse attention produced all-black frames in run 4 while none worked in run 9.
Since I only ran each once, I cannot separate this from run-to-run variance, and step times were nearly identical (25.25s for sla vs. 25.17s for none).
Because ComfyUI’s BlockSparseAttention falls back to standard attention when the token count is below min_tokens (set to 12288 by the node), sparse attention may not have activated at 512×768 (22 frames) and only kicked in at 768×768 (56 frames).
The video below is the output from run 9, showing Kana waving and returning to her standing pose.
Generating Walk and Idle Animations
Using run 9’s settings (768×768, 56 frames, 4 steps, sparse attention none, no SaveVideo node), I generated walk and idle animations. The reference remained the single front-facing image, restarting ComfyUI for each run.
| Preset | Time | Peak Memory | Output |
|---|---|---|---|
| Walk - Forward (S, front) | 368.1s | 59,107MB | Steps forward alternating legs while facing front; shadow appears at feet |
| Walk - Right (E, right-facing) | 346.3s | 59,111MB | Walked sideways, but her side ponytail turned into a high ponytail at the back of her head |
| Idle - Forward (S, front, seed 123456) | 339.5s | 59,065MB | Supposed to stand still, but shifts feet and keeps eyes closed for long stretches |
All three rendered 56 frames without crashing or hanging, though the right walk altered her hairstyle and the idle animation shuffled her feet and kept her eyes closed too long.
Compositing the node’s transparent RGBA frames (frames_rgba) over a dark background at 12fps gives the video below.
Because the node crops to the character’s bounding box, the front walk became 260×784, with some green fringe left along the hair edges and the foot shadow.
Adding Side-View Reference Images
Because the reference was only a front view, MiniMax H3 had no profile information and appeared to invent the side-view hairstyle on its own, changing it during the right-facing walk.
Keeping the same generation settings as the front reference, I changed only the pose prompt to side views (from side, profile, facing right and facing left) and generated three seeds each for right- and left-facing full-body shots. Placing them alongside the front image looks like this:
From left to right: left-facing (seed 524312), front (seed 424246), and right-facing (seed 524302). I used the two side-view images as references for their respective walking directions.
| Preset | Reference Image | Time | Output |
|---|---|---|---|
| Walk - Right (E) | Right-facing full body | 343.4s | Hair silhouette, ahoge, and profile matched the reference image |
| Walk - Left (W) | Left-facing full body | 328.1s | Scrunchie, side ponytail, and ahoge remained intact |
Supplying a matching reference image for each direction kept the side ponytail, scrunchie, and ahoge consistent with the reference. As with the front walk, the cutout videos still retain slight green edges around the hair and feet.
Retrying the Idle Animation
To stop the idle animation from shuffling her feet and keeping her eyes closed for too long, I decided to rewrite the preset prompt. The built-in preset specifies phrases like shifting weight slowly, blinking naturally, and letting hands and clothes settle.
When text is entered into the node’s prompt setting, it overrides the preset text. I replaced those three parts with English instructions stating that feet, legs, knees, and hips must not move, limiting motion to subtle chest and shoulder breathing, hair tips swaying, and a single brief blink.
| Run | Changes | Time | Result |
|---|---|---|---|
| A | Replaced prompt; kept original seed 123456 | 339.4s | Foot shuffling and long eye closures persisted almost identically |
| B | Added to A: switched mode from Reference to Video to Image to Video (FL2VA) (fixing first and last frames to the same image) and changed reference from 832×1248 to 768×768 | N/A | Hung twice in a row right after loading the text encoder |
| C | Added to B: set MIOPEN_FIND_MODE=FAST to skip ROCm convolution search | 335.6s | Completed, but all 56 frames were solid black |
| D | Reverted mode to Reference to Video, kept MIOPEN_FIND_MODE=FAST, and changed seed to 777 | 352.3s | Rendered properly; foot movement shrank and eye closure became one brief blink |
Below are the output from run D and its cutout version.
Since the only difference between A and D was the seed, the seed seemed to govern the motion more than the prompt. However, I only tested two seeds, and D also had MIOPEN_FIND_MODE=FAST set, so the conditions are not identical.
Because D rendered with the same environment variable active, the all-black output in C appears to stem from Image to Video (FL2VA). Judging by their filenames, both the diffusion model and the LoRA are meant for reference-to-video, so this combination may not be supported for first-last-frame-to-video.
Pinpointing Where the Process Hung
The hang in run B matched what happened in runs 6 and 8. This time, I had added a hook in the node’s __init__.py to dump Python’s stack trace on signal:
import faulthandler as _fh, signal as _sig
_fh.register(_sig.SIGUSR1, all_threads=True)
Sending kill -USR1 twice, 8 seconds apart, to the hung process printed the exact same location both times: the 3D convolution (Conv3d) in Qwen35VisionPatchEmbed inside ComfyUI’s comfy/text_encoders/qwen35.py. Because the text encoder is a multimodal model that also reads images, this is the very first step where it splits the reference image into small patches.
During the hang, GPU utilization sat at 100% and process CPU usage at 200%. It had not crashed or deadlocked on I/O; a single convolution calculation was simply not finishing.
MIOpen, the ROCm library that executes convolutions, searches for the fastest algorithm whenever it encounters a new convolution shape. According to the MIOpen documentation, setting MIOPEN_FIND_MODE=FAST makes it skip the search and pick an immediate fallback if the shape is missing from the database, trading some potential GPU performance for faster startup.
With this environment variable passed via systemd-run --setenv, neither C nor D hung. Run B had changed the reference image from 832×1248 to 768×768, feeding a new input shape to the convolution, which fits the explanation that it was stuck searching for an algorithm.
That said, I only tested this twice, and run 8 hung with the same reference image that succeeded in run 4. Step times were 25.17s in run 9 (without FAST) and 29.57s in run C (with FAST), though C also used a different generation mode, so the slowdown cannot be attributed solely to FAST.
Settings That Worked on EVO-X2
Generating one 768×768, 56-frame video took 330–370 seconds including model loading, with peak memory hovering around 59GB—barely under the 64GB ceiling.
| Item | Working Setting | What Happened Otherwise |
|---|---|---|
| Node patch | Unload text encoder right after conditioning | OOM crash (Runs 1, 2) |
| ComfyUI process | Restart for every generation | OOM on the 3rd job (Run 5) |
| Sparse attention | none | All-black frames with sla (Run 4, single test) |
| Generation mode | Reference to Video | All-black frames with Image to Video (FL2VA) (Idle C, single test) |
| Environment variable | MIOPEN_FIND_MODE=FAST | Hung during text encoder convolution |
| Reference image | Full-body shot facing the target direction | Front-only reference altered side-view hairstyle |
All matting above used the default auto_border setting, though the node also provides options for background removal models and edge refinement.