ComfyUI > Nodes > CRT-Nodes > Get First & Last Frame (CRT)

ComfyUI Node: Get First & Last Frame (CRT)

Class Name

CRTFirstLastFrameSelector

Category
CRT/Video
Author
CRT (Account age: 1707days)
Extension
CRT-Nodes
Latest Updated
2026-03-16
Github Stars
0.1K

How to Install CRT-Nodes

Install this extension via the ComfyUI Manager by searching for CRT-Nodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter CRT-Nodes in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Get First & Last Frame (CRT) Description

Extracts first and last frames from image batches for efficient sequence analysis and processing.

Get First & Last Frame (CRT):

The CRTFirstLastFrameSelector node is designed to efficiently handle batches of image frames, specifically focusing on extracting the first and last frames from a given batch. This node is particularly useful in scenarios where you need to quickly identify the starting and ending visuals of a sequence, such as in video processing or animation workflows. By automatically selecting these frames, it simplifies the process of frame analysis and manipulation, ensuring that you can focus on the most critical parts of your image sequence without manually sifting through each frame. This node is especially beneficial when dealing with large batches of images, as it streamlines the workflow by providing immediate access to the key frames of interest.

Get First & Last Frame (CRT) Input Parameters:

images

The images parameter is a required input that accepts a batch of images in the form of a PyTorch tensor. This tensor should have the shape (batch_size, height, width, channels), where batch_size represents the number of images in the batch. The function of this parameter is to provide the node with the necessary data to extract the first and last frames. The impact of this parameter on the node's execution is significant, as it determines the frames that will be returned. There are no specific minimum, maximum, or default values for this parameter, as it depends on the user's input batch size and image dimensions.

Get First & Last Frame (CRT) Output Parameters:

first_frame

The first_frame output parameter provides the first image frame from the input batch. This output is crucial for tasks that require the initial visual context of a sequence, such as setting the starting point for video editing or analysis. The output is a PyTorch tensor that retains the batch dimension, ensuring compatibility with further processing steps.

last_frame

The last_frame output parameter delivers the last image frame from the input batch. This output is essential for capturing the concluding visual context of a sequence, which can be used for tasks like determining the endpoint of a video or animation. Similar to the first_frame, this output is a PyTorch tensor that maintains the batch dimension for seamless integration into subsequent workflows.

Get First & Last Frame (CRT) Usage Tips:

  • Ensure that the input batch of images is correctly formatted as a PyTorch tensor with the appropriate dimensions to avoid errors during processing.
  • Utilize this node in video editing or animation projects where identifying the first and last frames quickly can enhance workflow efficiency and decision-making.

Get First & Last Frame (CRT) Common Errors and Solutions:

Incorrect Tensor Shape

  • Explanation: The input tensor does not have the expected shape (batch_size, height, width, channels).
  • Solution: Verify that your input tensor is correctly shaped and formatted before passing it to the node.

Empty Batch Input

  • Explanation: The input batch is empty, leading to an inability to extract frames.
  • Solution: Ensure that the input batch contains at least one image frame to allow the node to function correctly.

Get First & Last Frame (CRT) Related Nodes

Go back to the extension to check out more related nodes.
CRT-Nodes
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.

Get First & Last Frame (CRT)