Ask Your Question

Revision history [back]

can not help much at first we do the deskewing image right?

simplecv with it is easy.

see a image deskewing:

from SimpleCV import *
import time


img = Image("scene_2.png") # carrega a imagem 
bin = img.binarize().invert()#binariza para que fique mais facil encontrar a rotacao
bin = bin.smartRotate()


bin.show()
time.sleep(5)

result:

image description

can not help much at first we do the deskewing image right?

simplecv with it is easy.

see a image deskewing:

from SimpleCV import *
import time


img = Image("scene_2.png") # carrega a imagem 
bin = img.binarize().invert()#binariza para que fique mais facil encontrar a rotacao
bin = bin.smartRotate()


bin.show()
time.sleep(5)

result:

image description

after that you can also extract the object so that it becomes easier to detect :

from SimpleCV import *
import time


img = Image("scene_2.png") # carrega a imagem 
binario = img.binarize()#binariza para que fique mais facil encontrar a rotacao

binario = binario.smartRotate()

blobs = binario.findBlobs()

obj = blobs[-1] # extrai blob maior para obj

obj = obj.crop() #recorta obj

obj.show()
time.sleep(5)

image description