Created
April 17, 2013 18:31
-
-
Save sight-machine/5406600 to your computer and use it in GitHub Desktop.
An example of keypoint detection using SimpleCV.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from SimpleCV import Image, Color, Display | |
# load an image from imgur | |
img = Image('http://i.imgur.com/lfAeZ4n.png') | |
# use a keypoint detector to find areas of interest | |
feats = img.findKeypoints() | |
# draw the list of keypoints | |
feats.draw(color=Color.RED) | |
# show the resulting image. | |
img.show() | |
# apply the stuff we found to the image. | |
output = img.applyLayers() | |
# save the results. | |
output.save('juniperfeats.png') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
On line5:
feats = img.findKeypoints()
I get a seg fault:Using ipdb, I've traced it down to
/usr/local/lib/python2.7/dist-packages/SimpleCV/ImageClass.py(1942)getGrayNumpy() 1941 -> 1942 return self._grayNumpy
which then yields:
Fatal Python error: (pygame parachute) Segmentation Fault Aborted (core dumped)
The numpy array looked fine prior to returning it, so not sure why it faulted. Has anyone else encountered this before?