Giter Site home page Giter Site logo

jianglimed / emergency-triage-of-brain-computed-tomography-via-anomaly-detection-with-a-deep-generative-model Goto Github PK

View Code? Open in Web Editor NEW

This project forked from seungjunlee96/emergency-triage-of-brain-computed-tomography-via-anomaly-detection-with-a-deep-generative-model

0.0 1.0 0.0 25.67 MB

C++ 0.95% Python 90.22% Cuda 7.73% Dockerfile 1.10%

emergency-triage-of-brain-computed-tomography-via-anomaly-detection-with-a-deep-generative-model's Introduction

Emergency triage of brain computed tomography via anomaly detection with a deep generative-model

Python 3.8 Pytorch 1.3 CUDA 10.1 License GPLv3

Figure4 Figure4

This repository contains the official Pytorch implementation of the following paper:

Emergency triage of brain computed tomography via anomaly detection with a deep generative model
Authors: Seungjun Lee, Boryeong Jeong, Minjee Kim, Ryoungwoo Jang, Wooyul Paik, Jiseon Kang, Won Jung Chung, Gil-Sun Hong & Namkug Kim
https://www.nature.com/articles/s41467-022-31808-0

Abstract: Triage is essential for the early diagnosis and reporting of neurologic emergencies. Herein, we report the development of an anomaly detection algorithm (ADA) with a deep generative model trained on brain computed tomography (CT) images of healthy individuals that reprioritizes radiology worklists and provides lesion attention maps for brain CT images with critical findings. In the internal and external validation datasets, the ADA achieved area under the curve values (95% confidence interval) of 0.85 (0.81โ€“0.89) and 0.87 (0.85โ€“0.89), respectively, for detecting emergency cases. In a clinical simulation test of an emergency cohort, the median wait time was significantly shorter post-ADA triage than pre-ADA triage by 294 s (422.5 s [interquartile range, IQR 299] to 70.5 s [IQR 168]), and the median radiology report turnaround time was significantly faster post-ADA triage than pre-ADA triage by 297.5 s (445.0 s [IQR 298] to 88.5 s [IQR 179]) (all p < 0.001).

For business inquiries, please refer to [email protected]

1. System requirements

The package development version is tested on Linux (Ubuntu >= 16.04) operating systems. The developmental version of the package has been tested on the following systems:

  • Python >= 3.8.5
  • PyTorch >= 1.3.1
  • CUDA >= 10.1/10.2

This implementation requires GPU acceleration for optimal performance. We have tested the code with the following specs:

  • CPU: 12 cores, Intel(R) Xeon(R) CPU E5-2603 v4 @ 1.70GHz
  • RAM: 16 GB
  • GPU: 4 GPUs, Titan RTX 8000

2. Installation guide

Docker installation

Please follow the links below to install docker.

Docker container

Using the following codes, you can install docker container.

$ sudo docker build ./ -t ubuntu/cnstylegan:latest # Be sure to be inside the project directory
$ sudo docker run --gpus all --restart=always --shm-size=128G -dit --name cnstylegan -v /mnt:/mnt -p 8888:8888 ubuntu/cnstylegan
$ sudo docker exec -it cnstylegan bash

which should install in about 30 minutes.

3.Usage

You can either train the model from scratch or use pretrained model checkpoint

Training

In order to train the model from scratch, use following codes:

python3 -m torch.distributed.launch --nproc_per_node=<n_gpus> --master_port=8888 train.py --data_path=[TRAINING DATASET]
python3 -m torch.distributed.launch --nproc_per_node=<n_gpus> --master_port=8888 train_encoder.py --data_path=[TRAINING DATASET]`

Pretrained model checkpoint

To use pretrained model checkpoint, download following files and place at the project directory.

  • model checkpoint (link)
  • latent statistics (link)

Project images to latent space

Use following code to project images to latent space and perform anomaly detection

$ python projector.py --query_save_path=[DATASET_PATH]

  • To run the demo code: $ python projector.py --query_save_path=./demos which takes about 5 minutes for each CT scan

License

This project is covered under the GNU GENERAL PUBLIC LICENSE Version 3 (GPLv3).

emergency-triage-of-brain-computed-tomography-via-anomaly-detection-with-a-deep-generative-model's People

Contributors

seungjunlee96 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.