Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

leveldb iterator is invalid #4

Open
yalesong opened this issue Jul 21, 2016 · 5 comments
Open

leveldb iterator is invalid #4

yalesong opened this issue Jul 21, 2016 · 5 comments

Comments

@yalesong
Copy link

Running an experiment with reutersidf10k dataset via python dec.py reutersidf10k fails with an error

I0721 18:03:54.192920 24690 net.cpp:67] Creating Layer data
I0721 18:03:54.192975 24690 net.cpp:358] data -> data
I0721 18:03:54.193002 24690 net.cpp:96] Setting up data
I0721 18:03:54.193032 24690 data_layer.cpp:45] Opening leveldb reutersidf10k_total
python: db_iter.cc:68: virtual leveldb::Slice leveldb::<unnamed>::DBIter::value() const: Assertion `valid_' failed.

The same error occurs with the mnist and the reutersidf datasets. I haven't tried with the stl dataset.

I compiled the Caffe library provided in this repo, downloaded the dataset, and ran python make_reuters_data.py as given in the instruction.

The error happens when iter_->value() is called in: https://github.com/piiswrong/dec/blob/master/caffe/src/caffe/layers/data_layer.cpp#L122

It seems https://github.com/piiswrong/dec/blob/master/caffe/src/caffe/layers/data_layer.cpp#L53 creates an invalid iterator; putting a line CHECK(iter->Valid()) immediately after it fails.

My leveldb version is 1.0.7

@lipond
Copy link

lipond commented Sep 25, 2016

@yalesong did you solve this problem? I am being bewildered with it.

@yalesong
Copy link
Author

@lipond No I haven't. Are you getting the same problem?

@hkrds1996
Copy link

When python dec.py mnist, do you have the error : AttributeError: type object 'Net' has no attribute 'set_phase_train'

@yalesong
Copy link
Author

yalesong commented Nov 3, 2016

@Hukangrong It appears that you are importing the official, public version of the CAFFE library. This repo contains a modified version of CAFFE and you would have to compile & import that one instead.

@hkrds1996
Copy link

@yalesong Thank you for your reply. Compiling it need much time. I would change the author code rather than build it again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants