Skip to main content

//clika-runtime/io.clika.runtime/FrameBatch

FrameBatch

[common]
class FrameBatch(val frames: Tensor, val indices: LongArray, val ptsSeconds: DoubleArray, val durationSeconds: DoubleArray)

A decoded batch of frames plus the alignment facts a video model needs: frames packed [K, H, W, 3] UInt8 on the host, the source indices they were taken from, each frame's presentation time in seconds (the clip's own timeline, offsets and uneven spacing included) and its display duration. Release frames when done.

Constructors​

FrameBatch[common]
constructor(frames: Tensor, indices: LongArray, ptsSeconds: DoubleArray, durationSeconds: DoubleArray)

Properties​

NameSummary
durationSeconds[common]
val durationSeconds: DoubleArray
frames[common]
val frames: Tensor
indices[common]
val indices: LongArray
isEmpty[common]
val isEmpty: Boolean
True when the batch holds no frames.
ptsSeconds[common]
val ptsSeconds: DoubleArray
size[common]
val size: Int
The number of frames in the batch.