Base Video Data#
Base Video Dataset.
- class anomalib.data.base.video.AnomalibVideoDataModule(train_batch_size, eval_batch_size, num_workers, val_split_mode, val_split_ratio, test_split_mode=None, test_split_ratio=None, seed=None)#
Bases:
AnomalibDataModuleBase class for video data modules.
- class anomalib.data.base.video.AnomalibVideoDataset(task, transform, clip_length_in_frames, frames_between_clips, target_frame=VideoTargetFrame.LAST)#
Bases:
AnomalibDataset,ABCBase video anomalib dataset class.
- Parameters:
task (str) – Task type, either ‘classification’ or ‘segmentation’
transform (A.Compose) – Albumentations Compose object describing the transforms that are applied to the inputs.
clip_length_in_frames (int) – Number of video frames in each clip.
frames_between_clips (int) – Number of frames between each consecutive video clip.
target_frame (VideoTargetFrame) – Specifies the target frame in the video clip, used for ground truth retrieval. Defaults to
VideoTargetFrame.LAST.
- property samples: DataFrame#
Get the samples dataframe.
- class anomalib.data.base.video.VideoTargetFrame(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)#
Bases:
str,EnumTarget frame for a video-clip.
Used in multi-frame models to determine which frame’s ground truth information will be used.