From 894e312d30177ab53848385edd6293120f66c11d Mon Sep 17 00:00:00 2001 From: TFBunny Date: Thu, 21 Jan 2021 11:05:36 -0500 Subject: [PATCH] fix biasadd data format --- mindspore/core/abstract/prim_nn.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mindspore/core/abstract/prim_nn.cc b/mindspore/core/abstract/prim_nn.cc index e2cd0be0b58..aae14eabede 100644 --- a/mindspore/core/abstract/prim_nn.cc +++ b/mindspore/core/abstract/prim_nn.cc @@ -530,7 +530,7 @@ AbstractBasePtr InferImplBiasAdd(const AnalysisEnginePtr &, const PrimitivePtr & ShapeVector x_min_shape = x->shape()->min_shape(); ShapeVector x_max_shape = x->shape()->max_shape(); std::set available_data_format{"NCHW", "NHWC"}; - auto data_format_ptr = primitive->GetAttr("data_format"); + auto data_format_ptr = primitive->GetAttr("format"); std::string data_format = "NCHW"; if ((data_format_ptr != nullptr) && data_format_ptr->isa()) { data_format = data_format_ptr->cast()->value();