Skip to content

Commit

Permalink
Follow up for PR #3784 (#3821)
Browse files Browse the repository at this point in the history
  • Loading branch information
ilya-lavrenov authored Jan 13, 2021
1 parent b452991 commit b203e9e
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ class InferRequestInternal : virtual public IInferRequestInternal {
addInputPreProcessingFor(name, userBlob, devBlob ? devBlob : _inputs[name]);
} else {
size_t inputSize = foundInput->getTensorDesc().getLayout() != InferenceEngine::Layout::SCALAR
? InferenceEngine::details::product(foundInput->getTensorDesc().getDims())
: 1;
? InferenceEngine::details::product(foundInput->getTensorDesc().getDims())
: 1;
if (dataSize != inputSize) {
THROW_IE_EXCEPTION << "Input blob size is not equal network input size (" << dataSize
<< "!=" << inputSize << ").";
Expand All @@ -124,7 +124,9 @@ class InferRequestInternal : virtual public IInferRequestInternal {
THROW_IE_EXCEPTION << NOT_IMPLEMENTED_str
<< "cannot set compound blob: supported only for input pre-processing";
}
size_t outputSize = details::product(foundOutput->getDims());
size_t outputSize = foundOutput->getTensorDesc().getLayout() != InferenceEngine::Layout::SCALAR
? details::product(foundOutput->getTensorDesc().getDims()) :
1;
if (dataSize != outputSize) {
THROW_IE_EXCEPTION << "Output blob size is not equal network output size (" << dataSize
<< "!=" << outputSize << ").";
Expand Down

0 comments on commit b203e9e

Please sign in to comment.