Skip to content

Commit

Permalink
use assign
Browse files Browse the repository at this point in the history
  • Loading branch information
Sheil Kumar committed Jul 19, 2024
1 parent 20a1a65 commit 7e6297b
Showing 1 changed file with 4 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,7 @@ namespace OperatorHelper
{
ML_CHECK_VALID_ARGUMENT(outputShape[C] == gsl::narrow_cast<int>(m_outputShapes[0].GetShape()[C]),
"Output channel must be equivalent to filter channel.");
}
}

for (size_t i = 0; i < m_kernel.spatialDimensionCount; ++i)
{
Expand Down Expand Up @@ -1857,12 +1857,9 @@ namespace OperatorHelper
DowncastDimensions(gsl::span(shapeData), /*out*/ m_blockShape);

const uint32_t dimCount = gsl::narrow_cast<uint32_t>(m_blockShape.size());
m_dilations.resize(dimCount);
std::fill(m_dilations.begin(), m_dilations.end(), 1);
m_pads.resize(dimCount, 0);
std::fill(m_pads.begin(), m_pads.end(), 0);
m_strides.resize(dimCount, 1);
std::fill(m_strides.begin(), m_strides.end(), 1);
m_dilations.assign(dimCount, 1);
m_pads.assign(dimCount, 0);
m_strides.assign(dimCount, 1);

if (kernelInformation.HasAttribute(AttrName::Dilations, MLOperatorAttributeType::IntArray))
{
Expand Down

0 comments on commit 7e6297b

Please sign in to comment.