[VPU] - I64 issue with ONNX models - fix (#9978)
i32 or i64 is used for index_element_type. So it is more convenient to get rid of the condition and stay only with the i32 option. Tickets: 75748 75747 75029
This commit is contained in:
parent
298cced3b3
commit
a3f2a4ef99
@ -56,6 +56,7 @@ void dynamicToStaticShapeTopK(std::shared_ptr<ngraph::Node> target) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
std::shared_ptr<ngraph::Node> new_topk;
|
std::shared_ptr<ngraph::Node> new_topk;
|
||||||
|
|
||||||
if (ngraph::is_type<ngraph::opset3::Constant>(target->get_input_node_shared_ptr(1)))
|
if (ngraph::is_type<ngraph::opset3::Constant>(target->get_input_node_shared_ptr(1)))
|
||||||
new_topk = target->clone_with_new_inputs(target->input_values());
|
new_topk = target->clone_with_new_inputs(target->input_values());
|
||||||
else
|
else
|
||||||
@ -65,7 +66,7 @@ void dynamicToStaticShapeTopK(std::shared_ptr<ngraph::Node> target) {
|
|||||||
topk->get_provided_axis(),
|
topk->get_provided_axis(),
|
||||||
topk->get_mode(),
|
topk->get_mode(),
|
||||||
topk->get_sort_type(),
|
topk->get_sort_type(),
|
||||||
topk->get_index_element_type());
|
ngraph::element::i32);
|
||||||
|
|
||||||
for (auto &output : target->outputs()) {
|
for (auto &output : target->outputs()) {
|
||||||
const auto outDSR = std::make_shared<ngraph::vpu::op::DynamicShapeResolver>(new_topk->output(output.get_index()), output_shape);
|
const auto outDSR = std::make_shared<ngraph::vpu::op::DynamicShapeResolver>(new_topk->output(output.get_index()), output_shape);
|
||||||
|
Loading…
Reference in New Issue
Block a user