Get Batch Size

This function block is utilized to determine the size of a batch, providing the count of elements contained within a given input batch.

πŸ“₯ Inputs

Batch This is a generic input that accepts any batch, which can be a list or other collection of items.

πŸ“€ Outputs

Size This output provides the numeric count of items present in the batch.

πŸ•ΉοΈ Controls

This function block does not have any controls.

🎨 Features

Batch Size Calculation Quickly calculates the number of elements in a provided batch, making it easy to determine the length of lists or similar data structures.

πŸ“ Usage Instructions

  1. Connect a Batch: Link a batch output from another function block to the Batch input.

  2. Evaluate: Run this function block to receive the count of elements in the connected batch as output.

πŸ“Š Evaluation

When evaluated, the function block returns the size of the connected batch, providing a simple number output based on the length of the input data structure.

πŸ’‘ Tips and Tricks

Using with Batch Processing

Pair this function block with Batch Processing for optimized data handling, allowing you to effectively manage memory consumption in scenarios with large datasets.

Integrating with Data Flow

Combine with the Debatch block to split batches for more complex processing flows within your setup.

πŸ› οΈ Troubleshooting

No Output Received

Ensure that a valid batch is connected to the input. If the input does not reference a valid list or collection, the output may be undefined.

Batch Type Issues

If the batch type varies (e.g., nested lists), ensure that you are aware of the batch structure you are inputting, as this may affect the expected behavior.

Last updated