Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A bug when cropping images? #11

Open
yosider opened this issue Jul 21, 2020 · 0 comments
Open

A bug when cropping images? #11

yosider opened this issue Jul 21, 2020 · 0 comments

Comments

@yosider
Copy link

yosider commented Jul 21, 2020

Hi, thank you for your great research!
I'm afraid I think there is a bug at the random_crop function in utils.py:

curl/utils.py

Lines 244 to 245 in 23b0880

w1 = np.random.randint(0, crop_max, n)
h1 = np.random.randint(0, crop_max, n)

I think the crop_max should be modified as crop_max + 1.
If left as it is, the bottom and rightmost columns of the image are not included in cropped_image. Also, an error occurs when output_size==img_size.
I'm sorry if I'm wrong :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant