Check groups attribute existence in convolution op ONNX export.
This commit is contained in:
Родитель
2b326401c0
Коммит
f2192a145c
|
@ -3198,7 +3198,7 @@ void CNTKToONNXHelper::CopyAttributes(const FunctionPtr& src, ONNXIR::Node* node
|
|||
auto autoPadding = AsVector<bool>(src->Attributes()[L"autoPadding"].Value<std::vector<DictionaryValue>>());
|
||||
auto dilations = (NDShape)src->Attributes()[L"dilation"].Value<NDShape>();
|
||||
auto transpose = (bool)src->Attributes()[L"transpose"].Value<bool>();
|
||||
auto groups = (size_t)src->Attributes()[L"groups"].Value<size_t>();
|
||||
size_t groups = (src->Attributes().Contains(L"groups")) ? (size_t)src->Attributes()[L"groups"].Value<size_t>() : 1u;
|
||||
|
||||
//
|
||||
// Remove the channel part for ONNX. This is because ONNX, unlike CNTK, does
|
||||
|
|
Загрузка…
Ссылка в новой задаче