Home

Awesome

LineCloser

Unofficial Keras implementation of Joint Gap Detection and Inpainting of Line Drawings.

Overview

Joint gap for line-drawings. Model1 uses network from the paper. For stable training, BN was added for all Conv2D. Model2 uses common network for inpaint.

Dependencies

Usage

  1. Set up directories.

  2. Download the model from release and put it in the same folder with code.

  3. Run predict.py for prediction. Run model{NUM}.py for train.

Data Preparation

There are 3 methods for data generation, DATA_GEN, DATA_GAP and DATA_THIN.

  1. Use DATA_GEN for training, the data is generated online.

  2. Collect line-drawings with LineDistiller.

  3. Put line-drawings into data/line, using DATA_GAP for training.

  4. Thin(normalize) the line-drawings with LineNormalizer or tranditional thinning method.

  5. Manually processe line-drawings and thinning results(threshold etc.), then crop them into pieces.

  6. Put line-drawings into data/line and put thinning results into data/thin, using DATA_THIN for training.

Models

Models are licensed under a CC-BY-NC-SA 4.0 international license.

From Project HAT by Hepesu With :heart: