[GPU] Fixed device name in query network result (#13915)
This commit is contained in:
committed by
GitHub
parent
2faddf61bf
commit
e78a9e93c2
@@ -440,7 +440,7 @@ QueryNetworkResult Plugin::QueryNetwork(const CNNNetwork& network,
|
||||
});
|
||||
|
||||
for (auto&& layerName : supported) {
|
||||
res.supportedLayersMap.emplace(layerName, GetName());
|
||||
res.supportedLayersMap.emplace(layerName, GetName() + "." + conf.device_id);
|
||||
}
|
||||
|
||||
return res;
|
||||
|
||||
@@ -115,6 +115,15 @@ void LayerTestsCommon::QueryNetwork() {
|
||||
|
||||
std::set<std::string> actual;
|
||||
for (auto&& res : queryNetworkResult.supportedLayersMap) {
|
||||
std::shared_ptr<InferenceEngine::RemoteContext> ctx = nullptr;
|
||||
try {
|
||||
// Try to take fully specified name from the context to match it with query network result for devices that support remote contexts
|
||||
ctx = core->GetDefaultContext(targetDevice);
|
||||
ASSERT_EQ(res.second, ctx->getDeviceName());
|
||||
} catch (...) {
|
||||
// otherwise, compare with originally used device name
|
||||
ASSERT_EQ(res.second, targetDevice);
|
||||
}
|
||||
actual.insert(res.first);
|
||||
}
|
||||
ASSERT_EQ(expected, actual);
|
||||
|
||||
Reference in New Issue
Block a user