Skip to content

Commit

Permalink
dnn: fix additional text boxes handling after the latest adaptations …
Browse files Browse the repository at this point in the history
…for TF
  • Loading branch information
sovrasov committed Oct 11, 2017
1 parent 050916f commit f7175f5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions modules/dnn/src/layers/prior_box_layer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -254,10 +254,11 @@ class PriorBoxLayerImpl : public PriorBoxLayer
CV_TRACE_FUNCTION();
CV_TRACE_ARG_VALUE(name, "name", name.c_str());

size_t real_numPriors = _additional_y_offset ? _numPriors / 2 : _numPriors;
if (_scales.empty())
_scales.resize(_numPriors, 1.0f);
_scales.resize(real_numPriors, 1.0f);
else
CV_Assert(_scales.size() == _numPriors);
CV_Assert(_scales.size() == real_numPriors);

int _layerWidth = inputs[0]->size[3];
int _layerHeight = inputs[0]->size[2];
Expand Down

0 comments on commit f7175f5

Please sign in to comment.