Revert "[CPU] Set lower bound for nstreams to 1 (#8747)" (#8924)

This reverts commit 251883001c.
This commit is contained in:
Gorokhov Dmitriy 2021-12-01 09:24:55 +03:00 committed by GitHub
parent 232aadf518
commit 7879839a56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -588,15 +588,13 @@ Engine::LoadExeNetworkImpl(const InferenceEngine::CNNNetwork &network, const std
// network is below general threshold
num_streams = std::max(default_num_streams, num_streams_less_aggressive);
}
int ovPerfHintNumRequests = engConfig.perfHintsConfig.ovPerfHintNumRequests; // set thru SetConfig to the plugin
auto num_requests = config.find(PluginConfigParams::KEY_PERFORMANCE_HINT_NUM_REQUESTS);
if (num_requests != config.end()) {
// arrived with config to the LoadNetwork (and thus higher pri)
ovPerfHintNumRequests = PerfHintsConfig::CheckPerformanceHintRequestValue(num_requests->second);
}
num_streams = std::min(num_streams, std::max(ovPerfHintNumRequests, 1));
if (engConfig.perfHintsConfig.ovPerfHintNumRequests) // set thru SetConfig to the plugin
num_streams = std::min(engConfig.perfHintsConfig.ovPerfHintNumRequests,
engConfig.perfHintsConfig.ovPerfHintNumRequests);
if (num_requests != config.end()) // arrived with config to the LoadNetwork (and thus higher pri)
num_streams = std::min(num_streams,
PerfHintsConfig::CheckPerformanceHintRequestValue(num_requests->second));
config[PluginConfigParams::KEY_CPU_THROUGHPUT_STREAMS] = std::to_string(num_streams);
}
}