valrik
Posts: 28
Joined: Mon May 26, 2014 1:55 pm

Python SimpleCV help

Tue Sep 23, 2014 10:01 pm

Hi

I'm trying to call findKeypointMatch but i keep getting this error

Code: Select all

Fatal Python error: (pygame parachute) Segmentation Fault
Aborted
all im doing is loadin an image from a file list

my Python

Code: Select all

import time
import io
import os
import glob
import picamera
import picamera.array
import cv2
from SimpleCV import Image, Display, Color

with picamera.PiCamera() as camera:
        
        camera.resolution = (160,120)
        camera.framerate = 30
        #camera.awb_mode = 'auto'
        camera.start_preview()
        #camera.exposure = 'auto'
        d = Display()
        #db = Display()
        #stream = io.BytesIO()
        while not d.isDone():
                with picamera.array.PiRGBArray(camera) as stream:
                        camera.capture(stream, format='rgb')

                        img = Image( stream.array ).rotate90()
                        img.save(d)
                        imgs = list()
                        directory = os.path.join("unknown_faces/","*.jpg")

                                files = glob.glob(directory)
                                

                                count = 0
                                print ("Files Found %s" % str(len(files)))
                                for file in files:
                                        count = count + 1
                                        testimg = Image(file)
                                        
                                        match = img.findKeypointMatch(testimg)
                     

User avatar
davef21370
Posts: 897
Joined: Fri Sep 21, 2012 4:13 pm
Location: Earth But Not Grounded

Re: Python SimpleCV help

Wed Sep 24, 2014 5:01 pm

http://stackoverflow.com/questions/1003 ... tion-fault might help to find where the problem is occurring.

Dave.
Apple say... Monkey do !!

Return to “Python”