Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想通过使用图像处理边缘检测技术来计算仓库中的箱子数量。所以我使用Sobel算法来检测边缘。现在我需要测量边缘长度。有谁知道如何获得边的长度和任何合适的算法来获得最终计数?
您可以考虑使用提取边缘的 Canny Edge Detector。所有边缘点的宽度为一个像素。然后您可以提取边缘点的连通分量并计算每个连通分量中有多少像素。
您应该考虑使用 Hough 变换来识别框。然而,基本变换不会明确地为您提供特定框边的长度,但这将是一个很好的起点。
看看通过 Hough 变换对桩箱进行定位。