This repository contains a Caffe implementation of the paper Drop an Octave: Reducing Spatial Redundancy in Convolutional Neural Networks with Octave Convolution.
Provide octaveupsample layer to support octave convolution.
Forward:
Backward:
Here is a performance on the scene classification task of resnet18 in AI Challenger.The experiment in GTX1080Ti*2, batchsize=128, did not use any data augmentation without mirror, and did not load the pre-training model.
More other models are coming soon.
Modify caffe.proto like this:
Add option in LayerParameter.
message LayerParameter {
optional OctaveUpsampleParameter octaveupsample_param = Your last ID;
}
Add message at the end.
message OctaveUpsampleParameter {
// DEPRECATED. No need to specify upsampling scale factors when
// exact output shape is given by upsample_h, upsample_w parameters.
optional uint32 scale = 1 [default = 2];
// DEPRECATED. No need to specify upsampling scale factors when
// exact output shape is given by upsample_h, upsample_w parameters.
optional uint32 scale_h = 2;
// DEPRECATED. No need to specify upsampling scale factors when
// exact output shape is given by upsample_h, upsample_w parameters.
optional uint32 scale_w = 3;
// DEPRECATED. Specify exact output height using upsample_h. This
// parameter only works when scale is 2
optional bool pad_out_h = 4 [default = false];
// DEPRECATED. Specify exact output width using upsample_w. This
// parameter only works when scale is 2
optional bool pad_out_w = 5 [default = false];
optional uint32 upsample_h = 6;
optional uint32 upsample_w = 7;
}
Reference OctaveUpsample layer in resnet18_octave_0.5_train.prototxt.
1.Caffe:pooling layer
2.caffe-segnet-cudnn5:upsample layer
3.OctaveConv_pytorch
4.OctaveConv