Files
douyi_guaji_main/douyin/detection/detection_pkg
CodexandClaude Opus 4.7 01034347f4 refactor(finder): 抽 check_have_fudai_with_ready_screenshot 中"numpy 加速水平带扫描"块到 finder_numpy_scan
将 127 行的 numpy 加速扫描块抽到独立模块。
使用 numpy 批量处理,从最优位置向左右两侧交替搜索福袋图标的特征颜色。

helper 接受 (analyser, detected, detected_x, pic_new, width, height, rx, ry,
y_pianyi_val, optimal_x_scaled),返回更新后的 (detected, detected_x)。

finder.py: 553 → 435 行 (-118)
新增 finder_numpy_scan.py: 156 行

finder.py 跌破 500 行(1438 → 435,本会话累计削减 1003 行 = -70%)

验证:
- pytest 1013 passed
- compile OK

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 13:24:50 +08:00
..