CVS-174486: [OV EP] Followup: Add tests for dynamic shapes and for empty initializers#956
CVS-174486: [OV EP] Followup: Add tests for dynamic shapes and for empty initializers#956intbf wants to merge 3 commits intointel:ovep-developfrom
Conversation
Introduce OVEP_ExtInit_DynamicEmbed_Tests to verify >2GB external weights handling and expected protobuf exception. Add OVEP_ExtInit_EmptyRawData_Tests to check correct backend behavior with empty raw_data initializers.
There was a problem hiding this comment.
Pull request overview
This PR adds two new test fixture classes and corresponding test cases to openvino_ep_ext_init.cc to improve coverage of the OpenVINO EP's external initializer handling:
-
OVEP_ExtInit_DynamicEmbed_Tests: Tests that creating a session with a model that has dynamic shapes and >2GB external weights (9 × 256MB = ~2.25GB) throws anOrt::Exception, since the OV EP must embed the weights into the protobuf which then exceeds protobuf's 2GB limit. -
OVEP_ExtInit_EmptyRawData_Tests: Tests that a model containing emptyraw_datainitializers (like empty tensors used as Resize inputs) is correctly handled by the OpenVINO EP backend, without crashing or producing incorrect output.
Changes:
- Introduces
OVEP_ExtInit_DynamicEmbed_Testsfixture withSetUpTestSuite/TearDownTestSuiteand a test verifying thatOrt::Exceptionis thrown for >2GB weight embedding - Introduces
OVEP_ExtInit_EmptyRawData_Testsfixture withSetUpTestSuite/TearDownTestSuiteand a test verifying correct inference output when emptyraw_datainitializers are present - Registers both new parameterized test suites for CPU, GPU, and NPU device variants
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Clean up comments. Refactor dynamic embed test to use local weights data, removing static member for better memory management. Add missing session config entry for consistency. Reformat exception test and increment offset in external data loop.
Introduce OVEP_ExtInit_DynamicEmbed_Tests to verify >2GB external weights handling and expected protobuf exception. Add OVEP_ExtInit_EmptyRawData_Tests to check correct backend behavior with empty raw_data initializers.
Relates to: https://jira.devtools.intel.com/browse/CVS-174486