fix import
This commit is contained in:
@@ -177,17 +177,17 @@ class Sensor:
|
||||
# Start processing timing
|
||||
t_processing_start = time.perf_counter()
|
||||
|
||||
self.frame = frame.copy()
|
||||
|
||||
# self.frame = frame.copy()
|
||||
self.frame = frame
|
||||
# Extract and stitch tiles
|
||||
self.stitcher.get_stitch_unit(frame)
|
||||
# self.stitcher.get_stitch_unit(frame)
|
||||
self._extract_tiles(frame)
|
||||
|
||||
img = np.ascontiguousarray(self.stitcher.stitch_rt_optimized())
|
||||
|
||||
self.img_size_raw = img.shape
|
||||
# Resize
|
||||
img = cv2.resize(img, tuple(self._config_resolution_stitch), interpolation=cv2.INTER_CUBIC)
|
||||
img = cv2.resize(img, tuple(self._config_resolution_stitch), interpolation=cv2.INTER_LINEAR)
|
||||
|
||||
if self.mirror:
|
||||
img = cv2.flip(img, 1)
|
||||
@@ -201,7 +201,7 @@ class Sensor:
|
||||
self._fps = 1.0 / (time.perf_counter() - self.last_log_time)
|
||||
self.last_log_time = time.perf_counter()
|
||||
|
||||
return self.img.copy()
|
||||
return None
|
||||
|
||||
def detect_motion(self, threshold=4):
|
||||
if self.initial_img is None:
|
||||
|
||||
Reference in New Issue
Block a user