module TensorflowLite::Image
Defined in:
tflite_image.crtflite_image/detection/classification.cr
tflite_image/image_offset_calculations.cr
Constant Summary
-
DEFAULT_SCALE_MODE =
Scale::Fit
Class Method Summary
-
.calculate_boxing_offset(original_width : Int32, original_height : Int32, target_width : Int32, target_height : Int32) : Tuple(Int32, Int32)
how much do we need to adjust detections if we scaled to fit
-
.calculate_cropping_offset(original_width : Int32, original_height : Int32, target_width : Int32, target_height : Int32) : Tuple(Int32, Int32)
how much we need to adjust detections if we scaled to cover
Class Method Detail
def self.calculate_boxing_offset(original_width : Int32, original_height : Int32, target_width : Int32, target_height : Int32) : Tuple(Int32, Int32)
#
how much do we need to adjust detections if we scaled to fit
def self.calculate_cropping_offset(original_width : Int32, original_height : Int32, target_width : Int32, target_height : Int32) : Tuple(Int32, Int32)
#
how much we need to adjust detections if we scaled to cover