sift - runtime error of vlsift: input image contains a malformed PGM header -


i trying test sift detector of vlfeat computer vision library running sift.c file in src folder. have compiled , run program. however, got error: the input image contains malformed pgm header. sure not problem of image file inputed. explain that.

this corresponds vl_err_pgm_inv_head error code issued pgm decoder if file less 2 bytes or has not supported or invalid magic number.

please note vlfeat supports p2 (ascii) , p5 (binary) formats. should inspect magic control if fits these requirements, e.g.:

$ xxd -c 1 -l 2 foo.pgm 0000000: 50  p 0000001: 35  5  $ xxd -c 1 -l 2 bar.pbm 0000000: 50  p 0000001: 34  4 

here foo.pgm valid (graymap in binary format) bar.pbm not supported vlfeat (black & white bitmap in binary format).


Comments

Popular posts from this blog

javascript - Karma not able to start PhantomJS on Windows - Error: spawn UNKNOWN -

Nuget pack csproj using nuspec -

c# - Display ASPX Popup control in RowDeleteing Event (ASPX Gridview) -