amartya-k / vision

This is a simple vehile detection project using Computer Vision
68 stars 41 forks source link

ValueError: not enough values to unpack (expected 3, got 2) #3

Closed Lepiloff closed 4 years ago

Lepiloff commented 4 years ago

I get an error then running main.py

(qrcode) y700@jekson:~/projects/cardetect/car/vision$ python main.py
Red line y: 288
Blue line y: 192
Traceback (most recent call last):
  File "main.py", line 85, in <module>
    _, countours0,hierarchy=cv2.findContours(mask,cv2.RETR_EXTERNAL,cv2.CHAIN_APPROX_NONE)
ValueError: not enough values to unpack (expected 3, got 2)
balapatricia commented 4 years ago

Just delete the '_' character like this: countours0,hierarchy=cv2.findContours(mask,cv2.RETR_EXTERNAL,cv2.CHAIN_APPROX_NONE)