View source on GitHub |
Preprocessing ops.
Classes
class range
: range(stop) -> range object range(start, stop[, step]) -> range object
Functions
center_crop_image(...)
: Center crop a square shape slice from the input image.
center_crop_image_v2(...)
: Center crop a square shape slice from the input image.
clip_or_pad_to_fixed_size(...)
: Pads data to a fixed length at the first dimension.
color_jitter(...)
: Applies color jitter to an image, similarly to torchvision`s ColorJitter.
compute_padded_size(...)
: Compute the padded size given the desired size and the stride.
horizontal_flip_boxes(...)
: Flips normalized boxes horizontally.
horizontal_flip_image(...)
: Flips image horizontally.
horizontal_flip_masks(...)
: Flips masks horizontally.
normalize_image(...)
: Normalizes the image to zero mean and unit variance.
normalize_scaled_float_image(...)
: Normalizes a scaled float image to zero mean and unit variance.
random_brightness(...)
: Jitters brightness of an image.
random_contrast(...)
: Jitters contrast of an image, similarly to torchvision`s ColorJitter.
random_crop(...)
: Randomly crop the image and boxes, filtering labels.
random_crop_image(...)
: Randomly crop an arbitrary shaped slice from the input image.
random_crop_image_v2(...)
: Randomly crop an arbitrary shaped slice from the input image.
random_crop_image_with_boxes_and_labels(...)
: Crops a random slice from the input image.
random_horizontal_flip(...)
: Randomly flips input image and bounding boxes horizontally.
random_horizontal_flip_with_roi(...)
: Randomly flips input image and bounding boxes horizontally.
random_saturation(...)
: Jitters saturation of an image, similarly to torchvision`s ColorJitter.
random_vertical_flip(...)
: Randomly flips input image and bounding boxes vertically.
resize_and_crop_boxes(...)
: Resizes boxes to output size with scale and offset.
resize_and_crop_image(...)
: Resizes the input image to output size (RetinaNet style).
resize_and_crop_image_v2(...)
: Resizes the input image to output size (Faster R-CNN style).
resize_and_crop_masks(...)
: Resizes boxes to output size with scale and offset.
resize_image(...)
: Resize image with size and max_size.
vertical_flip_boxes(...)
: Flips normalized boxes vertically.