wenwenyu / PICK-pytorch

Code for the paper "PICK: Processing Key Information Extraction from Documents using Improved Graph Learning-Convolutional Networks" (ICPR 2020)
https://arxiv.org/abs/2004.07464
MIT License
553 stars 191 forks source link

Issue with Training data box_coordinates direction #56

Closed compadrejavo closed 3 years ago

compadrejavo commented 3 years ago

Greetings, I wanted to point a conflict about the data format of training and test data:

The readme says that the direction of the coordinates of the bounding boxes must be clockwise, but looking at the examples given in the X00016469623.tsv file of this repo, the coordinates are counterclockwise.

1,83,41,331,41,331,78,83,78,TAN WOON YANN,other 1,109,171,330,171,330,191,109,191,MR D.I.Y. (M) SDN BHD,company

image

huliang2016 commented 3 years ago

whether the coordinates of the bounding boxes are clockwise or not, this line of code should be able to handle it correctly.

https://github.com/wenwenyu/PICK-pytorch/blob/master/data_utils/documents.py#L108

phongnd3482 commented 3 years ago

Your coordinates directions are wrong. In image processing, the coordinates are as following image

compadrejavo commented 3 years ago

Ohhh, now I understand, I'll close this issue. Thanks.