princewang1994 / TextSnake.pytorch

A PyTorch implementation of ECCV2018 Paper: TextSnake: A Flexible Representation for Detecting Text of Arbitrary Shapes
https://arxiv.org/abs/1807.01544
MIT License
437 stars 92 forks source link

Why find bottom and side line before transform? #23

Closed ghost closed 5 years ago

ghost commented 5 years ago

https://github.com/princewang1994/TextSnake.pytorch/blob/6e890ef75a0f9e82b7dfe6ea4c4200ad2664840d/dataset/dataload.py#L151

After transform, polygons will change. Bottom and side line still correct for disk cover?

princewang1994 commented 5 years ago

Hi, find_bottom_and_sideline finds two bottoms using cosine metric mentioned in the paper. The cosine metric would be changed after augmentation, for example, it can be warp heavily so you may unable to find the correct bottoms and sidelines. BTW, find_bottom_and_sideline record index of edge, but not the exact coordinates. After transforming, it produce the geometric target, so it works well.

ghost commented 5 years ago

Thank you, now i understand. I will close this issues.