added debug image steps for explainer (to be written)

This commit is contained in:
2024-08-01 01:47:35 +02:00
parent ed9215ab11
commit 6637ddba80
12 changed files with 3 additions and 2 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 16 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 MiB

+2 -2
View File
@@ -1,4 +1,3 @@
# import the necessary packages
import cv2
import utils
@@ -9,6 +8,7 @@ import argparse
# construct the argument parser and parse the arguments
ap = argparse.ArgumentParser()
ap.add_argument("-i", "--image", required=True, help="path to input image containing AprilTag")
ap.add_argument("-d", "--debug", action="store_true", help="display debug information")
args = vars(ap.parse_args())
# load the input image and convert it to grayscale
@@ -17,7 +17,7 @@ print("[INFO] loading image...")
image = cv2.imread(args["image"])
utils.display_image("Image", image)
path = cv_maze.solve_maze(image)
path = cv_maze.solve_maze(image, debug=args["debug"])
# draw the path on the original image
+1
View File
@@ -26,6 +26,7 @@ def display_image(label, image, default_width: int = 800, default_height: int =
cv2.namedWindow(label, cv2.WINDOW_NORMAL)
cv2.resizeWindow(label, default_width, default_height)
cv2.imshow(label, image)
cv2.imwrite(f"debug-steps/{len(WINDOW_LABELS):03}_{label}.png", image)
def wait_frame():