classify.py stuck in defining input_scale and raw_scale

22 views
Skip to first unread message

Saman Sarraf

unread,
Apr 21, 2016, 5:47:47 PM4/21/16
to Caffe Users
Dear caffe users,

I'm kind of got stuck in defining classify.py parameters and I am getting arbitrary results / predictions from this interface. 
I trained LeNet (exactly the same network of MNIST data) for 57 classes (instead of 10) and got Test net output #0: accuracy = 0.928275. I assume this is the accuracy of testing samples. I am using classify.py against the same testing samples and I am getting very arbitrary predictions. 

I attached my solver and network model. The only thing I need to mention is the scaling factor "scale: 0.00390625" in the model. So my question is how to set raw_scale and input_scale ? Also image_size is cropping images or rescaling images? because my testing samples are 32*32 but I trained LeNet bu 28*28. and the last thing , as I am not subtracting the mean of images during training, I don't need to subtract it in prediction , correct?

Honestly, I have tried everything mentioned above and still get the bizarre predictions, just wanted to double check if they are correct or not ? there should be definitely something wrong that I don't get the correct predictions.   

Your prompt help is much appreciated,
Saman



lenet_solver_online_data_01.prototxt
lenet_train_test_online_data_01.prototxt

Saman Sarraf

unread,
Apr 26, 2016, 7:17:24 PM4/26/16
to Caffe Users
Hey folks, 

Thanks for your help. 

The problem was in doing normalization twice first in deploy.prototext and second in classsify.py command line.

Best.
Saman 
Reply all
Reply to author
Forward
0 new messages