Skip to content

Commit

Permalink
[CPU][ARM] Fix inference precision for behaviour tests (openvinotoolk…
Browse files Browse the repository at this point in the history
  • Loading branch information
alvoron authored Aug 30, 2023
1 parent e8f1df4 commit 9b10ef6
Showing 1 changed file with 1 addition and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -156,11 +156,7 @@ TEST_F(OVClassConfigTestCPU, smoke_PluginSetConfigAffinity) {
TEST_F(OVClassConfigTestCPU, smoke_PluginSetConfigHintInferencePrecision) {
ov::Core ie;
auto value = ov::element::f32;
#if defined(OV_CPU_ARM_ENABLE_FP16)
const auto precision = ov::element::f16;
#else
const auto precision = InferenceEngine::with_cpu_x86_bfloat16() ? ov::element::bf16 : ov::element::f32;
#endif

ASSERT_NO_THROW(value = ie.get_property("CPU", ov::hint::inference_precision));
ASSERT_EQ(precision, value);
Expand Down Expand Up @@ -194,11 +190,7 @@ TEST_F(OVClassConfigTestCPU, smoke_PluginSetConfigEnableProfiling) {
ASSERT_EQ(enableProfiling, value);
}

#if defined(OV_CPU_ARM_ENABLE_FP16)
const auto expected_precision_for_performance_mode = ov::element::f16;
#else
const auto expected_precision_for_performance_mode = InferenceEngine::with_cpu_x86_bfloat16() ? ov::element::bf16 : ov::element::f32;
#endif
const auto expected_precision_for_performance_mode = InferenceEngine::with_cpu_x86_bfloat16() ? ov::element::bf16 : ov::element::f32;

const auto bf16_if_can_be_emulated = InferenceEngine::with_cpu_x86_avx512_core() ? ov::element::bf16 : ov::element::f32;
using ExpectedModeAndType = std::pair<ov::hint::ExecutionMode, ov::element::Type>;
Expand Down

0 comments on commit 9b10ef6

Please sign in to comment.