Adding model domain to ONNX model export.
This commit is contained in:
Родитель
5d92880a21
Коммит
2b326401c0
|
@ -410,7 +410,8 @@ std::unique_ptr<ONNXIR::Model> CNTKToONNX::CreateModel(const FunctionPtr& src)
|
|||
if (!status.IsOK())
|
||||
LogicError("%s", status.ErrorMessage().c_str());
|
||||
|
||||
model->SetModelversion(static_cast<ONNXIR::Version>(CNTK_ONNX_MODEL_VERSION)); // This is the default. Should be surfaced as graph's 'save' API input.
|
||||
model->SetModelversion(static_cast<ONNXIR::Version>(CNTK_ONNX_MODEL_VERSION)); // REVIEW sptiwari: This is the default. This and doc_string should be surfaced as graph's 'save' API input.
|
||||
model->SetDomain(CNTK_ONNX_MODEL_DOMAIN);
|
||||
model->SetProducerVersion(CNTK_ONNX_PRODUCER_VERSION);
|
||||
model->SetProducerName(CNTK_ONNX_PRODUCER_NAME);
|
||||
return model;
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
#define CNTK_ONNX_MODEL_VERSION 1
|
||||
#define MACRO_TO_STRING(s) #s
|
||||
const std::string CNTK_ONNX_PRODUCER_NAME = "CNTK";
|
||||
const std::string CNTK_ONNX_MODEL_DOMAIN = "ai.cntk";
|
||||
#ifdef _WIN32
|
||||
const std::string CNTK_ONNX_PRODUCER_VERSION = CNTK_VERSION;
|
||||
#else
|
||||
|
|
Загрузка…
Ссылка в новой задаче