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

about training image size format #22

Open
BENHSU0723 opened this issue Aug 8, 2021 · 1 comment
Open

about training image size format #22

BENHSU0723 opened this issue Aug 8, 2021 · 1 comment

Comments

@BENHSU0723
Copy link

BENHSU0723 commented Aug 8, 2021

Accroding to previous issue before and setting of IN_OUT_RATIO = 4 and IN_SIDE = 640 , so i think that the training image format shound as same as ICDAR2015, right? because i have trained with some image with different size, then i got this error

File "C:\Users\VMlab\Desktop\text-detection-fots.pytorch-master\datasets.py", line 76, in transform
   torch.randint(low=0, high=(stretched.shape[0] // IN_OUT_RATIO) - OUT_SIDE, size=(1,), dtype=torch.int16).item())
RuntimeError: random_ expects 'from' to be less than 'to', but got from=0 >= to=-3

thanks for your reply @Wovchena

@Wovchena
Copy link
Owner

Wovchena commented Aug 8, 2021

Correct. The error on high=(stretched.shape[0] // IN_OUT_RATIO) - OUT_SIDE suggests that stretched.shape[0] can't be smaller than OUT_SIDE.

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

2 participants