Giter Club home page Giter Club logo

despeckling_sar_images's Introduction

Despeckling SAR images

Repository contains an algorithm that removes speckle noise from SAR images. The algorithm based on using convolutional neural network. Using PyTorch framework. This repository contains the implementation of the network from Kaggle on the framework PyTorch.

Description of CNN

Despeckle filter consist from convolution layers (CNN). Example, Summary for image (256, 256, 3):

----------------------------------------------------------------
        Layer (type)               Output Shape         Param #
================================================================
            Conv2d-1         [-1, 64, 256, 256]             640
        Conv2dSame-2         [-1, 64, 256, 256]               0
         LeakyReLU-3         [-1, 64, 256, 256]               0
            Conv2d-4         [-1, 64, 256, 256]          36,928
        Conv2dSame-5         [-1, 64, 256, 256]               0
       BatchNorm2d-6         [-1, 64, 256, 256]             128
         LeakyReLU-7         [-1, 64, 256, 256]               0
            Conv2d-8         [-1, 64, 256, 256]          36,928
        Conv2dSame-9         [-1, 64, 256, 256]               0
      BatchNorm2d-10         [-1, 64, 256, 256]             128
        LeakyReLU-11         [-1, 64, 256, 256]               0
           Conv2d-12         [-1, 64, 256, 256]          36,928
       Conv2dSame-13         [-1, 64, 256, 256]               0
      BatchNorm2d-14         [-1, 64, 256, 256]             128
        LeakyReLU-15         [-1, 64, 256, 256]               0
           Conv2d-16         [-1, 64, 256, 256]          36,928
       Conv2dSame-17         [-1, 64, 256, 256]               0
      BatchNorm2d-18         [-1, 64, 256, 256]             128
        LeakyReLU-19         [-1, 64, 256, 256]               0
           Conv2d-20         [-1, 64, 256, 256]          36,928
       Conv2dSame-21         [-1, 64, 256, 256]               0
      BatchNorm2d-22         [-1, 64, 256, 256]             128
             ReLU-23         [-1, 64, 256, 256]               0
           Conv2d-24         [-1, 64, 256, 256]          36,928
       Conv2dSame-25         [-1, 64, 256, 256]               0
      BatchNorm2d-26         [-1, 64, 256, 256]             128
             ReLU-27         [-1, 64, 256, 256]               0
           Conv2d-28         [-1, 64, 256, 256]          36,928
       Conv2dSame-29         [-1, 64, 256, 256]               0
      BatchNorm2d-30         [-1, 64, 256, 256]             128
             ReLU-31         [-1, 64, 256, 256]               0
           Conv2d-32         [-1, 64, 256, 256]          36,928
       Conv2dSame-33         [-1, 64, 256, 256]               0
      BatchNorm2d-34         [-1, 64, 256, 256]             128
             ReLU-35         [-1, 64, 256, 256]               0
           Conv2d-36          [-1, 1, 256, 256]             577
       Conv2dSame-37          [-1, 1, 256, 256]               0
             ReLU-38          [-1, 1, 256, 256]               0
           Lambda-39          [-1, 1, 256, 256]               0
================================================================
Total params: 297,665
Trainable params: 297,665
Non-trainable params: 0
----------------------------------------------------------------
Input size (MB): 0.25
Forward/backward pass size (MB): 1122.00
Params size (MB): 1.14
Estimated Total Size (MB): 1123.39
----------------------------------------------------------------

You can check architecture of neural network using the following lines of code:

from torchsummary import summary
model = DespeckleFilter(1)
summary(model, input_size=(1, 256, 256))

where 1 is number channels of image. Current repository using 1-channel images for training and testing neural network.

Dataset

Dataset should contain image without noise (clean images) and with noise (noise images). The data set must have the following file structure:

dataset/
├── test
│   ├── clean
│   └── noise
├── train
│   ├── clean
│   └── noise
└── val
    ├── clean
    └── noise

There is link on dataset (dataset shortened and formed) for training and testing network. Full dataset you can find on Kaggle.

Train and Test

Start the training of neural network with command:

python3 train.py

Testing of neural network with command:

python3 test.py

Results

Will be later

Examples

Will be later

despeckling_sar_images's People

Contributors

kotovnikitastudent avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

czw1910

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.