|
|
@@ -573,11 +573,15 @@ bool CheckDynamicImageSizeShape(const vector<int64_t> &shape, const string &data |
|
|
|
if (input_format == "NCHW") { |
|
|
|
height = shape[NCHW_DIM_H]; |
|
|
|
width = shape[NCHW_DIM_W]; |
|
|
|
} |
|
|
|
|
|
|
|
if (input_format == "NHWC") { |
|
|
|
} else if (input_format == "NHWC") { |
|
|
|
height = shape[NHWC_DIM_H]; |
|
|
|
width = shape[NHWC_DIM_W]; |
|
|
|
} else { |
|
|
|
ErrorManager::GetInstance().ATCReportErrMessage("E10001", {"parameter", "value", "reason"}, {"--input_format", |
|
|
|
input_format, "only support nchw and nhwc!"}); |
|
|
|
GELOGE(ge::PARAM_INVALID, "Invalid value for %s[%s], %s", "--input_format", input_format.c_str(), |
|
|
|
"only support nchw and nhwc!"); |
|
|
|
return false; |
|
|
|
} |
|
|
|
|
|
|
|
if (height == kDynmaicDims && width == kDynmaicDims && |
|
|
|