caffe icon indicating copy to clipboard operation
caffe copied to clipboard

Error: compute_image_mean: mdv_env_open failed

Open gpulkitg opened this issue 12 years ago • 2 comments

Hey all I am new to caffe and want to use it to classify White Blood Cell images and find out the cancerous cells. I have created the train and val lmdb data with create_sgt.sh (identical to create_imagenet.sh) (sgt is the name of my project). However, running make_sgt_mean.sh (identical to make_imagenet_mean.sh) after creating the lmdb data throws this error:

[root@pulkit caffe]# ./examples/sgt/make_sgt_mean.sh F1118 10:32:01.052323 12342 compute_image_mean.cpp:50] Check failed: mdb_env_open(mdb_env, argv[1], 0x20000, 0664) == 0 (2 vs. 0) mdb_env_open failed *** Check failure stack trace: *** @ 0x7ffc73bcaa5d google::LogMessage::Fail() @ 0x7ffc73bceef7 google::LogMessage::SendToLog() @ 0x7ffc73bccd59 google::LogMessage::Flush() @ 0x7ffc73bcd05d google::LogMessageFatal::~LogMessageFatal() @ 0x412e06 main @ 0x390901ed5d (unknown) @ 0x411ba9 (unknown) ./examples/sgt/make_sgt_mean.sh: line 6: 12342 Aborted (core dumped) ./build/tools/compute_image_mean /examples/sgt/sgt_train_leveldb /data/sgt/sgt_mean.binaryproto Done.

I am executing all commands from the CAFFE_ROOT directory. I also replaced the compute_image_mean by the latest stable version from github, but in vain. I have been searching the internet for possible solutions to this problem, but it seems there are no concrete solutions. Does anybody know what is the issue here? (I am using CentOS 6.5)

gpulkitg avatar Nov 18 '14 01:11 gpulkitg

Did you actually mean examples/sgt/sgt_train_leveldb instead of /examples/sgt/sgt_train_leveldb and data/sgt/sgt_mean.binaryproto instead of /data/sgt/sgt_mean.binaryproto?

kmatzen avatar Nov 18 '14 15:11 kmatzen

Yes. Sorry I posted the wrong path. Even with the path examples/sgt/sgt_train_leveldb, there was an issue. The problem was that 'create_sgt.sh' was creating a folder named 'sgt_train_lmdb', but the make_sgt_mean.sh was trying to import data from 'sgt_train_leveldb'. Minor issue in the code for ImageNet, but I checked and edited my file acordingly. It is resolved now. Thanks a lot anyway! :)

gpulkitg avatar Nov 19 '14 00:11 gpulkitg