Clone this repo.
git clone https://github.com/huangh0408/protein-dimer-inpainting.git
Prerequisites
- Python 2.7
- tensorflow-gpu 1.12.0
- ipdb
- opencv-python
- glob
- cPickle
We use 3dcomplex and masif datasets.
We use gremlin, evcomplex,benchmark 5.0 and casp-capri datasets.
Please prepare the pdb file and the corresponding chain file, which are required by our scripts to generate inter-protein and intra-protein contact/distance map.
# To generate the whole contact/distance map.
cd generate_contact_map
bash work.sh
There are three folders to present three kinds of datasets respectively. You can download the data here.
# To train on the dataset. Notice that you should modify the input file directory and checkpoint directory in the work_train.sh file.
bash work_train.sh
# To train on the you dataset, for example.
python train.py --input_dir[the path of original images] --mode=[contact distance slice] --netsize[128 256 512]
There are many options you can specify. Please use python train.py --help
or see the options
There are three folders to present pre-trained for three kinds of datasets respectively. You can download the pre-trained model here.
# To test on the dataset. Notice that you should modify the test set directory and checkpoint directory in the work_test.sh file.
bash work_test.sh
We calculate the precision,which is defined as TP/N. Such as Top 5, 10, 20, L/10, L/5, L/2, L used in the intra-protein contact map prediction. For the overall results, we calculate the mean precision. Additionaly, we calculate the success rate, which is defined the percentage of the targets with at least one successfully predicted contact when a certain number of predicted contacts are considered, compared to all the targets in the test set.
# To evaluate on the dataset. Notice that you should modify the output file directory and groundtruth file directory in th work_evaluate.sh file.
bash work_evaluate.sh
original scripts without mask
scripts with region mask
implement in environment python 3.7
jupyter-notebook to test our model
If you use this code for your research, please cite our papers.
@article{huang2021,
title={Inter-protein contact map generated only from intra-monomer by image inpainting},
author={He Huang, Chengshi Zeng, Xinqi Gong},
booktitle={2021 IEEE International Conference on Bioinformatics and Biomedicine (BIBM)},
year={2021},
doi={10.1109/BIBM52615.2021.9669709}
}
Our inpainting codes refer to Inpainting and the readme.md file refers to Rethinking-Inpainting-MEDFE.