Skip to content

Commit

Permalink
Refactor variadic_split shape infer namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
mitruska committed Nov 28, 2024
1 parent 63f1e00 commit e8cca16
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@

namespace ov {
namespace op {
namespace v1 {

namespace variadic_split {
template <typename T, class TRShape = result_shape_t<T>>
std::vector<TRShape> shape_infer(const Node* op,
Expand Down Expand Up @@ -123,11 +121,12 @@ std::vector<TRShape> shape_infer(const Node* op,
}
} // namespace variadic_split

namespace v1 {
template <typename T, class TRShape = result_shape_t<T>>
std::vector<TRShape> shape_infer(const VariadicSplit* op,
const std::vector<T>& input_shapes,
const ITensorAccessor& ta = make_tensor_accessor()) {
return variadic_split::shape_infer(op, input_shapes, ta);
return op::variadic_split::shape_infer(op, input_shapes, ta);
}

} // namespace v1
Expand Down
10 changes: 4 additions & 6 deletions src/core/src/op/variadic_split.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ bool VariadicSplit::evaluate(TensorVector& outputs, const TensorVector& inputs)
++out_partial_shape;
}

return op::variadic_split::evaluate(outputs, inputs);
return variadic_split::evaluate(outputs, inputs);
} else {
return false;
}
Expand All @@ -112,18 +112,16 @@ bool VariadicSplit::has_evaluate() const {

bool VariadicSplit::evaluate_lower(TensorVector& output_values) const {
OV_OP_SCOPE(v1_Split_evaluate_lower);
return op::variadic_split::has_axis_and_splits_bound_set(this) &&
default_lower_bound_evaluator(this, output_values);
return variadic_split::has_axis_and_splits_bound_set(this) && default_lower_bound_evaluator(this, output_values);
}

bool VariadicSplit::evaluate_upper(TensorVector& output_values) const {
OV_OP_SCOPE(v1_Split_evaluate_upper);
return op::variadic_split::has_axis_and_splits_bound_set(this) &&
default_upper_bound_evaluator(this, output_values);
return variadic_split::has_axis_and_splits_bound_set(this) && default_upper_bound_evaluator(this, output_values);
}

bool VariadicSplit::evaluate_symbol(TensorSymbolVector& output_symbols) const {
return op::variadic_split::has_axis_and_splits_bound_set(this) &&
return variadic_split::has_axis_and_splits_bound_set(this) &&
ov::util::default_symbol_evaluator(this, output_symbols);
}
} // namespace v1
Expand Down

0 comments on commit e8cca16

Please sign in to comment.