Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Good First Issue]: [OP CONFORMANCE][TEMPLATE] One Multiply test in failed in confomance over template #22753

Open
iefode opened this issue Feb 9, 2024 · 11 comments
Assignees
Labels
category: TEMPLATE OpenVINO Template plugin conformance good first issue Good for newcomers no_stale Do not mark as stale

Comments

@iefode
Copy link
Contributor

iefode commented Feb 9, 2024

Context

OP conformance suite is validation tool checks a plugin conditions from operation implementation status perspective.
OP conformance is based on extracted from OMZ model scope operations and graphs by ov_subgraphs_dumper tool. Extracted graphs are saved as IR (OpenVINO Intermediate representation) and is stored in the public share.
OP conformance suite contains the following test types:

  • OpImplCheck validates operation support by plugin. Return true or false.
  • Inference compare device inference results vs reference over extracted IR as a model. We generate synthetic tensors to get a result. Possible results are passed, failed, hanged (interrupted by timeout), crashed and skipped (just in case -shape_mode is misaligned with graph inputs).
  • QueryModel check possibility of graph execution per device. Have the same status as Inference
  • ImportExport exports compiled model, imports it and check that models are same. Have the same status as Inference

Template is a simple plugin run inference using reference implementation. It means if we will run conformance over template, we should compare TEMPLATE vs TEMPLATE results. Sometimes we have bugs inside the plugin, reference implementation or test infrastructure leads to negative test result.

What needs to be done?

Description:
conformance_Multiply/ReadIRTest.Inference/Op=Multiply.1_Type=f32_Shape=dynamic_IR=287a7562757ef0295cc38442e3d775cff0fb1ea9b27e6897bd456f01ce82d455_Device=TEMPLATE_Config=() is failed.

How to reproduce:

  1. Build the OV using -DENABLE_TESTS=ON -DENABLE_FUNACTIONAL_TESTS=ON
  2. Build ov_op_conformance_tests target
  3. Run OP conformance to download conformance IRs and run executable file with args:
python3 /openvino/src/tests/test_utils/functional_test_utils/layer_tests_summary/run_conformance.py -d=TEMPLATE --gtest_filter="conformance_Multiply/ReadIRTest.Inference/Op=Multiply.1_Type=f32_Shape=dynamic_IR=287a7562757ef0295cc38442e3d775cff0fb1ea9b27e6897bd456f01ce82d455_Device=TEMPLATE_Config=()"

NOTE: run_conformance log contains all commands to run ov_op_conformance_tests! You can take them to debug!

  1. Check the logs inside working directory and get the results:
[ RUN      ] conformance_Multiply/ReadIRTest.Inference/Op=Multiply.1_Type=f32_Shape=dynamic_IR=287a7562757ef0295cc38442e3d775cff0fb1ea9b27e6897bd456f01ce82d455_Device=TEMPLATE_Config=()

MEM_USAGE=55352KB
[ CONFORMANCE ] Influence coefficient: 2.89071e-06
[ PLUGIN      ] `SubgraphBaseTest::compile_model()` is started
[ PLUGIN      ] `SubgraphBaseTest::compile_model()` is finished successfully. Duration is 0.00832317s
[ PLUGIN      ] `SubgraphBaseTest::get_plugin_outputs()` is started
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is started
[ REFERENCE   ] Calculate reference in runtime
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is started
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is finished successfully. Duration is 0.00406761s
[ PLUGIN      ] `SubgraphBaseTest::get_plugin_outputs()` is finished successfully. Duration is 0.00915385s
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is finished successfully. Duration is 0.0157838s
[ COMPARATION ] `ov_tensor_utils.hpp::compare()` is started
[ COMPARATION ] rel_threshold: 0.639893
[ COMPARATION ] abs_threshold: 0.639893
[ COMPARATION ] `ov_tensor_utils.hpp::compare()` is finished successfully. Duration is 0.00117577s
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is started
[ REFERENCE   ] Calculate reference in runtime
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is started
[ PLUGIN      ] `SubgraphBaseTest::get_plugin_outputs()` is started
[ PLUGIN      ] `SubgraphBaseTest::get_plugin_outputs()` is finished successfully. Duration is 15.895s
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is finished successfully. Duration is 16.7522s
[ REFERENCE   ] `SubgraphBaseTest::calculate_refs()` is finished successfully. Duration is 16.8706s
[ COMPARATION ] `ov_tensor_utils.hpp::compare()` is started
[ COMPARATION ] rel_threshold: 0.601611
[ COMPARATION ] abs_threshold: 0.601611
[ COMPARATION ] `ov_tensor_utils.hpp::compare()` is finished successfully. Duration is 13.7659s
src/tests/functional/shared_test_classes/src/base/ov_subgraph.cpp:96: Failure
Exception from src/core/src/runtime/allocator.cpp:69:
std::bad_alloc

