Giter VIP home page Giter VIP logo

msl-student-becomes-master's Introduction

Teach me to segment with mixed-supervision:when the student becomes the master

This repository contains the code of our recent paper:

Jose Dolz, Christian Desrosiers, Ismail Ben Ayed. Teach me to segment with mixed-supervision: confident students becomes masters. Arxiv'20.



Dataset preparation

Download the dataset from the ACDC Challenge or your own data.

Then, you can find the instructions to pre-process the data and obtain partial labeled annotations in this repository

If you just want to run your own dataset with this code, you simply need to convert the 3D volumes to 2D slices/images. Then, the structure to save the images should be (in trainSemi folder you can avoid having the 'WeaklyAnnotations' folder, but I suggest to create the same structure across all the folders):

-| MainFolder
--|N (number of labeled images)
----| trainFull
--------| Img/
------------| patientXXXX_01_1.png
------------| patientXXXX_01_2.png
------------| ....
--------| GT/
------------| patientXXXX_01_1.png
------------| patientXXXX_01_2.png
------------| ....
--------| WeaklyAnnotations/
------------| patientXXXX_01_1.png
------------| patientXXXX_01_2.png
------------| ....
----| trainSemi
--------| Img/
------------| patientXXXX_01_1.png
------------| patientXXXX_01_2.png
------------| ....
--------| GT/
------------| patientXXXX_01_1.png
------------| patientXXXX_01_2.png
------------| ....
--------| WeaklyAnnotations/
------------| patientXXXX_01_1.png
------------| patientXXXX_01_2.png
------------| ....
----| val/
----| test/

Note: Val and Test folder will have the same structure as trainFull and trainSemi folders. Furthermore, note that we evaluated our method on the ACDC dataset, which contains two sets of images (systole and diastole) per exam. This explains the '01' in between the patient name and the slide number (patient_systole/diastole_slidenumber.png).

Training

The code for training will be released after publication of the paper.

Trained models

We also share the trained networks for our two models, i.e., KL and KL+Ent, which can be found in this link

Testing

To test a given model, download the trained models in the previous link into a folder named 'TrainedModel'. Then, you can use the following script:

CUDA_VISIBLE_DEVICES=1 python runTest.py --modelName ./TrainedModel/path_and_name_of_your_model

NOTE: This script will segment both the validation and testing images, and generate 3D volumes from them. In order to be able to successfully run the whole script, and therefore compare to the GT, you need to create 3D GT volumes in .nifti format and saved them in the following path:

-|Results
---|GT
------|val/Nifti
---------|patientXXX_YY.nii
---------|patientXXX_YY.nii
---------|......
------|test/Nift
---------|patientXXX_YY.nii
---------|patientXXX_YY.nii
---------|......

Several results

Qualitative results comparing the proposed methods to other baselines for mixed-supervised learning, as well as to full supervision (upper bound)



The top and bottom rows visualize respectively the prediction probability maps obtained by the proposed models



Requirements

  • The code has been written in Python (3.6.9)
  • Torch version: 1.6.0
  • scikit-image: 0.15.0

Versions

  • Version 1.0.
    • December,10th. 2020

You can contact me at: [email protected]

msl-student-becomes-master's People

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.