-
Notifications
You must be signed in to change notification settings - Fork 0
Installation
This guide provides detailed instructions for installing and configuring pat2vec.
Core Services:
- CogStack: An operational instance for data retrieval.
- Elasticsearch: The backend for CogStack.
- MedCAT: For medical concept annotation.
Local Setup:
- Python: Version 3.10 or higher.
-
Virtual Environment: Requires the
python3-venvpackage (or equivalent for your OS).
The install_pat2vec.sh script automates the full setup.
Prerequisites
- A MedCAT model pack (
.zipfile). - Your CogStack/Elasticsearch credentials.
Steps
-
Clone the repository:
git clone https://github.com/SamoraHunter/pat2vec.git cd pat2vec -
Run the installation script:
chmod +x install_pat2vec.sh ./install_pat2vec.sh
The script supports several options:
-
--proxy: Use if you are behind a corporate proxy. -
--dev: Installs development dependencies (e.g.,pytest). -
--force: Performs a clean installation, removing any existing environment.
-
-
Activate the environment:
source ../pat2vec_env/bin/activate
-
Clone the repository:
git clone https://github.com/SamoraHunter/pat2vec.git
-
Run the installation script: This script sets up the Python virtual environment.
cd pat2vec install.bat -
Activate the environment:
pat2vec_env\Scripts\activate
After running the installation script, you must configure your environment.
Your credentials should be placed in a file named credentials.py in the parent directory of your pat2vec clone. The install_pat2vec.sh script automatically copies a template for you.
IMPORTANT: This file contains sensitive information and should never be committed to version control.
The structure should look like this: