mirror of
https://github.com/opencv/opencv.git
synced 2026-07-29 23:33:05 +04:00
Fix IE backend considering future changes.
This commit is contained in:
@@ -448,11 +448,12 @@ public:
|
||||
const int outNum = blobs[0].size[0];
|
||||
ieLayer.setOutputNum(outNum);
|
||||
|
||||
ieLayer.setWeights(wrapToInfEngineBlob(blobs[0], {(size_t)blobs[0].size[0], (size_t)blobs[0].size[1], 1, 1}, InferenceEngine::Layout::OIHW));
|
||||
InferenceEngine::Builder::Layer l = ieLayer;
|
||||
addConstantData("weights", wrapToInfEngineBlob(blobs[0], {(size_t)blobs[0].size[0], (size_t)blobs[0].size[1], 1, 1}, InferenceEngine::Layout::OIHW), l);
|
||||
if (blobs.size() > 1)
|
||||
ieLayer.setBiases(wrapToInfEngineBlob(blobs[1], {(size_t)outNum}, InferenceEngine::Layout::C));
|
||||
addConstantData("biases", wrapToInfEngineBlob(blobs[1], {(size_t)outNum}, InferenceEngine::Layout::C), l);
|
||||
|
||||
return Ptr<BackendNode>(new InfEngineBackendNode(ieLayer));
|
||||
return Ptr<BackendNode>(new InfEngineBackendNode(l));
|
||||
#else
|
||||
InferenceEngine::LayerParams lp;
|
||||
lp.name = name;
|
||||
|
||||
Reference in New Issue
Block a user