Developing a CDSS as a mini project
cdss-dev-project/
│
├── data/
│ ├── project_db.xlsx # Patients file
│ ├── cdss.db # Processed DB for all operations. Created on the first run
│ ├── Loinc_2.80.zip
│
├── backend/
├── ├── queries/ # All of the queries for initialization, data access and business logic
│ │ ├── create_patients_table.sql
│ │ ├── create_loinc_table.sql
│ │ ├── insert_patient.sql
│ │ └── ...
│ ├── backend_config.py # Configuration file for the backend operations
│ ├── dataaccess.py
│ ├── businesslogic.py
│
├── frontend/
│ ├── images/ # Images used for design
│ ├── userinterface.py
│
├── README.md
├── requirements.txt
- Python 3.7 or higher.
- Loinc_2.80.zip (Downloaded from Loinc-Org) - Should be placed under
data
repository.
- Clone the repository:
git clone https://github.com/shaharoded/cdss-dev-project.git
cd cdss-dev-project
- Create and activate a virtual environment:
# On Windows
python -m venv venv
.\venv\Scripts\Activate
# On macOS/Linux
python3 -m venv venv
source venv/bin/activate
- Install dependencies:
pip install -r requirements.txt
Once you updates the main of each module:
You can run the folowing PowerShell command in the root repository to initiate the DataAccess class and build your DB:
(from root)
python -m backend.dataaccess
You can run the folowing PowerShell command in the root repository to test your business logic:
(from root)
python -m backend.businesslogic
Need to remove the DB you created?
rm cdss.db
In order to run the application, you'll need to navigate to the frontend folder and run the code from there:
(from root)
cd frontend
python userinterface.py
Once you've made changes, commit and push as usual:
git add .
git commit -m "Commit message"
git push -u origin main