self.last_capture = None
self.last_recovered = None
- cv.namedWindow("display", cv.WINDOW_NORMAL)
+ cv.namedWindow("display", cv.WINDOW_NORMAL + cv.WINDOW_GUI_NORMAL)
if self.show_debug == True:
cv.namedWindow("debug", cv.WINDOW_NORMAL)
print("calibration failed")
quit()
- if self.use_file == True:
+ if self.use_files == True:
self.get_lookup()
def get_lookup(
return image
-
import time
import cv2 as cv
import matplotlib.pyplot as plt
+import cProfile
"""
Notes:
return data
+if __name__ == "__main__":
+ with cProfile.Profile() as pr:
+ fft = fft(130, 65)
+ fft.istft(fft.stft(np.random.randint(-32768, 32767, (130,))))
+ pr.print_stats()
camera = camera(
window_size,
window_height,
- (1840, 1000),
+ (1920, 1080),
device_id = 2,
debug = False,
dummy = True,
slept = 0
time.sleep(0.1)
- while len(audio) > 5 * segment_samples:
- time.sleep(0.01)
+ while len(audio) > 1 * segment_samples:
+ cv.waitKey(1)
slept += 1
print(f"slept {slept} times")