Skip to content

Elastic Deformation that is localised to a specific position on a segmentation mask. Enables smooth augmentation by enlarging or reducing size of segmentation area without distorting nearby pixels

kitbransby/Localised-Elastic-Deformation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Localised Elastic Deformation

Elastic Deformation augmentation that is localised to a positive segmentation region in a mask. Enables smooth and natural augmentation by enlarging or reducing size of segmentation area without distorting nearby pixels. The amount, radius, direction and randomness of the displacement can be adjusted using the config in main, and is applied to both image and mask.

Particularly applicable for medical image segmentation tasks where general Elastic Deformation can cause implausible boundaries.

alt text

Usage:

Simply run this command for default config on example data python main.py

For your own data, place image and masks as npy files into the data folder, as follows:

Localised-Elastic-Deformation
│
└───data
    │   image_1.npy
    │   image_2.npy
    │   mask_1.npy
    │   mask_2.npy
    │   ...

Dependencies:

Simple ITK (tested on 2.2.0)
numpy
matplotlib
glob

About

Elastic Deformation that is localised to a specific position on a segmentation mask. Enables smooth augmentation by enlarging or reducing size of segmentation area without distorting nearby pixels

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages