Skip to content

NHSE PhD Internship Project - P61: Understanding Fairness and Explainability in Multi-modal Approaches within Healthcare

License

Notifications You must be signed in to change notification settings

nhsengland/mm-healthfair

Repository files navigation

Understanding Fairness and Explainability in Multimodal Approaches within Healthcare

NHSE PhD Internship Project

About the Project

status: experimental PyPI - License pre-commit.ci status Ruff Poetry Code style: black

This repository holds code for the Understanding Fairness and Explainability in Multimodal Approaches within Healthcare project. See the original project propsoal for more information.

Note: Only public or fake data are shared in this repository.

Project Stucture

  • The main code is found in the root of the repository (see Usage below for more information)
  • The accompanying report is also available in the reports folder
  • More information about the code usage can be found in the model card

Built With

Python v3.10

Getting Started

Installation

To get a local copy up and running follow these simple steps.

To clone the repo:

git clone https://github.com/nhsengland/mm-healthfair

To create a suitable environment:

  1. Use pip + requirements.txt
  • python -m venv _env
  • source _env/bin/activate
  • pip install -r requirements.txt
  1. Use poetry (recommended)
  • Install poetry (see website for documentation)
  • Navigate to project root directory cd mm-healthfair
  • Create environment from poetry lock file: poetry install
  • Run scripts using poetry run python3 xxx.py

Note: There are known issues when installing the scispacy package for Python versions >3.10 or Apple M1 chips. Project dependencies strictly require py3.10 to avoid this, however OSX users may need to manually install nmslib with CFLAGS="-mavx -DWARN(a)=(a)" pip install nmslib to circumvent this issue (see open issue nmslib/nmslib#476).

Usage

This repository contains code used to extract and preprocess demographic, time-series and clinical notes from MIMIC-IV v2.2. Additionally, it includes the model architectures and training scripts used to train multimodal models on different modalities and generate the results described in the report.

Outputs

  • Preprocessed features from MIMIC-IV 2.2
  • Trained models
  • Notebook exploring the dataset and visualising results

Seeds have been set to reproduce the results in the report.

Datasets

The MIMIC-IV dataset (v2.2) can be downloaded from PhysioNet.org. This project made use of three modules:

  • Hosp: hospital level data for patients: labs, micro, and electronic medication administration
  • ED: data from the emergency department
  • Notes: deidentified free-text clinical notes

Further information can be found in PhysioNet's documentation.

Roadmap

See the repo issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

See CONTRIBUTING.md for detailed guidance.

License

Unless stated otherwise, the codebase is released under the MIT Licence. This covers both the codebase and any sample code in the documentation.

See LICENSE for more information.

The documentation is © Crown copyright and available under the terms of the Open Government 3.0 licence.

Contact

To find out more about the Analytics Unit visit our project website or get in touch at [email protected].

About

NHSE PhD Internship Project - P61: Understanding Fairness and Explainability in Multi-modal Approaches within Healthcare

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages