Simplified defs for same_cams...

main
Robert 8 months ago
parent 449f521fa7
commit 9e0b36d600
  1. 15
      dedup.py

@ -56,23 +56,18 @@ def handle_GPS(location1, location2):
point2 = (latitude2, longitude2)
camera1 = (camera_info1['Make'], camera_info1['Model'])
camera2 = (camera_info2['Make'], camera_info2['Model'])
same_cams = is_same_camera(camera1, camera2)
the_location = is_same_location(point1, point2)
match the_location:
case True:
print("Images are both from same exact Location")
if is_same_camera(camera1, camera2):
if same_cams:
print("Cameras are the same.")
delibs.exit_timer(5)
else:
print("Different Cameras detected.")
not_a_dup()
case False:
print("Images are from different Locations")
if is_same_camera(camera1, camera2) == False:
print("Different Cameras detected.")
not_a_dup()
case float() if isinstance(the_location, float): # Checks if it's a float
print(f"Images distance in feet: {the_location:.2f}")
@ -81,10 +76,8 @@ def handle_GPS(location1, location2):
if is_same_camera(camera1, camera2):
print("Cameras are the same.")
delibs.exit_timer(6)
else:
print("Different Cameras detected.")
not_a_dup()
elif is_same_camera(camera1, camera2) == False:
if same_cams == False:
print("Different Cameras detected.")
not_a_dup()

Loading…
Cancel
Save