Data augmentation does not improve network accuracy

58 views
Skip to first unread message

Ali

unread,
May 31, 2016, 10:45:57 AM5/31/16
to Caffe Users
Hi,

At the moment, I am using Alexnet to do a classification task.

The size of each input sample is 480*680.

Using a normal network, fed by cropped inputs of size 256*256 (generated in preprocessing steps) with the batch size of 8, gives me the accuracy rate of 92%.

But, when I  try to generate 5 crops of each (480*680) sample (corners plus a center crop) using the following crop layers:

# this is the reference blob of the cropping process which determines cropping size
layer {
  name: "reference-blob"
  type: "Input"
  top: "reference"
  input_param { shape: { dim: 8 dim: 3 dim: 227 dim: 227 } }
}
# upper-left crop
layer{
name: "crop-1"
type: "Crop"
bottom: "data"
bottom: "reference"
top: "crop-1"
crop_param {
axis: 2
offset: 1
offset: 1
}
}
# upper-right crop
layer{
name: "crop-2"
type: "Crop"
bottom: "data"
bottom: "reference"
top: "crop-2"
crop_param {
axis: 2
offset: 1
offset: 412
}
}
# lower-left crop
layer{
name: "crop-3"
type: "Crop"
bottom: "data"
bottom: "reference"
top: "crop-3"
crop_param {
axis: 2
offset: 252
offset: 1
}
}
# lower-right crop
layer{
name: "crop-4"
type: "Crop"
bottom: "data"
bottom: "reference"
top: "crop-4"
crop_param {
axis: 2
offset: 252
offset: 412
}
}
# center crop
layer{
name: "crop-5"
type: "Crop"
bottom: "data"
bottom: "reference"
top: "crop-5"
crop_param {
axis: 2
offset: 127
offset: 207
}
}
# concat all the crop results to feed the next layer
layer{
name: "crop_concat"
type: "Concat"
bottom: "crop-1"
bottom: "crop-2"
bottom: "crop-3"
bottom: "crop-4"
bottom: "crop-5"
top: "all_crops"
concat_param {
    axis: 0
}
}
# generating enough labels for all the crop results
layer{
name: "label_concat"
type: "Concat"
bottom: "label"
bottom: "label"
bottom: "label"
bottom: "label"
bottom: "label"
top: "all-labels"
concat_param {
    axis: 0
}
}

leads to accuracy rate of 90.6% which is strange.

Do you see any mistake in that?

Reply all
Reply to author
Forward
0 new messages