GithubHelp home page GithubHelp logo

tkwoo / visualization-segmentation-process Goto Github PK

View Code? Open in Web Editor NEW
72.0 9.0 16.0 14.61 MB

Segmentation visualization, keras, augmentation, fine tuning

Python 100.00%
segmentation keras unet deeplearning imagedatagenerator tensorflow visualization visualization-segmentation-process segmentation-visualization

visualization-segmentation-process's Introduction

Visualization segmentation training process

Semenatic segmentation using Unet, fcn, pspnet

Result

Youtube video

click image to watch video

Requirements

Usage

To train a model (visualization)

$ python main.py

Then, the training steps(image) will be saved 'result' directory


usage: main.py [-h] [--data_path DATA_PATH] 
                    [--output_dir OUTPUT_DIR]
                    [--image_height IMAGE_HEIGHT] 
                    [--image_width IMAGE_WIDTH]
                    [--batch_size BATCH_SIZE]
                    [--total_epoch TOTAL_EPOCH]
                    [--initial_learning_rate INITIAL_LEARNING_RATE]
                    [--learning_rate_decay_factor LEARNING_RATE_DECAY_FACTOR]
                    [--epoch_per_decay EPOCH_PER_DECAY] 
                    [--ckpt_dir CKPT_DIR]
                    [--ckpt_name CKPT_NAME]
                    [--pretrained_weight_path PRETRAINED_WEIGHT_PATH]
                    [--confidence_value CONFIDENCE_VALUE] 
                    [--debug DEBUG]
                    [--mode MODE] 
                    [--test_image_path TEST_IMAGE_PATH]
                    [--tf_log_level TF_LOG_LEVEL]

Input data(only for training)

└── dataset
    └── xxx
        └── train
            └── IMAGE
                └── ori
                    └── xxx.png (name doesn't matter)
            └── GT
                └── mask
                    └── xxx.png (It must have same name as original image)

The dataset directory structure is quite complex to use the Keras ImageDataGenerator Framework.

Input data for testing

└── test_data
    └── image.png

First, create checkpoint dir and download trained parameter files

└── checkpoint
    └── (ckpt_name)
        ├── model.json 
        ├── weight.xx.h5
        └── ...

You can download CHECKPOINT --> not supported

To test a model

$ python main.py --mode predict_img --ckpt_name <NAME> --test_image_path <.../image.png>

Reference

paper : https://lmb.informatik.uni-freiburg.de/people/ronneber/u-net/

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.