BVLC / caffe

Caffe: a fast open framework for deep learning.
http://caffe.berkeleyvision.org/
Other
34.12k stars 18.69k forks source link

Read Caffe Features to a txt file for further analysis #2043

Closed kilickaya closed 9 years ago

kilickaya commented 9 years ago

Hi everyone,

I'm using tools/extract_features.cpp to extract features of a set of images in my dataset. Caffe extracts and saves features in leveldb format.

However I conduct most of my analysis on Matlab, so I try to read extracted features to a txt file where each row corresponds to the features of a single image.

I use simple iterator examples provided on leveldb's website, and iterate through all keys and values stored in the database, and printing them to a text file. But at the end I get these strange characters in my text file:

untitled

I read that leveldb stores data in BYTE array format, but if this is the case, I do not know how to convert this format to a human consumable format (i.e: floating point values like 0.3 0.788 etc)

Thanks in advance for your help and support!

mauriciolp commented 9 years ago

I am having the same issue here, for me it is not clear how to convert the DB information to human consumable format.

As an workaround, I intend to perform the feature extraction with python, based on the Filter Visuzalization tutorial and python/classify.py script.

longjon commented 9 years ago

Please ask usage questions on the caffe-users list. Thanks!

Dev2022 commented 8 years ago

I also have the same problem. Can you please let me know if you have got the answer.Thanks

kilickaya commented 8 years ago

Sadly, I do not have any improvements over this.

didpurwanto commented 8 years ago

I have a problem too, same with this. Anyone know? Thanks