opticam.utils.batching

Functions

get_batches(input)

Given an input list, split it into up to 100 evenly(ish)-sized batches.

get_batch_size(L)

Compute the batch size for a given input length.

Module Contents

opticam.utils.batching.get_batches(input)

Given an input list, split it into up to 100 evenly(ish)-sized batches.

Parameters

inputList[Any]

The input list.

Returns

List[List[Any]]

The batches.

Parameters:

input (List[Any])

Return type:

List[List[Any]]

opticam.utils.batching.get_batch_size(L)

Compute the batch size for a given input length.

Parameters

Lint

The length of the input.

Returns

int

The batch size.

Parameters:

L (int)

Return type:

int