mirror of
https://github.com/opencv/opencv.git
synced 2025-01-18 22:44:02 +08:00
Merge pull request #19529 from WeiChungChang:3.4
* improve map allocation check * fix accoring to CR
This commit is contained in:
parent
34d5746553
commit
d4d12164aa
@ -852,16 +852,16 @@ public:
|
||||
for (int i = 0; i < num; ++i, locData += numPredsPerClass * numLocClasses * 4)
|
||||
{
|
||||
LabelBBox& labelBBox = locPreds[i];
|
||||
int start = shareLocation ? -1 : 0;
|
||||
for (int c = 0; c < numLocClasses; ++c) {
|
||||
labelBBox[start++].resize(numPredsPerClass);
|
||||
}
|
||||
for (int p = 0; p < numPredsPerClass; ++p)
|
||||
{
|
||||
int startIdx = p * numLocClasses * 4;
|
||||
for (int c = 0; c < numLocClasses; ++c)
|
||||
{
|
||||
int label = shareLocation ? -1 : c;
|
||||
if (labelBBox.find(label) == labelBBox.end())
|
||||
{
|
||||
labelBBox[label].resize(numPredsPerClass);
|
||||
}
|
||||
util::NormalizedBBox& bbox = labelBBox[label][p];
|
||||
if (locPredTransposed)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user