|
RoboCarts
|
Functions | |
| def | filter_contours (cnts, aspect_ratio_limit=3) |
| def | tl_br_to_xywh (rectangle) |
| def | cnt_from_rect (rect) |
@file contour.py @brief This file contains functions for the manipulations with image contours
| def contour.cnt_from_rect | ( | rect | ) |
Converts a rectangle to the contour format :param rect: x,y,w,h - rectangle :return: contour
| def contour.filter_contours | ( | cnts, | |
aspect_ratio_limit = 3 |
|||
| ) |
Filters contours based on their aspect ratio :param cnts: contours :param aspect_ratio_limit: maximal allowed aspect ratio for a detection :return: filtered contours
| def contour.tl_br_to_xywh | ( | rectangle | ) |
Converts a rectangle from top-left, bottom-right format to x, y , width, height format :param rectangle: tl,br - rectangle :return: x,y,w,h - rectangle
1.8.13