Skip to content

Conversation

@yarglawaldeg
Copy link
Contributor

update structured_edge_detection to read models from updated p. dollar toolbox

This pullrequest changes

current version returns blurry edge map with "new" models from updated p. dollar toolbox
the solution can be to set sharpen parameter from the models to 0 and update the structured_edge_detection.cpp file as suggested here : http://answers.opencv.org/question/72962/trained-model-for-opencv-structured-edge-detection/?answer=95989#post-id-95989

update structured_edge_detection to read models from updated p. dollar toolbox
@bommo1
Copy link

bommo1 commented Mar 16, 2018

related #1282 #1559

Copy link
Contributor Author

@yarglawaldeg yarglawaldeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removing trailing whitespaces

int finish = __rf.edgeBoundaries[currentNode + 1];
size_t sizeBoundaries = __rf.edgeBoundaries.size();
int convertedBoundaries = static_cast<int>(sizeBoundaries);
int nBnds = (convertedBoundaries - 1) / (nTreesNodes * nTrees);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like nBnds is a constant for these loops (so it should be moved out).

Does "((convertedBoundaries - 1) % (nTreesNodes * nTrees)) == 0" always (remainder == 0)?
Or should we calculate original expression exactly (multiplication at first): currentNode * (convertedBoundaries - 1) / (nTreesNodes * nTrees)?

@vpisarev
Copy link
Contributor

👍

@vpisarev vpisarev merged commit 4ea11a0 into opencv:master Jun 25, 2018
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.

4 participants