Finetune Enformer on expression data.
First, install dependencies
# clone project
git clone https://github.com/wconnell/enformer-finetune
# install project
cd enformer-finetune
pip install -e .
pip install -r requirements.txt
Next, download data and test finetuning. The module ships with testing data files under tests/data/{train,val}.bed
.
# download
bash download-data.sh
# build dataset
cd eft; python preprocess.py
# modify options in `config.yaml`...
# launch training
python main.py fit --config config.yaml
- DDP OOM issues on 24GB machine set:
export PYTORCH_CUDA_ALLOC_CONF=max_split_size_mb:128
- requires batch_size >=2
- must use full precision (32 bit)
- use num_workers = 0