-
Notifications
You must be signed in to change notification settings - Fork 0
Manually Segmentation
The module gives all the functions used through the manually segmentation
The function return the image on which print the objects. If original is not provided the objects already segmented are shown in light gray color.
-
Parameters
original (bool) – The parameter specify when return the original image of the image with the already insert polygons.
-
Returns
The image required is return
The function asks the path of the image to segment and the folder in which saves the output json.
The output is a JSON structure in a dictionary. The key is an integer that represent uniquely the object segmented. Each value are the vertices of the polygon used to segment the object.
-
Returns
A bool value that check if all operations end correctly
-
Return type
bool
The function plot all polygons into the image. If the function is called as final version the image is not shown, otherwise it is printed into a window.
-
Parameters
-
pols (list) – A list containing all the polygon represented as a dictionary
-
final (bool) – Parameter that represent when print the image and return or only return
-
-
Returns
Return the image on which all the polygons are printed
The function takes care of print the points, line and polygons while the selection
-
Parameters
saving (bool) – The parameters represent when print the polygons in saving mode (in red colors instead of green).
The method is called when the required event is listen through openCV
-
Parameters
-
event – Name of the event
-
x – Position x of the event
-
y – Position y of the event
-
flags – Not used parameter
-
param – Not used parametr
-