根据内核信息选择engine = CAFFE或CUDNN

时间:2017-04-10 13:22:11

标签: machine-learning deep-learning caffe

我的网络结构为

Input (5x5)-->Deconv1(kernel=6,stride=6, pad=0)

我尝试了两种设置:

layer {
  name: "Deconvolution1"
  type: "Deconvolution"
  bottom: "input"
  top: "Deconvolution1"
  convolution_param {
    num_output: 128
    kernel_size: 6
    pad: 1
    stride: 6
    engine: CUDNN
    weight_filler {
      type: "gaussian"
      std: 0.01
    }
  }
}

通过上述设置,caffe有错误。但是,如果我设置engine=CAFFE,它将起作用。我认为CUDNN仅对输入起作用是偶数(即2,4,6,8,10...)。我对吗?

这是错误

I0411 11:43:04.186025  9383 net.cpp:400] Deconvolution1 -> Deconvolution1
*** Aborted at 1491878584 (unix time) try "date -d @1491878584" if you are using GNU date ***
PC: @     0x7fc8d2b3df44 (unknown)
*** SIGFPE (@0x7fc8d2b3df44) received by PID 9383 (TID 0x7fc8e2374a40) from PID 18446744072949587780; stack trace: ***
    @     0x7fc8dfda4cb0 (unknown)
    @     0x7fc8d2b3df44 (unknown)
    @     0x7fc8d299786f (unknown)
    @     0x7fc8e1663374 caffe::CuDNNDeconvolutionLayer<>::Reshape()
    @     0x7fc8e15808c4 caffe::Net<>::Init()
    @     0x7fc8e1581fe8 caffe::Net<>::Net()
    @     0x7fc8e158a742 caffe::Solver<>::InitTrainNet()
    @     0x7fc8e158bad8 caffe::Solver<>::Init()
    @     0x7fc8e158be4a caffe::Solver<>::Solver()
    @     0x7fc8e15bbf93 caffe::Creator_AdamSolver<>()
    @           0x40901a train()
    @           0x405ec8 main
    @     0x7fc8dfd8ff45 (unknown)
    @           0x4065f3 (unknown)
    @                0x0 (unknown)
Floating point exception (core dumped)

0 个答案:

没有答案