Skip to content

Dewarping Document Image By Displacement Flow Estimation with Fully Convolutional Network

License

Notifications You must be signed in to change notification settings

gwxie/Dewarping-Document-Image-By-Displacement-Flow-Estimation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dewarping Document Image

Dewarping Document Image By Displacement Flow Estimation with Fully Convolutional Network.

See “paper” for more information.

Download “rectified images”.

Dewarping Process

image We predict the displacement and the categories (foreground or background) at pixellevel by applying two tasks in FCN, and then remove the background of the input image, and mapped the foreground pixels to rectified image by interpolation according to the predicted displacements. The cracks maybe emerge in rectified image when using a forward mapping interpolation. Therefore, we construct Delaunay triangulations in all scattered pixels and then using interpolation.

Compare

image

Requirements

python >=3.7

pytorch

opencv-python

scipy

Notice

  • 2020.11.10 update the result file, including 6-25_11_52_54-49-rgb_ and 6-25_11_52_54-49_.

  • 2022.2.17 update the Release Code.

  • 2022.4.14 update Source file.

Release Code

The source code is open, please download from Source.

Please send an email to [email protected].

Running

1、Download model parameter and source codes

2、Resize the input image into 1024x960 (zooming in or out along the longest side and keeping the aspect ration, then filling zero for padding. )

3、Run python test.py --data_path_test=./dataset/shrink_1024_960/crop/

Training

Run python train.py

Dataset

The training dataset can be synthesised using the scripts.

About

Dewarping Document Image By Displacement Flow Estimation with Fully Convolutional Network

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages