EA Trim Frames
Chop frames off the head and tail — and get previews back
- images
- images
- first_frame
- last_frame
- frame_count
Generated clips almost always have junk at the edges: a couple of frames of startup noise at the head, a drift at the tail. EA Trim Frames is the dead-simple fix - tell it how many frames to cut from the start and end, and it hands back the trimmed sequence plus the first/last frames so you can check the result without opening a player.
It's the most basic node in the pack's video family, and that's the point. No detection, no dials: two numbers in, trimmed frames out.
What you set
skip_first- frames to drop from the start.skip_last- frames to drop from the end.
That's the whole input surface, plus the images sequence. The slicing is safe: out-of-range values are clamped rather than erroring, so skip_first bigger than your clip just returns an empty sequence instead of crashing - which is forgiving, but check it if your output is mysteriously empty.
The outputs
images- the trimmed sequence. Wire this to your saver or next node.first_frame/last_frame- the new endpoints, as single-frame IMAGE previews. This is the detail that makes the node pleasant: after a trim, you can eyeball the exact frames that will now join a loop.frame_count- how many frames survived. Handy for a text display or a downstream frame-budget check.
Where it fits
It's the manual cousin of the pack's fancier EA Auto Trim (PingPong), which finds the cut points for you. Use this one when you know the numbers - you generated 81 frames and want the last 9 gone to hit a clean 72, say. And it pairs naturally with EA PingPong: trim the junk, then loop the result.
For anything where the cut point isn't obvious, reach for the auto-trim instead; this node is deliberately dumb, and that's its virtue. It's also the one you'll wire into training-data prep when you want a repeatable, exact head/tail removal with no surprises.
Install
Part of comfyui-ea-nodes: ComfyUI Manager → search comfyui-ea-nodes, or git clone https://github.com/ExoticArts/comfyui-ea-nodes into custom_nodes/, restart, hard-refresh. No extra Python dependencies - the pack's requirements.txt is empty.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| skip_first | INT | 0 | — |
| skip_last | INT | 0 | — |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| first_frame | IMAGE | — |
| last_frame | IMAGE | — |
| frame_count | INT | — |