data_juicer.utils.ASD_mapper_utils module#
- data_juicer.utils.ASD_mapper_utils.detect_and_mark_anomalies(data, window_size=7, std_multiplier=2)[source]#
- data_juicer.utils.ASD_mapper_utils.crop_video_with_facetrack(video_array, track, cropFile, audioFilePath, is_empty=False)[source]#
- data_juicer.utils.ASD_mapper_utils.annotate_video_with_bounding_boxes_with_audio(video_path, q_human_video_track_bbox, output_path)[source]#
- data_juicer.utils.ASD_mapper_utils.annotate_video_with_bounding_boxes_withText_with_audio(video_path, q_human_video_track_bbox, output_path, numbers)[source]#
- data_juicer.utils.ASD_mapper_utils.annotate_video_with_bounding_boxes(video_array, frame_indices, bounding_boxes, output_path)[source]#
Annotates specified frames in the video with bounding boxes and saves the result to a new video file.
- Parameters:
video_array â Input video as a numpy array with shape (num_frames, height, width, channels).
frame_indices â List of frame indices to annotate.
bounding_boxes â Array of bounding box coordinates with shape (num_frames_to_annotate, 4), where each bounding box is (x, y, w, h).
output_path â Path to save the output video.