[  FAILED  ] conformance_Multiply/ReadIRTest.Inference/Op=Multiply.1_Type=f32_Shape=dynamic_IR=287a7562757ef0295cc38442e3d775cff0fb1ea9b27e6897bd456f01ce82d455_Device=TEMPLATE_Config=(), where GetParam() = (("/home/efode/repo/openvino/src/tests/test_utils/functional_test_utils/layer_tests_summary/temp/template_conformance/models/2023.3.0-13657-d5b0f4d2d73/operation/dynamic/Multiply-1/f32/287a7562757ef0295cc38442e3d775cff0fb1ea9b27e6897bd456f01ce82d455.xml", ""), "TEMPLATE", {}) (39759 ms)
  1. To debug the test in C++ Use the following command (just an example, refer to note in third item):
openvino/bin/intel64/Release/ov_op_conformance_tests --device=TEMPLATE --input_folders=openvino/src/tests/test_utils/functional_test_utils/layer_tests_summary/temp/models/conformance_ir_files.lst, --report_unique_name --output_folder="openvino/src/tests/test_utils/functional_test_utils/layer_tests_summary/temp/report/parallel" --gtest_filter="conformance_Multiply/ReadIRTest.Inference/Op=Multiply.1_Type=f32_Shape=dynamic_IR=287a7562757ef0295cc38442e3d775cff0fb1ea9b27e6897bd456f01ce82d455_Device=TEMPLATE_Config=()" --config_path="" --shape_mode=

Expected result:
Passed status for mentioned test.

Example Pull Requests

No response

Resources

Contact points

@iefode

Ticket

No response

@iefode iefode added good first issue Good for newcomers category: TEMPLATE OpenVINO Template plugin conformance no_stale Do not mark as stale labels Feb 9, 2024
@iefode iefode changed the title [Good First Issue]: [CONFORMANCE][TEMPLATE] [Good First Issue]: [OP CONFORMANCE][TEMPLATE] Feb 9, 2024
@iefode iefode changed the title [Good First Issue]: [OP CONFORMANCE][TEMPLATE] [Good First Issue]: [OP CONFORMANCE][TEMPLATE] One Multiply test in failed in confomance over template Feb 9, 2024
@awayzjj
Copy link
Contributor

awayzjj commented Feb 28, 2024

.take

Copy link
Contributor

Thank you for looking into this issue! Please let us know if you have any questions or require any help.

@awayzjj awayzjj removed their assignment Mar 8, 2024
@YutingGao7
Copy link

.take

Copy link
Contributor

Thank you for looking into this issue! Please let us know if you have any questions or require any help.

@p-wysocki
Copy link
Contributor

Hello @YutingGao7, are you still working on this?

@iefode
Copy link
Contributor Author

iefode commented Apr 25, 2024

Hello @YutingGao7!

What is the status of the issue? Please, let us know in case of any issues

We will unassign the ticket from you in case of inaction

@Vladislav-Denisov
Copy link
Contributor

.take

Copy link
Contributor

Thank you for looking into this issue! Please let us know if you have any questions or require any help.

@Vladislav-Denisov
Copy link
Contributor

@iefode I've done some research and I'm sharing the results with you:

When executing a loop

for (const auto& targetStaticShapeVec : targetStaticShapes) {
generate_inputs(targetStaticShapeVec);
validate();
}

Iterations for targetStaticShapes[0] and targetStaticShapes[1] are successful.
However, when calling generate_inputs() for targetStaticShapes[2] a "bad allocation" exception occurs.

The error occurs when allocating memory for the tensor [127,512,127,127,64].

I think it is necessary to change the logic of Shape generation to solve the problem.
The generate() function


must according to the principle of "taking into account the available memory capacity when generating Shape".

@mlukasze
Copy link
Contributor

@iefode your feedback please

@iefode
Copy link
Contributor Author

iefode commented Aug 8, 2024

@mlukasze Thanks for notification!

@Vladislav-Denisov Many thanks for investigation! Looks like we should fix shape generate() method. It looks absolutely ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: TEMPLATE OpenVINO Template plugin conformance good first issue Good for newcomers no_stale Do not mark as stale
Projects
Status: Assigned
Development

No branches or pull requests

6 participants