MIMIC-III is a corpus has 58,976 hospital admission and 2,083,180 had written
notes by medical professionals. This repo contains Docker configuration
files and a GNU makefile
create and control the life cycle of a Postgres
database containing the MIMIC-III corpus. The Docker Postgres container
is populated with the MIMIC-III corpus using scripts from the MIMIC Code
Repository.
The installation of the database isn't trivial. Even though everything is automated, there is a lot that can go wrong. For this reason, images of the database are available by the author with provided proof you have taking the PhysioNet MIMIC-III training. The steps to install are as follows:
- Clone this repository:
git --recurse-submodules https://github.com/plandes/mimicdb.git
- Do the PhysioNet MIMIC-III training. Only after you have done this do you have access to the corpus source data.
- Download the source MIMIC-III data files as the file
mimic-iii-clinical-database-1.4.zip
to this directory. - Install the Postgres client:
- macOS:
brew install libpq
- Linux:
apt install postgresql postgresql-contrib
- Windows: Installer
- macOS:
- Install git, Docker, and GNU make
- Edit the user editable values section of the makefile to make any changes such as the database name, user, or port.
- Bring up the database Docker container and install the database:
make world
.
The last step does the following:
- Decompresses the MIMIC-III data files.
- Clones the MIMIC Code Repository.
- Generates passwords in
password.txt
andsa-password.txt
. - Uses the MIMIC Code Repository to load the Postgres database with the corpus.
- Creates the
mimic3
database user and grants the userselect
rights. - Shuts down the instance.
- To start the container:
make up
- To stop the container:
make down
- To login to the database as a user:
make userlogin
- To login to the database as the system administrator:
make rootlogin
A bash script could be created to do everything the makefile does very easily. If you do that, please send it to me and I will add it to this repo.
An extensive changelog is available here.
Copyright (c) 2023 Paul Landes