Skip to content

Commit

Permalink
Merge pull request opencv#13906 from dkurt:fix_tf_ssd_min_size
Browse files Browse the repository at this point in the history
  • Loading branch information
alalek committed Feb 25, 2019
2 parents f6d3adc + fe7c93c commit 0aa0f2a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions samples/dnn/tf_text_graph_ssd.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ def get(self, layer_id):

widths += [sqrt(self.scales[layer_id] * self.scales[layer_id + 1])]
heights += [sqrt(self.scales[layer_id] * self.scales[layer_id + 1])]
widths = [w * self.image_width for w in widths]
heights = [h * self.image_height for h in heights]
min_size = min(self.image_width, self.image_height)
widths = [w * min_size for w in widths]
heights = [h * min_size for h in heights]
return widths, heights


Expand Down

0 comments on commit 0aa0f2a

Please sign in to comment.