diff options
Diffstat (limited to 'nn/common/operations/ExpandDims.cpp')
-rw-r--r-- | nn/common/operations/ExpandDims.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nn/common/operations/ExpandDims.cpp b/nn/common/operations/ExpandDims.cpp index 6503407bd..573a467e5 100644 --- a/nn/common/operations/ExpandDims.cpp +++ b/nn/common/operations/ExpandDims.cpp @@ -23,7 +23,7 @@ namespace nn { namespace expand_dims { bool prepare(const Shape& input, int32_t axis, Shape* output) { - axis = getDimensionIndex(getNumberOfDimensions(input) + 1, axis); + NN_CHECK(handleNegativeAxis(getNumberOfDimensions(input) + 1, &axis)); output->type = input.type; output->offset = input.offset; |