caffe

What does Caffe Train/Test net output mean?

若如初见. 提交于 2019-12-12 13:07:40
问题 When training in Caffe, there are Train and Test net outputs for each iteration. I know this is the loss. However, is this the average loss over my batch or the total loss? And is this the same for both Classification and Regression? For example, if I were to have a batch of 100 training examples and my loss over that iteration is 100, does that mean that the average loss per example is 1? 回答1: Train loss is the averaged loss over the last training batch. That means that if you have 100

Caffe HDF5 pixel-wise classification

最后都变了- 提交于 2019-12-12 11:18:01
问题 I am trying to implement a pixel-wise binary classification for images using caffe. For each image having dimension 3x256x256, I have a 256x256 label array in which each entry is marked as either 0 or 1. Also, when I read my HDF5 file using the below code, dirname = "examples/hdf5_classification/data" f = h5py.File(os.path.join(dirname, 'train.h5'), "r") ks = f.keys() data = np.array(f[ks[0]]) label = np.array(f[ks[1]]) print "Data dimension from HDF5", np.shape(data) print "Label dimension

Caffe network getting very low loss but very bad accuracy in testing

拟墨画扇 提交于 2019-12-12 10:06:07
问题 I'm somewhat new to caffe, and I'm getting some strange behavior. I'm trying to use fine tuning on the bvlc_reference_caffenet to accomplish an OCR task. I've taken their pretrained net, changed the last FC layer to the number of output classes that I have, and retrained. After a few thousand iterations I'm getting loss rates of ~.001, and an accuracy over 90 percent when the network tests. That said, when I try to run my network on data by myself, I get awful results, not exceeding 7 or 8

Setting input layer in CAFFE with C++

喜欢而已 提交于 2019-12-12 09:49:22
问题 I'm writing C++ code using CAFFE to predict a single (for now) image. The image has already been preprocessed and is in .png format. I have created a Net object and read in the trained model. Now, I need to use the .png image as an input layer and call net.Forward() - but can someone help me figure out how to set the input layer? I found a few examples on the web, but none of them work, and almost all of them use deprecated functionality. According to: Berkeley's Net API, using

caffe:AttributeError: 'module' object has no attribute 'LabelMap'

廉价感情. 提交于 2019-12-12 09:28:11
问题 The caffe is installed on the Ubuntu server,and it test is ok. I just run the following code on the Ubutun(16.04) cloud server: import caffe from caffe.proto import caffe_pb2 label_map = caffe_pb2.LabelMap() and I have run the command as following which provided by the internet, but there is still error: command: export PYTHONPATH=$/home2/challenge98/caffe/python:$PYTHONPATH error: Traceback (most recent call last): File "<stdin>", line 1, in <module> AttributeError: 'module' object has no

Prediction in Caffe - Exception: Input blob arguments do not match net inputs

谁说我不能喝 提交于 2019-12-12 07:47:11
问题 I'm using Caffe for classifying non-image data using a quite simple CNN structure. I've had no problems training my network on my HDF5-data with dimensions n x 1 x 156 x 12. However, I'm having difficulties classifying new data. How do I do a simple forward pass without any preprocessing? My data has been normalized and have correct dimensions for Caffe (it's already been used to train the net). Below is my code and the CNN structure. EDIT: I've isolated the problem to the function '_Net

How to run pretrained models of Pixel Objectness

浪尽此生 提交于 2019-12-12 06:47:17
问题 I can't run pretrained models of Pixel Objectness published by Suyog Dutt Jain et al in 2017. I referred section Using the pretrained models in README.md on GitHub, but couldn't understand the following procedures well. ・Setup: Download and install Deeplab-v1 from here ・Refer to demo.py for step-by-step instruction on how to run the code. I tryed to install and run "demo.py", but I got some errors. Though I referred solutions on Website, unsolvable error remained. /usr/bin/python2.7 /mnt/C6BF

Caffe error: no field named “net”

孤街醉人 提交于 2019-12-12 06:14:26
问题 I had the Caffe C++ example program working on my computer, but after recently recompiling Caffe, I've encountered this error when I try to run the program: [libprotobuf ERROR google/protobuf/text_format.cc:245] Error parsing text-format caffe.NetParameter: 2:4: Message type "caffe.NetParameter" has no field named "net". upgrade_proto.cpp:928] Check failed: ReadProtoFromTextFile(param_file, param) Failed to parse NetParameter file: /home/jack/Desktop/beeshiny/deploy.prototxt Am I missing

Cmake error at Windows download Prebuilt Dependencies.cmake:54 file Download hash mismatch

不想你离开。 提交于 2019-12-12 04:35:17
问题 I'm trying to install Caffe for windows 8. I'm using this article for installation guide, I installed visual studio 2015. I put python.exe & CMAKE.exe on the path & after running these errors occured. I appreciate any help. 回答1: After searching my question,I understood maybe the problem is about "time out" in network connection or another problem about downloading. I removed the complete binary output build directory, again. I used "freegate.exe" and tried again. cmd>cd caffe cmd>caffe

How to predict float vector labels with caffe?

元气小坏坏 提交于 2019-12-12 04:23:39
问题 I was wondering if it's possible to predict a 1-by-n feature associated to an input image using caffe. In this post there is a solution to make caffe predict a binary vector such as [1 0 1 0]. Is this solution also suitable if I have a 1-by-n float vector as label (such as [0.2, 0.1, 0.3, 0.4] ? I want to predict such a vector, not a binary vector label. 回答1: You can also think about this MultiTaskData Layer. It can parse float typed label vector as you mentioned in your question. 回答2: Yes; I