Browse Source

!14882 fix lenet

From: @zhujingxuan
Reviewed-by: @wangchengyuan,@zhang_xue_tong
Signed-off-by: @wangchengyuan
pull/14882/MERGE
mindspore-ci-bot Gitee 4 years ago
parent
commit
9c3f46a624
2 changed files with 3 additions and 2 deletions
  1. +1
    -0
      mindspore/lite/micro/cmake/file_list.cmake
  2. +2
    -2
      mindspore/lite/micro/coder/opcoders/nnacl/fp32/convolution_winograd_fp32_coder.cc

+ 1
- 0
mindspore/lite/micro/cmake/file_list.cmake View File

@@ -173,6 +173,7 @@ set(LITE_SRC
${LITE_DIR}/src/ops/populate/strided_slice_populate.cc ${LITE_DIR}/src/ops/populate/strided_slice_populate.cc
${LITE_DIR}/src/ops/populate/lstm_populate.cc ${LITE_DIR}/src/ops/populate/lstm_populate.cc
${LITE_DIR}/src/ops/populate/squeeze_populate.cc ${LITE_DIR}/src/ops/populate/squeeze_populate.cc
${LITE_DIR}/src/ops/populate/transpose_populate.cc
### tools ### tools
${LITE_DIR}/tools/common/flag_parser.cc ${LITE_DIR}/tools/common/flag_parser.cc
) )


+ 2
- 2
mindspore/lite/micro/coder/opcoders/nnacl/fp32/convolution_winograd_fp32_coder.cc View File

@@ -162,9 +162,9 @@ int ConvolutionWinogradFP32Coder::InitWeightBias() {
if (input_tensors_.size() == kInputSize2) { if (input_tensors_.size() == kInputSize2) {
auto ori_bias_addr = reinterpret_cast<float *>(bias_tensor_->data_c()); auto ori_bias_addr = reinterpret_cast<float *>(bias_tensor_->data_c());
MS_CHECK_RET_CODE(memcpy_s(new_bias_, new_bias_ele_size, ori_bias_addr, out_channel_size * sizeof(float)), MS_CHECK_RET_CODE(memcpy_s(new_bias_, new_bias_ele_size, ori_bias_addr, out_channel_size * sizeof(float)),
"memset_s failed!");
"memcpy_s failed!");
} else { } else {
return RET_ERROR;
MS_CHECK_RET_CODE(memset_s(new_bias_, new_bias_ele_size, 0, new_bias_ele_size), "memset_s failed!");
} }
return RET_OK; return RET_OK;
} }


Loading…
Cancel
Save