Skip to content

Commit 0521648

Browse files
authored
reverts previos commit
not right branch.
1 parent 3d7ea32 commit 0521648

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

src/ethoscope/trackers/adaptive_bg_tracker.py

+1-7
Original file line numberDiff line numberDiff line change
@@ -288,13 +288,7 @@ def _pre_process_input_minimal(self, img, mask, t, darker_fg=True):
288288
#
289289
mean = cv2.mean(self._buff_grey, mask)
290290

291-
# Possible division by zero, has to be protected with epsilon, raise a warning
292-
293-
if mean[0] == 0:
294-
scale = 128. / (mean[0]+1e-10)
295-
logging.warning("Division by Zero in image preprocessing.")
296-
else:
297-
scale = 128. / mean[0]
291+
scale = 128. / mean[0]
298292

299293
cv2.multiply(self._buff_grey, scale, dst = self._buff_grey)
300294

0 commit comments

Comments
 (0)