module TensorflowLite::Image::Detection::BoundingBox
Included Modules
Direct including types
Defined in:
tflite_image/detection/bounding_box.crInstance Method Summary
-
#adjust_bounding_box(target_aspect_ratio : Float64, image_width : Int32, image_height : Int32)
This allows us to extract features from an image in the correct aspect ratio for further processing
-
#area : Float32
Calculate the area
-
#aspect_ratio : Float64
Calculate current aspect ratio
- #bottom : Float32
- #boundary : Detection::Line
- #height : Float32
- #left : Float32
- #right : Float32
-
#to_pixel_coordinates(image_width : Int32, image_height : Int32)
Convert percentage-based dimensions to pixel coordinates
- #top : Float32
-
#width : Float32
Calculate width and height in percentage
Instance methods inherited from module TensorflowLite::Image::Detection::Lines
lines : Indexable(Detection::Line)
lines
Instance methods inherited from module TensorflowLite::Image::Detection::Classification
index : Int32
index,
label : String | Nil
label,
score : Float32
score
Instance Method Detail
def adjust_bounding_box(target_aspect_ratio : Float64, image_width : Int32, image_height : Int32)
#
This allows us to extract features from an image in the correct aspect ratio for further processing
def to_pixel_coordinates(image_width : Int32, image_height : Int32)
#
Convert percentage-based dimensions to pixel coordinates