Skip to content

Commit 1d682f3

Browse files
authored
Update where.cpp
Signed-off-by: Maxim Vafin <maxim.vafin@intel.com>
1 parent 72d3f44 commit 1d682f3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/frontends/pytorch/src/op/where.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ OutputVector translate_where(const NodeContext& context) {
2727
const auto& cond_shape = cond.get_partial_shape();
2828
PYTORCH_OP_CONVERSION_CHECK(cond_shape.rank().is_static(),
2929
"aten::where(cond) with input of dynamic rank is not supported");
30-
const auto ndim = static_cast<int>(cond_shape.rank().get_length());
30+
const auto ndim = cond_shape.rank().get_length();
3131
auto non_zero = context.mark_node(std::make_shared<v3::NonZero>(cond));
3232
auto axis = context.mark_node(v0::Constant::create(element::i32, Shape{}, {0}));
3333
OutputVector result;
3434
if (ndim > 0) {
3535
auto split = context.mark_node(std::make_shared<v1::Split>(non_zero, axis, ndim));
36-
for (int i = 0; i < ndim; ++i) {
36+
for (size_t i = 0; i < ndim; ++i) {
3737
result.push_back(context.mark_node(std::make_shared<v0::Squeeze>(split->output(i), axis)));
3838
}
3939
}

0 commit comments

Comments
 (0)