Skip to content

Commit a129120

Browse files
authored
[GPU] Update condition of NMSIEInternal op convert callback in transformation for legacy static models (#30458)
### Details: - Update condition of NMSIEInternal op convert callback in transformation for legacy static models - Some models have performance regression when allow_new_shape_infer is changed to true by PR#30043. This PR fixes it. ### Tickets: - 166611 - 166613 - 167154
1 parent b85136f commit a129120

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/plugins/intel_gpu/src/plugin/transformations_pipeline.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -834,8 +834,9 @@ void TransformationsPipeline::apply(std::shared_ptr<ov::Model> func) {
834834

835835
pass_config->set_callback<ov::pass::ConvertNMS9ToNMSIEInternal>(
836836
[&](const_node_ptr &node) -> bool {
837-
// Convert to NMSIEInternal when model is static
838-
return !func->is_dynamic() ? false : true;
837+
// Convert to NMSIEInternal when input shape is static
838+
// Otherwise keep NMS op
839+
return !node->get_input_partial_shape(0).is_dynamic() ? false : true;
839840
});
840841

841842
// List of enabled/disabled transformations

0 commit comments

Comments
 (0)