tagan icon indicating copy to clipboard operation
tagan copied to clipboard

code changes required for image size 256.

Open abhinav3 opened this issue 5 years ago • 4 comments

Hi, I wanted to run the code for images of size 256 as input instead of 128. I see that image size 128 is hardcoded in "train.py" while transforming into tensors.

Is there any other place across the code where I need to change the image size (or other parameters dependent on image size) to run it on 256 size input image.

Should I raise a PR for the same where I can ask for the image size as run time argument? Thanks, Abhinav

abhinav3 avatar Mar 11 '19 07:03 abhinav3

@abhinav3 You need to change hard-coded numbers in model.py (defining network), train.py, and test.py (preprocessing data). Yes, it will be great if you do so. Thanks!

woozzu avatar Mar 11 '19 07:03 woozzu

@abhinav3 Do you have an open PR for this?

shubhamagarwal92 avatar Jun 21 '19 22:06 shubhamagarwal92

@woozzu What do you suggest should be an ideal way to take images of size 256/224? Should we just reshape the image to 128 or is the code generalized enough to take arbitrary image size if we just remove the hard coding?

shubhamagarwal92 avatar Jun 24 '19 23:06 shubhamagarwal92

@shubhamagarwal92 You can simply change the hard-coded numbers. Everything works fine, but you may want to add more residual blocks or down/upsampling to enlarge a receptive field.

woozzu avatar Jun 25 '19 01:06 woozzu