hdmf.monitor module¶
- class hdmf.monitor.DataChunkProcessor(data)¶
Bases:
AbstractDataChunkIterator
Initialize the DataChunkIterator
- Parameters:
data (
DataChunkIterator
) – the DataChunkIterator to analyze
- recommended_chunk_shape()¶
Recommend the chunk shape for the data array.
- Returns:
NumPy-style shape tuple describing the recommended shape for the chunks of the target array or None. This may or may not be the same as the shape of the chunks returned in the iteration process.
- recommended_data_shape()¶
Recommend the initial shape for the data array.
This is useful in particular to avoid repeated resized of the target array when reading from this data iterator. This should typically be either the final size of the array or the known minimal shape of the array.
- Returns:
NumPy-style shape tuple indicating the recommended initial shape for the target array. This may or may not be the final full shape of the array, i.e., the array is allowed to grow. This should not be None.
- get_final_result(**kwargs)¶
Return the result of processing data fed by this DataChunkIterator
- abstract process_data_chunk(data_chunk)¶
- This method should take in a DataChunk,
and process it.
- Parameters:
data_chunk (
DataChunk
) – a chunk to process
- abstract compute_final_result()¶
- Return the result of processing this stream
Should raise NotYetExhaused exception
- class hdmf.monitor.NumSampleCounter(data)¶
Bases:
DataChunkProcessor
Initialize the DataChunkIterator
- Parameters:
data (
DataChunkIterator
) – the DataChunkIterator to analyze
- compute_final_result()¶