tianzhi0549 / CTPN

Detecting Text in Natural Image with Connectionist Text Proposal Network (ECCV'16)
http://textdet.com
Other
1.28k stars 539 forks source link

Implementation of Side-Refinement #58

Closed senliuy closed 7 years ago

senliuy commented 7 years ago

Hi, TianZhi, I am trying to implement the training phase of CTPN with TensorFlow based on your code and faster-rcnn. However, I don't quietly understand the meaning of side-refinement or offset regression in your paper. The problems is I don't understand the meaning of x{side} in your paper so I can't implement the training loss function. Can you release the code of side-refinement or tell me how to calculate x{side}? It will help me understanding the meaning of your excellent idea. Many thanks!

tianzhi0549 commented 7 years ago

Hi @senliuy, the side-refinement means that for every anchor, which is close to horizontal sides of word bounding boxes, need also regress the relative distance to the word bounding boxes. In other words, these anchors are required to output three values (y_c, h, x_side) instead of two values (y_c, h). Hope it is useful for you.

senliuy commented 7 years ago

Thanks, @tianzhi0549 . Now I have finished the code of CTPN.

dajiangxiaoyan commented 7 years ago

@senliuy will you plan to release the code?

senliuy commented 7 years ago

@dajiangxiaoyan Sorry, the code is for company used currently.

dajiangxiaoyan commented 7 years ago

@senliuy Thank you for reply. I also reimplement CTPN. But I have met two problem.

  1. when adding blstm layer after the last conv layer, the net is not converge.
  2. how to split the label text bounding box. Just split it by 16 width. Fox example. the bbox is (x0,y0, x1, y1). Split it into (x0,y0,x0+16, y1)...?
senliuy commented 7 years ago
  1. There are lots of reasons that lead to non-convergence. I'm sorry that I can't answer your question.
  2. You are right, tianzhi gave the code of generating anchors. You can copy his code.
dajiangxiaoyan commented 7 years ago

@senliuy Thank you very much. I will try.

dajiangxiaoyan commented 7 years ago

@senliuy sorry to bother you again. I do not add side-refinement in my implementation. So i wander if i divide gt boxes directly by equal 16 witdh, the overlap between gt and anchor may be too low. For example:

  1. The gt box is (16,y0,64,y1), divide into (16,y0,32,y1) (32,y0,48,y1) (48,y0,64,y1)
  2. the anchor is (8,y0',24,y1'), (24, y0',40,y1')

Then, calc the overlap is very low. do i understand right?

tonmoyborah commented 6 years ago

I want to implement side refinement too. Any help on how I should proceed? @senliuy have you implemented the side refinement part?

hcnhatnam commented 5 years ago

Discuss about iplementation of Side-Refinement