Closed qingmm closed 6 years ago
@qingmm Thank you for reporting!
Please let me confirm that this is the code with which you faced the segmentation fault error, right?
import gist
import numpy as np
img = ... # numpy array containing an image
descriptor = gist.extract(img)
I found the error occurs when img
is None
.
Can you please check whether it is in your case?
Anyway, this is a bug and I will fix it.
@tuttieee Thank you for replying! Yes, it is, but I find I have misunderstanding your code before carelessly, I pass a imagepath to "img", so, your code is right, just not clear enough.
mmm, I have added a comment like below:
img = ... # numpy array containing an image
Isn't it clear?
Anyway, I updated the code and it now throws TypeError
unless the argument is of np.ndarray
.
It occurs
Segmentationfault
(core dumped)' when I follow the instructions in the Usage section, maybe it should be as following:The code above is from your file in sample/feature_extraction, it works well. Thank you for your code, it helps me a lot.