GithubHelp home page GithubHelp logo

sunxjtu / bdcn Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wandoucao/bdcn

0.0 1.0 0.0 624 KB

The code for the paper Bi-Directional Cascade Network for Perceptual Edge Detection( CVPR2019 ),and add the re_Dice loss from the paper Learning to Predict Crisp Boundaries (ECCV 2018)

License: MIT License

Python 96.45% JavaScript 2.97% MATLAB 0.53% Shell 0.05%

bdcn's Introduction

This code is update thecode into python3,and add the re_Dice loss which mentioned in Learning to Predict Crisp Boundaries(ECCV 2018).we apply it into face edge detection task,the experiment has achieved good results.

The first paper proposes a Bi-Directional Cascade Network for edge detection. By introducing a bi-directional cascade structure to enforce each layer to focus on a specific scale, BDCN trains each network layer with a layer-specific supervision. To enrich the multi-scale representations learned with a shallow network, we further introduce a Scale Enhancement Module (SEM). Here are the code for this paper.

The second paper mainly proposed a useful loss to help the network learning a crisp edge .

the experiment results

(left:the original results,right:add the re_Dice loss results)

Prerequisites

  • pytorch >= 0.2.0(Our code is based on the 0.2.0)
  • numpy >= 1.11.0
  • pillow >= 3.3.0
  • python3

Train and Evaluation

  1. Clone this repository to local
git clone https://github.com/pytorch/pytorch.git
  1. Download the imagenet pretrained vgg16 pytorch model [vgg16.pth](link: https://pan.baidu.com/s/10Tgjs7FiAYWjVyVgvEM0mA code: ab4g) or the caffemodel from the model zoo and then transfer to pytorch version. You also can download our pretrained model for only evaluation. The google drive link.

  2. Download the dataset to the local folder

  3. running the training code train.py or test code test.py

Pretrained models

BDCN model for BSDS500 dataset and NYUDv2 datset of RGB and depth are availavble on Baidu Disk.

The link https://pan.baidu.com/s/18PcPQTASHKD1-fb1JTzIaQ
code: j3de

The pretrained model will be updated soon.

bdcn's People

Contributors

wandoucao avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.