rezafuad / vehicle-color-recognition

GNU General Public License v3.0
27 stars 4 forks source link

how to run the code #1

Open EvergreenHZ opened 6 years ago

EvergreenHZ commented 6 years ago

Hi, I try to recognize the color of vehicles, but I don't know how to use your code.

rezafuad commented 6 years ago

Hi,

I use Caffe deep learning framework, so you need to install the framework before running the code.

You can try the image classification tutorial at this link: http://nbviewer.jupyter.org/github/BVLC/caffe/blob/master/examples/00-classification.ipynb

Make sure that you change the deploy.prototxt, bvlc_reference_caffenet.caffemodel, and ilsvrc_2012_mean.npy to the one that provided in this github.

You can also use the file python/classify.py provided with Caffe deep learning framework.

vedmed85 commented 5 years ago

Hi! I tried to use python/classify.py as you wrote in previews answer python classify.py --input_file 'w.jpeg' --output_file 'out.jpg' --model_def 'vcolor_deploy02.prototxt' --pretrained_model 'vcolor_train02_RGB_t01_iter_250000.caffemodel' --mean_file 'vcolor-mean.npy' i got result [[ 5.50239626e-03 2.13468790e-01 1.98935071e-04 1.01572834e-03 7.73842275e-01 3.69509868e-03 1.73119758e-03 5.45500428e-04]] I expected as result id of color, or maybe i did something wrong?

huunhan312 commented 5 years ago

@vedmed85 the outputs are the probability of all output classes.