Skip to content

fix API cv::dnn::net::getLayerInputs#15064

Closed
dgerin wants to merge 1 commit intoopencv:masterfrom
dgerin:master
Closed

fix API cv::dnn::net::getLayerInputs#15064
dgerin wants to merge 1 commit intoopencv:masterfrom
dgerin:master

Conversation

@dgerin
Copy link
Copy Markdown
Contributor

@dgerin dgerin commented Jul 16, 2019

This pullrequest changes

@dkurt
Copy link
Copy Markdown
Member

dkurt commented Jul 17, 2019

Hi! Thanks for the path.

Can you please provide incorrect case? In example, using dumpToFile.

@dgerin
Copy link
Copy Markdown
Contributor Author

dgerin commented Jul 17, 2019

@dkurt
Copy link
Copy Markdown
Member

dkurt commented Jul 17, 2019

@Dimitri1, Which layer is a problematic one?

@dgerin
Copy link
Copy Markdown
Contributor Author

dgerin commented Jul 17, 2019

Hi, the issue is that getLayerInputs method returns 0 size vector (no input) on opencv master.
Maybe I missed a step of initialization or something, but my patch fix directly the issue.

Here is my test sequence:

// build net from .onnx
datas_->net_ = cv::dnn::readNetFromONNX(datas_->modelFilename_);
std::vectorcv::String layerNames = datas_->net_.getLayerNames();
for (int il = 0; il < layerNames.size(); il++) {
cv::String layerName = layerNames[il];
int layerId = datas_->net_.getLayerId(layerName);
std::vector<cv::Ptrcv::dnn::Layer> layerInputs = datas_->net_.getLayerInputs(layerId);
}
Here layerInputs is empty with opencv master getLayerInputs !

@dgerin dgerin force-pushed the master branch 2 times, most recently from 9b5e1e2 to 6e16196 Compare September 24, 2019 09:39
@dkurt
Copy link
Copy Markdown
Member

dkurt commented Sep 30, 2019

@Dimitri1, Please check the changes in this PR. can we review again initial version?

You may reopen it with new branch with different name from master.

@asmorkalov
Copy link
Copy Markdown
Contributor

@Dimitri1 A loot of fixes has been merged to DNN module and merge conflict appears. Please re-base you branch and fix it.

@dgerin dgerin closed this Oct 24, 2019
@dgerin
Copy link
Copy Markdown
Contributor Author

dgerin commented Oct 24, 2019

ignore this pull request

@dkurt dkurt mentioned this pull request Nov 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants