Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenCV python: ValueError: too many values to unpack #1

Open
fdornelasx opened this issue Apr 29, 2018 · 2 comments
Open

OpenCV python: ValueError: too many values to unpack #1

fdornelasx opened this issue Apr 29, 2018 · 2 comments

Comments

@fdornelasx
Copy link

fdornelasx commented Apr 29, 2018

Obtive este erro ao rodar o código. Achei a solução pesquisando na internet e parece que o problema é com a última versão do OpenCV, para corrigir basta colocar um "underline" antes da variável "contorno". Comigo funcionou perfeitamente em Python 2.7.9 e Python 3.6, após a mudança.

Solução: _,contornos, hierarquia = cv2.findContours(frameSegmentado, cv2.RETR_TREE, cv2.CHAIN_APPROX_SIMPLE)

Créditos: https://stackoverflow.com/questions/25504964/opencv-python-valueerror-too-many-values-to-unpack

contornos, hierarquia = cv2.findContours(frameSegmentado, cv2.RETR_TREE, cv2.CHAIN_APPROX_SIMPLE)

@JoseRFJuniorLLMs
Copy link

Peguei o mesmo ! Obrigado por pesquisar antes ! tanks !

@danielnunesdc
Copy link

Obrigado! @fillipedornelas ajudou bastante.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants