Skip to content

Commit

Permalink
[train] fix padding_value type (#14206)
Browse files Browse the repository at this point in the history
This commit fixes type of padding value match with declaration.

ONE-DCO-1.0-Signed-off-by: JuYoung Lee [email protected]
  • Loading branch information
icodo98 authored Oct 15, 2024
1 parent 4a319d0 commit e12da49
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions runtime/onert/backend/train/ops/PoolLayer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -134,10 +134,10 @@ class AveragePool2D final : public TrainingKernelRegistry
_op_params.stride_width = strideWidth;
_op_params.filter_height = kernelHeight;
_op_params.filter_width = kernelWidth;
assert(paddingTop < (1 << 8));
assert(paddingLeft < (1 << 8));
_op_params.padding_values.height = static_cast<uint8_t>(paddingTop);
_op_params.padding_values.width = static_cast<uint8_t>(paddingLeft);
assert(paddingTop < (1 << 15));
assert(paddingLeft < (1 << 15));
_op_params.padding_values.height = static_cast<int16_t>(paddingTop);
_op_params.padding_values.width = static_cast<int16_t>(paddingLeft);
CalculateActivationRange<float>(activation, &_op_params.float_activation_min,
&_op_params.float_activation_max);
}
Expand Down

0 comments on commit e12da49

Please sign in to comment.