Skip to content

Commit

Permalink
Update ApiTraits, as it causes issues with Serialization.
Browse files Browse the repository at this point in the history
  • Loading branch information
Sheil Kumar committed Jul 20, 2024
1 parent 7e6297b commit 75c3d40
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,9 @@ DML_OPERATOR_TYPE ApiTraits::StringifyHelpers::FromString(std::string_view value
{"DML_OPERATOR_MULTIHEAD_ATTENTION1", DML_OPERATOR_MULTIHEAD_ATTENTION1},
{"DML_OPERATOR_QUANTIZE", DML_OPERATOR_QUANTIZE},
{"DML_OPERATOR_DEQUANTIZE", DML_OPERATOR_DEQUANTIZE},
{"DML_OPERATOR_ROI_ALIGN_GRAD", DML_OPERATOR_ROI_ALIGN_GRAD},
{"DML_OPERATOR_FOLD", DML_OPERATOR_FOLD},
{"DML_OPERATOR_UNFOLD", DML_OPERATOR_UNFOLD},
};
auto index = StringUtil::MapToIndex(value, mapping);
if (!index)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ struct EnumTraits<DML_TENSOR_TYPE>
template <>
struct EnumTraits<DML_OPERATOR_TYPE>
{
static constexpr auto ValueCount = 175;
static constexpr auto ValueCount = 178;
static constexpr size_t ActivationFunctionCount = 26;
};

Expand Down Expand Up @@ -2922,6 +2922,9 @@ inline gsl::czstring ToString(DML_OPERATOR_TYPE value)
case DML_OPERATOR_MULTIHEAD_ATTENTION1: return "DML_OPERATOR_MULTIHEAD_ATTENTION1";
case DML_OPERATOR_QUANTIZE: return "DML_OPERATOR_QUANTIZE";
case DML_OPERATOR_DEQUANTIZE: return "DML_OPERATOR_DEQUANTIZE";
case DML_OPERATOR_ROI_ALIGN_GRAD: return "DML_OPERATOR_ROI_ALIGN_GRAD";
case DML_OPERATOR_FOLD: return "DML_OPERATOR_FOLD";
case DML_OPERATOR_UNFOLD: return "DML_OPERATOR_UNFOLD";
default:
assert(false);
return "<unknown>";
Expand Down

0 comments on commit 75c3d40

Please sign in to comment.