Skip to content
This repository has been archived by the owner on Jan 1, 2024. It is now read-only.

Commit

Permalink
Removed the unneeded prints
Browse files Browse the repository at this point in the history
  • Loading branch information
micnekr committed Feb 24, 2022
1 parent 4f41b07 commit 563bf3d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
1 change: 0 additions & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,4 +95,3 @@ def poll_sensors_and_write(sensors, out_file):
# Get time now
now_time = datetime.now()
iteration_index += 1
print(end_time, datetime.now())
5 changes: 1 addition & 4 deletions sensors/camera/base_camera.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
# Does not exist = found
save_id += 1
not_found = os.path.exists(f"./out/{save_id}_nir.png")
print("Image ID:", save_id)


class CameraData(Data):
Expand Down Expand Up @@ -97,7 +96,6 @@ def serialise_as_png(self) -> bytes:
# Return as bytes; dynamic size based on size of image ID
result = int.to_bytes(image_id, length=(image_id.bit_length()+7)//8,
byteorder='big')
print("Serialised image file id", image_id)

save_id += 1 # Next image
return result
Expand All @@ -107,7 +105,6 @@ def deserialise_as_png(b):
"""Deserialise the image data as a png."""
# Load from bytes
load_id = int.from_bytes(b, byteorder='big')
print("Deserialised image file id", load_id)
# As PNG, get from ID
nir = cv2.imread(os.path.join(".", "out", str(load_id) + "_nir.png"), \
cv2.IMREAD_ANYCOLOR)
Expand Down Expand Up @@ -153,7 +150,7 @@ def process(image):
if CAN_DISCARD:
# Discard the images if not useful
if CameraData.should_discard(image):
print("Discarding the image")
print("Warning: Discarding the image")
return None
return image

Expand Down

0 comments on commit 563bf3d

Please sign in to comment.