What is accuracy actually measuring here?

21 views
Skip to first unread message

Matthew Smith

unread,
Aug 10, 2016, 7:14:24 PM8/10/16
to Caffe Users
I'm new to Caffe and have been playing around with the MNSIT example.  It's a fairly simple network and most of it makes sense.  However, I can't quite figure out what the accuracy layer is measuring during the test phase.  The accuracy layer is taking input from the labels and an inner product layer.  But as far as I can tell, the inner product layer will produce unbounded activations that don't directly mean anything.  Therefore, I would have expected the accuracy layer to take input from a softmax layer and the labels which would compute an accuracy based on probability of classification.

Can anyone help me understand what is going on here with the accuracy layer?  Is my intuition about measuring accuracy with inputs from a softmax layer also correct?

The last layers of the .prototxt file:

...redacted...

layer
{
  name
: "ip2"
  type
: "InnerProduct"
  bottom
: "ip1"
  top
: "ip2"
  param
{
    lr_mult
: 1
 
}
  param
{
    lr_mult
: 2
 
}
  inner_product_param
{
    num_output
: 10
    weight_filler
{
      type
: "xavier"
   
}
    bias_filler
{
      type
: "constant"
   
}
 
}
}
layer
{
  name
: "accuracy"
  type
: "Accuracy"
  bottom
: "ip2"
  bottom
: "label"
  top
: "accuracy"
  include
{
    phase
: TEST
 
}
}
layer
{
  name
: "loss"
  type
: "SoftmaxWithLoss"
  bottom
: "ip2"
  bottom
: "label"
  top
: "loss"
}

Thanks!
Reply all
Reply to author
Forward
0 new messages