Skip to content

CMME-Lab/PhysRFANet

 
 

Repository files navigation

PhysRFANet: Physics-Guided Neural Network for Real-Time Prediction of Thermal Effect During Radiofrequency Ablation Treatment

Overview

This repository contains the implementation of a neural network designed to predict the thermal effects of Radiofrequency Ablation (RFA) on breast tumors. RFA is a medical procedure used to ablate, or destroy, breast tumors using heat generated by radiofrequency energy. Understanding the thermal impact of RFA is crucial for effective treatment planning and outcome prediction.

Features

  • 3D Encoder-decoder-based convolutional neural network (EDCNN), U-Net, and Attention U-Net architecture for accurate prediction of ablated area and temperature distribution.
  • Custom loss functions that combine MSE, weighted MSE, and weighted Dice loss to enhance prediction accuracy.
  • Data pre-processing and loading modules for efficient handling of RFA simulation data.
  • Evaluation metrics to assess model performance, including MSE, RMSE, dice coefficient, and Jaccard index.

Requirements

  • python 3.9
  • torch-1.11.0+cu113
  • cudatoolkit-11.3.1

Installation

To set up the project environment:

  • Clone the repository: git clone https://github.com/iangilan/PhysRFANet.git

Dataset

The dataset used in this project consists of:

Note: MR images of breast cancer patients from a publicly available dataset (Saha et al., 2018) were utilized to model tumor geometry.

Usage

  1. Locate your RFA dataset in your local storage.
  2. Edit config.py according to the user's need.
  3. Edit the data loaders data_loader_Temp.py and data_loader_Dmg.py for temperature distribution and damaged area, respectively, to load and preprocess the data.
  4. Train the model using python train_Temp.py or python train_Dmg.py.
  5. Evaluate the model's performance on test data using python test_Temp.py or python test_Dmg.py.

Model Architecture

  • The RFACNN model is a 3D EDCNN that consists of encoder and decoder blocks, designed for extracting features and predicting both temperature distribution and damaged (ablated) areas.
  • The RFAUNet model is a 3D U-Net, designed for extracting features and predicting both temperature distribution and damaged (ablated) areas.
  • The RFAAttUNet model is a 3D Attention U-Net, designed for extracting features and predicting both temperature distribution and damaged (ablated) areas.
  • The architectures of all models are defined in models.py.

Custom Loss Function

The model uses a combined loss function (new_combined_loss in utils.py) incorporating MSE, weighted MSE, and weighted Dice loss to cater to the specific challenges in RFA thermal effect prediction.

Evaluation

The model is evaluated based on Mean Squared Error (MSE), Root Mean Squared Error (RMSE), Mean Absolute Error (MAE), and Dice Coefficient, providing a comprehensive assessment of its prediction accuracy.

Citation

If you use this tool in your research, please cite the following paper:

Contact

For any queries, please reach out to Minwoo Shin.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%