Exemplo n.º 1
0
def desktopSearch(imgp):
       image = cv2.imread(imgp)
       image = hkresize(image)
       cd=des.ColorDescriptor((8,12,3))
       matching.key["cd"]=cd.describe(image)

       faceObj=objects.Face()
       matching.key["faces"]=faceObj.getFaces(image)
       imlist=[]
       for dir in dirs:
           imlist+=spider.desktopSpiderThread(dir)
       print imlist
       thrdlist=[]
       print "scaning...."
       i=0
       for img in imlist:
           th=matching(img)
           thrdlist.append(th)
           th.start()
           time.sleep(0.01)

       for  th in thrdlist:
           th.join()
       print "complete scan"
       cv2.waitKey(0)
       cv2.destroyAllWindows()
       print matching.result
Exemplo n.º 2
0
def testSpider():
     dir="/home/haikent/Pictures/"
     return spider.desktopSpiderThread(dir)