fix: 靶子检测

This commit is contained in:
2026-08-11 14:17:21 +08:00
parent b94b0f2e55
commit ae339889c2
3 changed files with 2 additions and 1 deletions
+1
View File
@@ -1,3 +1,4 @@
/cpp_ext/build/
/.cursor/
/dist/
.idea
Binary file not shown.
+1 -1
View File
@@ -631,7 +631,7 @@ def detect_circle_v3(frame, laser_point=None, img_cv=None):
min_r = min(rc["radius"], yellow_radius)
max_r = max(rc["radius"], yellow_radius)
size_ratio = min_r / max_r if max_r > 0 else 0
if dist_centers < max_dist and size_ratio > 0.3:
if dist_centers < max_dist and size_ratio >= 0.3:
if logger:
logger.info(f"[target] -> 找到匹配的红圈: 黄心({yellow_center}), "
f"红心({rc['center']}), 距离:{dist_centers:.1f}, "