Skip to content

Commit

Permalink
Corrected bug in maintain aspect ratio always being true
Browse files Browse the repository at this point in the history
  • Loading branch information
titu1994 committed Jan 27, 2017
1 parent 764a63c commit 6a2fcec
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion INetwork.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def preprocess_image(image_path, load_dims=False, read_mode="color"):
aspect_ratio = float(img_HEIGHT) / img_WIDTH

img_width = args.img_size
if args.maintain_aspect_ratio:
if maintain_aspect_ratio:
img_height = int(img_width * aspect_ratio)
else:
img_height = args.img_size
Expand Down
2 changes: 1 addition & 1 deletion Network.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def preprocess_image(image_path, load_dims=False, read_mode="color"):
aspect_ratio = float(img_HEIGHT) / img_WIDTH

img_width = args.img_size
if args.maintain_aspect_ratio:
if maintain_aspect_ratio:
img_height = int(img_width * aspect_ratio)
else:
img_height = args.img_size
Expand Down
2 changes: 1 addition & 1 deletion script_helper/Script/INetwork.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def preprocess_image(image_path, load_dims=False, read_mode="color"):
aspect_ratio = float(img_HEIGHT) / img_WIDTH

img_width = args.img_size
if args.maintain_aspect_ratio:
if maintain_aspect_ratio:
img_height = int(img_width * aspect_ratio)
else:
img_height = args.img_size
Expand Down
2 changes: 1 addition & 1 deletion script_helper/Script/Network.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def preprocess_image(image_path, load_dims=False, read_mode="color"):
aspect_ratio = float(img_HEIGHT) / img_WIDTH

img_width = args.img_size
if args.maintain_aspect_ratio:
if maintain_aspect_ratio:
img_height = int(img_width * aspect_ratio)
else:
img_height = args.img_size
Expand Down

0 comments on commit 6a2fcec

Please sign in to comment.