FiducialCollection.estimatePose: ids/cornerss zip misaligns after ID filtering
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 76/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- opencv, python
- Lĩnh vực
- computer-vision
Hướng nghiên cứu
Bắt đầu trong ImageFiducials.py tại FiducialCollection.estimatePose và kiểm tra cách các góc và ID được phát hiện được lọc. Bổ sung phạm vi kiểm thử hồi quy cho nhiều board hoặc các ID marker thừa, sau đó xác minh rằng các góc và ID đã lọc vẫn tương ứng với nhau và bộ kiểm thử hiện có vượt qua.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Found 2026-08-03 while fixing the OpenCV 4/5 `ids` shape compat issue in the same method (see #44). `ImageFiducials.py`'s `FiducialCollection.estimatePose` does:
```python
cornerss = [
corners.T.squeeze()
for corners, id in zip(cornerss, ids)
if id in self._ids
]
ids = [id for corners, id in zip(cornerss, ids) if id in self._ids]
```
The second line's `zip(cornerss, ids)` pairs the already-filtered `cornerss` (reassigned on the line above) against the original, unfiltered `ids`. If any detected marker's ID isn't in `self._ids` (exactly the scenario the docstring calls out -- "filter the markers, useful if there are several ArUco boards in the scene"), the two lists have different lengths and `zip` silently pairs mismatched corners/ids from that point on. Only harmless when every detected marker happens to belong to this board (no actual filtering occurs), which is presumably why it hasn't been caught yet.
Fix
Compute the filtered `cornerss`/`ids` together in a single pass (e.g. one list comprehension producing tuples, then unzip), so both lists are always built from the same original, unfiltered pairing. Needs a test with multiple boards/extraneous marker IDs in view to catch a regression -- there's currently no coverage for the multi-board filtering case at all.
- Ngôn ngữ chính
- Python
- Star
- 220
- Fork
- 30
- Merge trung bình
- 12 ngày 23 giờ
- Pull request đã merge (30 ngày)
- 5
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của petercorke/machinevision-toolbox-python
-
tech-debt
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
-
tech-debt
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
-
tech-debt
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 52/100
-
tech-debt
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 72/100
-
tech-debt
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
Tất cả issue của petercorke/machinevision-toolbox-python
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
stephrobert/dsoxlab#238 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
sublimehq/package_control#1780 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
nwg-piotr/nwg-displays#145 ·