Contents
- Abstract
- Project Motivation
- Biological & Theoretical Background
- Model Structure
- Usage
- First Steps: Pyro
- Model Reconstruction
- Performance Comparison
- Conclusions
Usage
Dependencies
- PyTorch (installation guide here)
- NumPy (through Anaconda or
pip install numpy) - SciPy (through Anaconda or
pip install scipy)
Running
The code for this model is included in this website’s github, but a fully functional version will soon be deployed on the Marks lab’s github. It is recommended that once the lab’s version is available, that version should be downloaded.
- Create Environment
- using
conda create -n env_name python=x.xcreate your environment for running the model. The model was tested using Python 2.7 but is compatible with Python 3. Either through a.yamlfile or through terminal, ensure that the model’s dependencies are installed.
- using
- Clone Repo
- Acquire the necessary code by cloning the github repository.
- Prepare Sequence Alignment Dataset
- To use a sample data set from the Marks lab, run the download_alignments.sh file (
./download_alignments.shin terminal) - To construct a new sequence alignment data set, it is advised that one uses the EVcouplings software package. This package was constructed by the Marks lab for a previous statistical model, and generates sequence alignments in the correct format for both EVmutation and DeepSequence packages.
- To use a sample data set from the Marks lab, run the download_alignments.sh file (
- Set model parameters
- In
run_ptmle.pyorrun_ptsvi.pyfor MLE- or SVI-VAE models respectively, set the data, model and training parameters in the respective dictionaries
- In
- Set up directory
- Ensure all modules can access one another and that a ‘model_params’ folder has been created to store saved models.
- Run!
- For CPU running (which is strongly advised against), run
python run_ptxxx.pywherexxxismleorsvidepending on the model. - For GPU running with cuda, construct a script to run the model using
sbatch script_name.sh. An example of a script to run this model is:
- For CPU running (which is strongly advised against), run
#!/bin/bash
#SBATCH -c 8
#SBATCH -t 18:00:00
#SBATCH -p gpu
#SBATCH --gres=gpu:4
module load gcc/6.2.0
module load cuda/9.0
python run_ptsvi.py