Merged PR 4954300: Enable preliminary 8D support in DirectML EP

- Update TensorDesc maximum dimension count to 8.
- Update OneHot kernel dimension range.

Related work items: #27678579
This commit is contained in:
Dwayne Robinson 2020-07-22 20:51:03 +00:00
parent 0b5117958a
commit 3b53be001b
3 changed files with 5 additions and 5 deletions

View file

@ -10,7 +10,7 @@ namespace Dml
{
using namespace OperatorHelper;
static const int MaximumDimensionCount = DML_TENSOR_DIMENSION_COUNT_MAX;
static const int MaximumDimensionCount = DML_TENSOR_DIMENSION_COUNT_MAX1;
DML_TENSOR_DATA_TYPE GetDmlDataTypeFromMlDataType(MLOperatorTensorDataType tensorDataType);
DML_TENSOR_DATA_TYPE GetDmlDataTypeFromMlDataTypeNoThrow(MLOperatorTensorDataType tensorDataType) noexcept;

View file

@ -37,7 +37,7 @@ public:
TensorAxis::DoNotCoerce,
TensorAxis::W,
TensorAxis::RightAligned,
NchwDimensionCount, // minDimensionCount
1, // minDimensionCount
0
);
@ -49,10 +49,12 @@ public:
TensorAxis::DoNotCoerce,
TensorAxis::W,
TensorAxis::RightAligned,
NchwDimensionCount, // minDimensionCount
1, // minDimensionCount
0
);
DmlOperator::Remap64bitDmlDataTypesTo32bitIfNeeded();
// Adjust the axis so it's in DML's terms rather than the original ONNX indexing.
uint32_t dmlAxis = GetDmlAdjustedAxis(
m_absoluteAxis,

View file

@ -59,8 +59,6 @@ namespace Dml
DML_BUFFER_TENSOR_DESC m_bufferTensorDesc = {};
};
class TensorDescBuilder
{
public: