Giter Site home page Giter Site logo

ehr-fhir-converter's Introduction

EHR-FHIR Converter

Convert data from arbitrary EHR vendors to the FHIR standard.

Operates as part of the CONSULT architecture (ehr-fhir-converter), a collaborative mobile decision-support system to help patients suffering from chronic diseases with multiple morbidities self-manage their treatment:

Cite as A semi-autonomous approach to connecting proprietary EHR standards to FHIR. Chapman, Martin and Curcin, Vasa and Sklar, Elizabeth I. 2019.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

Before installing, download and install Python 3 and Pip, a Python package manager.

(Recommended) Then install virtualenv.

Other service communication

Receives messages from: ehr-integration (install). Sends messages to: fhir-server (install).

Running

Clone this repository:

git clone [email protected]:kclconsult/ehr-fhir-converter.git

Change into the directory:

cd ehr-fhir-converter/src

Initialise a virtual environment, and activate:

virtualenv -p python3 env
. env/bin/activate

Install dependencies:

pip install -r requirements.txt
(Optional, Option 1) Build FHIR classes

Clone the FHIR parser repository:

git clone [email protected]:smart-on-fhir/fhir-parser.git src/main/python/fhir-parser

Copy configuration scripts into the directory:

cp src/main/python/mappings.py src/main/python/fhir-parser/
cp src/main/python/settings.py src/main/python/fhir-parser/

Install parser requirements:

cd src/main/python/fhir-parser/
pip install -r requirements.txt

Generate FHIR Python classes:

touch Default/__init__.py
python generate.py

Move generated classes into project:

cd ../
mv models/ models_full/
touch models_full/__init__.py

Automated through fhir-parser.sh.

(Optional, Option 2) Download FHIR classes

Clone the FHIR client repository.

git clone [email protected]:smart-on-fhir/client-py.git src/main/python/client-py

Copy FHIR classes into project:

cd src/main/python/
cp -r client-py/fhirclient/models/ models_full/

Usage

Run as follows:

python listen.py

The app runs by default on port 3004.

Install as package

Run setup tools from the root directory:

python setup.py sdist bdist_wheel

Given a certain release, either available in dist/ if built, or via Github, install as follows:

python setup.py install

Documentation

View.

Running the tests

python setup.py test

Deployment

Deployment is via Docker, and includes containers for this application and an optional message queue.

Specify the address of the FHIR server and credentials in docker-compose. If a hostname, reference its corresponding certificate. Also specify the address of the hostname if unlikely to be present in the DNS.

Build these containers:

docker-compose build

Run these containers:

docker-compose up -d

(Optional) Run without queue:

docker-compose up --scale webapp-queue=0 rabbit=0

Different docker-compose files exist to accommodate different service configurations.

Built With

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

Produced as part of the CONSULT project.

CONSULT project

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

ehr-fhir-converter's People

Contributors

martinchapman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

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