[GNA] Set performance mode to undefined (#10174)

This commit is contained in:
Nadezhda Ageeva
2022-02-07 23:04:29 +03:00
committed by GitHub
parent 65701e12ef
commit 2215440188
3 changed files with 8 additions and 2 deletions

View File

@@ -51,7 +51,7 @@ struct Config {
std::vector<std::string> GetSupportedKeys() const;
static const InferenceEngine::Parameter GetSupportedProperties(bool compiled = false);
ov::hint::PerformanceMode performance_mode = ov::hint::PerformanceMode::LATENCY;
ov::hint::PerformanceMode performance_mode = ov::hint::PerformanceMode::UNDEFINED;
// default precision of GNA hardware model (see QuantI16 quantizer struct)
ov::element::Type inference_precision = ov::element::undefined;

View File

@@ -102,6 +102,9 @@ TEST(OVClassBasicTest, smoke_SetConfigAfterCreatedPrecisionHint) {
ov::Core core;
ov::element::Type precision;
ASSERT_NO_THROW(precision = core.get_property("GNA", ov::hint::inference_precision));
ASSERT_EQ(ov::element::undefined, precision);
ASSERT_NO_THROW(core.set_property("GNA", ov::hint::inference_precision(ov::element::i8)));
ASSERT_NO_THROW(precision = core.get_property("GNA", ov::hint::inference_precision));
ASSERT_EQ(ov::element::i8, precision);
@@ -129,6 +132,9 @@ TEST(OVClassBasicTest, smoke_SetConfigAfterCreatedPerformanceHint) {
ov::Core core;
ov::hint::PerformanceMode mode;
ASSERT_NO_THROW(mode = core.get_property("GNA", ov::hint::performance_mode));
ASSERT_EQ(ov::hint::PerformanceMode::UNDEFINED, mode);
ASSERT_NO_THROW(core.set_property("GNA", ov::hint::performance_mode(ov::hint::PerformanceMode::LATENCY)));
ASSERT_NO_THROW(mode = core.get_property("GNA", ov::hint::performance_mode));
ASSERT_EQ(ov::hint::PerformanceMode::LATENCY, mode);

View File

@@ -29,7 +29,7 @@ const std::map<std::string, std::string> supportedConfigKeysWithDefaults = {
{GNA_CONFIG_KEY(LIB_N_THREADS), "1"},
{CONFIG_KEY(SINGLE_THREAD), CONFIG_VALUE(YES)},
{CONFIG_KEY(LOG_LEVEL), PluginConfigParams::LOG_NONE},
{CONFIG_KEY(PERFORMANCE_HINT), CONFIG_VALUE(LATENCY)},
{CONFIG_KEY(PERFORMANCE_HINT), ""},
{CONFIG_KEY(PERFORMANCE_HINT_NUM_REQUESTS), "1"}
};
IE_SUPPRESS_DEPRECATED_END