Tensor Info
Tensor Info — the node that tells you what the hell you're actually working with
- tensor
- shape
- dtype
- device
Every ComfyUI beginner eventually hits the wall where a node refuses to connect and the error message is just a wall of tensor shapes. Tensor Info is the debugging node that tells you what's actually flowing through a wire: its shape, its dtype, and what device it lives on. It's the single most useful node in this pack's tensor section, and honestly the one I'd install the whole extension for.
Here's the thing about ComfyUI: nearly everything you touch is secretly a tensor. An image is a 4D tensor like [1, 1024, 1024, 3] (batch, height, width, channels). Latents are a different shape entirely - more like [1, 4, 128, 128]. Masks, embeddings, conditioning - all tensors. When something downstream complains, the fastest way to understand why is to actually look at what shape your data has, and this node is a mirror.
It's part of Basic data handling by StableLlama, a dependency-free utility pack that wraps plain Python and PyTorch into ComfyUI nodes. The tensor corner gives you create, binary/unary ops, slice, reshape, permute, join, and this - the analyzer.
How it works
You wire a tensor in, and the node returns three values straight from PyTorch: list(tensor.shape), str(tensor.dtype), and str(tensor.device). That's it - no math, no state, no side effects. It's a passive observer that just reports facts.
The outputs that matter
One input, three outputs, all of them useful:
shape- a list of the tensor's dimensions, e.g.[1, 512, 512, 3]for an image,[1, 4, 64, 64]for SDXL latents. This is the number to read when a node won't accept your data: mismatched dimensions are the #1 cause of "shape mismatch" errors.dtype(STRING) -torch.float32,torch.int64, whatever. In practice, images and latents are float32; if something arrives asint64, that's usually a sign it came out of a cast or create node rather than a sampler, and math will behave differently.device(STRING) -cuda:0vscpu. If something is sitting on the CPU when the rest of your graph is on GPU, that's a performance red flag worth knowing about.
Where you'd actually use it
Stick one on the end of a wire when something breaks, read the shapes, then delete it. That's the 95% use case. The other 5%: permanently hanging it off a suspicious branch while you build a workflow, so you can sanity-check that a custom node didn't quietly swap your image to channel-first or drop the batch dimension.
Installing it
# ComfyUI Manager (recommended): search "Basic data handling", install, restart.
# or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/StableLlama/ComfyUI-basic_data_handling
# restart ComfyUI
No dependencies beyond torch (which ComfyUI already ships), no model downloads. The whole pack is lightweight by design.
Gotchas
Because the input is a wildcard *, ComfyUI won't type-check what you connect. Feed it an image and it works. Feed it a string and it'll try to coerce it into a tensor and likely throw. If you see a confusing error, it's not the node being broken - it's that you handed it something that isn't a tensor. Also worth knowing: shape comes out as a list, so if you want to act on it (say, feed a dimension into an INT input), you'll need a list-to-value step - this node reports, it doesn't extract.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| tensor | * | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| shape | * | — |
| dtype | STRING | — |
| device | STRING | — |