Shen-Lab / CPAC

[Bioinformatics 2022] Cross-Modality and Self-Supervised Protein Embedding for Compound-Protein Affinity and Contact Prediction
GNU General Public License v3.0
12 stars 1 forks source link

What are the versions of PyTorch? #1

Open YeojinKim220 opened 1 year ago

YeojinKim220 commented 1 year ago

Hi, Thank you for this work. I have two questions about the code.

1. I am wondering what the version of PyTorch for this project is. I could not find information about the version on the environment.yml file.

2. Could you explain what "prot_[data_type]_inter_exist.npy" file is for? prot_train_inter_exist = np.load(data_processed_dir+'prot_train_inter_exist.npy') It seems related to calculating loss for interaction but I could not find information in the paper.

Thanks in advance.

yyou1996 commented 1 year ago

Hi @YeojinKim220,

  1. We did not have special requirements for the PyTorch version. Generally, I believe >=1.6.0 would work.
  2. inter_exist is the normalized factor for contacts, since in the repo the supervision objective of the contact prediction is via regression, we follow https://pubs.acs.org/doi/full/10.1021/acs.jcim.0c00866 for such normalization which helps performance (https://github.com/Shen-Lab/CPAC/blob/243a899eb926e01db99e8f394e9907e9dfa698ab/cross_modality_keras/nets.py#L380).
ZzzzzzzSkyward commented 1 year ago

Actually newer version of Pytorch will fail because of an inplace operation x+=x0.