Skip to content

Commit

Permalink
Merge pull request #53 from alexzhangxx/small_change
Browse files Browse the repository at this point in the history
adjusting coordinate
  • Loading branch information
mystic123 authored Dec 14, 2018
2 parents f41178b + 1b56de7 commit ed60b90
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ def letter_box_image(image: Image.Image, output_height: int, output_width: int,
to_return = np.tile(fill_value, (output_height, output_width, 1))
pad_top = int(0.5 * (output_height - fit_height))
pad_left = int(0.5 * (output_width - fit_width))
to_return[pad_top:pad_top+fit_height, pad_left:+fit_width] = fit_image
to_return[pad_top:pad_top+fit_height, pad_left:pad_left+fit_width] = fit_image
return to_return


Expand Down

0 comments on commit ed60b90

Please sign in to comment.