From ccd7b2fd16bbab862acbfaaf127338ccfe7594a6 Mon Sep 17 00:00:00 2001 From: "Dr. Peter Netz" <152088022+zentrocdot@users.noreply.github.com> Date: Sun, 2 Feb 2025 11:24:53 +0100 Subject: [PATCH] Update nodes.py --- nodes/nodes.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/nodes/nodes.py b/nodes/nodes.py index 5277ad4..379c733 100644 --- a/nodes/nodes.py +++ b/nodes/nodes.py @@ -105,7 +105,7 @@ class CircleDetection: def post_img(self, img, detected_circles): '''Postprocess image.''' # Draw circles. - img, (a, b, r) = draw_circles(img, detected_circles) + img, (a, b, r) = self.draw_circles(img, detected_circles) # Print dimensions and radius. #print("a:", a, "b:", b, "r:", r) # Return image and tuple. @@ -116,11 +116,11 @@ class CircleDetection: # Read image. #img_input = cv2.imread(fn, cv2.IMREAD_COLOR) # Preprocess image. - gray_blur = pre_img(img_input) + gray_blur = self.pre_img(img_input) # Process image. Detect circles. - detected_circles = detect_circles(gray_blur) + detected_circles = self.detect_circles(gray_blur) # Postrocess image. - img_output, _ = post_img(img_input, detected_circles) + img_output, _ = self.post_img(img_input, detected_circles) # Write image. #cv2.imwrite("detected_circle.jpg", img_output) # Return None.