Commit 86f18c39 authored by Sikhin VC's avatar Sikhin VC

added server API endpoints

parent 91074b9a
Pipeline #69238 failed with stage
......@@ -250,7 +250,6 @@ class CementBagCounter(ModelWrapper):
:return: boolean
"""
_alignment, line_coordinates = self.get_line_coordinates()
logger.info(f"line_coordinates {line_coordinates} and _alignment {_alignment}")
assert len(line_coordinates) == 4, "Line coordinates variable is invalid"
assert len(point) == 2, "Point variable is invalid"
......@@ -303,7 +302,6 @@ class CementBagCounter(ModelWrapper):
frame = draw_circles_on_frame(
frame, centroid, radius=10, color=(0, 0, 255), thickness=-1
)
logger.info(f'self.validate_point_position(centroid) {self.validate_point_position(centroid)}')
if self.validate_point_position(centroid):
if not isinstance(self.initial_object_position, bool):
......@@ -312,7 +310,6 @@ class CementBagCounter(ModelWrapper):
self.initial_object_position = True
_point_position = self.line_point_position(point=centroid)
logger.info(f'Centroid position {_point_position}')
# Check point in the same side as the initial object
if _point_position == self.initial_object_position:
# Check the object is not already counted
......@@ -417,7 +414,7 @@ class CementBagCounter(ModelWrapper):
for x in dets:
frame = cv2.rectangle(frame, (x["points"][0], x["points"][1]), (x["points"][2], x["points"][3]),
(255, 255, 255), 2)
logger.info(f"Dets after overlapping removal: {dets}")
logger.debug(f"Dets after overlapping removal: {dets}")
return dets, frame
def inference(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment