Git Product home page Git Product logo

disae's Introduction

DISAE

MSA-Regularized Protein Sequence Transformer toward Predicting Genome-Wide Chemical-Protein Interactions: Application to GPCRome Deorphanization

Shield: CC BY-NC 4.0

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.

CC BY-NC 4.0

This is the repository to replicate experiments for the fine-tuning of classifier with pretrained ALBERT in the paper DISAE.

----------- INSTRUCTION -----------

1. Install Prerequisites

  • python 3.7
  • Pytorch
  • rdkit
  • Transformers (Huggingface. version 2.3.0)

2. Clone this repository

3. Download Data

All data could be download here and put it under this repository, i.e. in the same directory as the finetuning_train.py.

There will be four subdirectories in the data folder.

image

  • activity: gives you the train/dev/test set split based on protein similarity at threshold of bitscore 0.035
  • albertdata: gives you pretrained ALBERT model. The ALBERT is pretraind on distilled triplets of whole Pfam
  • Integrated: gives collected chemicals from several database
  • protein: gives you mapping from uniprot ID to triplets form

4. Generate clusters:

1. Cluster your protein dataset with `cdhit.sh`. Input is fasta file with all protein sequences in your dataset.
2. Apply multi-sequence alignment to the clusters with Clustal Omega. (`clustalo.sh`)
3. Build hmm profiles for the clusters with hmmbuild. (`hmmer_build.sh`)
4. Redo multi-sequence alignment with the hmm profiles and HMP clusters with HMMER. (`hmmer_align.sh`)
5. Construct corpus (singlets and triplets, represent sequence and all sequences) with `construct_hmp_singlets_and_triplets.py`. This step could take long if use only one CPU. Multiprocessing can significantly reduce computing time.
6. Generate TFRecord with the corpus with `create_tfrecords.sh`.

5. Run Finetuning

To run ALBERT model (default: ALBERRT frozen transformer):

python finetuning_train.py --protein_embedding_type="albert"

To try other freezing options, change "frozen_list" to choose modules to be frozen.

To run LSTM model:

python finetuning_train.py --protein_embedding_type="lstm"

distilled-and-architecture

disae's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

disae's Issues

question about the distilled triplets

I am still a bit confused about this file.Take the first senqunece 'A0A016RYG7' in the 'gpcr_uniprot2triplets.json' as an example,there are 210 conserved positions.
I don't understand how to get the distilled triplets of 'A0A016RYG7' like 'pnt ntp tpl pls' at the start because it seems no relation between the sequence of 'A0A016RYG7' in the Uniprot. I mean there is no 'pnt' in the sequence.

Thank you very much!

Question about "Amino acid conservation at each position is determined"

Hi, I am confused about the sentence "Amino acid conservation at each position is determined" in your paper. How could you get conservation score of each position? we could download them from database or we have to calculate in some way?

Could you please describe the process in as much detail as possible? Thank you very much!!!

Some problem about CODE-AE

i am sorry to contact with your team in this repository. the issue of CODE-AE (https://github.com/XieResearchGroup/CODE-AE) may be closed.
i have some problem about CODE-AE , and want to consult with your team.

  1. the stage of pretrian of CODE-AE, just use the cell lines gene expression, does not use the patients gene expression?
    in the pretrian_hyper_main.py, use the ccle_only=True pramater to get the cell lines data.
    Maybe I didn't understand it.
  2. the intermediate_results direction
    some data file in the intermediate_results direction, may be some results data, i just want to how to produce this result, they are come from your private code or just by CODE-AE.

thank you very much, Looking forward to your reply!

No module named "microbiomemeta"

Hello,
when I run the construct_singles_and_triplets.py file, the following problems occur:
—— ModuleNotFoundError:No module named "microbiomemeta"
But I can't get the installation package corresponding to "microbiomemeta" by searching online. Please tell me how to solve it? Thanks and best regards!

Question about cdhit.sh generate .clstr file and clustalo.sh

Hi, I have ran cdhit.sh and generated hmdb_cluster30.clstr,hmdb_cluster60.clstr,hmdb_cluster90.clstr,hmdb_cluster9060.clstr,hmdb_cluster906030.clstr, but I am confused about how to use them. Can you tell me how to use them.
And I also confued clustalo.sh , I want to know what file that HMDB_clustered_fasta stored, how to get them.
I'd appreciate it if you helped me.

question about "gpcr_uniprot2triplets.json"

I wonder what the document "gpcr_uniprot2triplets.json' means because I want to add some protein sequence to fine-tune the model,but I don't know how to get the representation like 210 triplest in this file.

Errors when running cdhit.sh

Hello, I have successfully installed cd-hit tool, but when I run cdhit.sh, the terminal will prompt the following errors:

.../DISAE-master/cdhit.sh: 行 33: psi-cd-hit.pl:未找到命令
.../DISAE-master/cdhit.sh: 行 37: clstr_rev.pl:未找到命令
.../DISAE-master/cdhit.sh: 行 42: clstr_rev.pl:未找到命令

which means that I don't have the above psi-cd-hit.pl clstr_rev.pl (but I can find them in the installation package of cd-hit)
Do you know how to solve it? Thanks and best regards.

kinase

Can you give mapping from uniprot ID of kinase to triplets form

Question about create_tfrecords.sh

Hi, I'm sorry for asking you so many questions. I have create singlet_representatives,singlets,triplet_representatives,triplets. And when I run create_tfrecords.sh, I found that I havn't got directory triplets_wo_IDs. I really want to know directory triplets_wo_IDs store what kind file and file content. I want to know the way to generate the directory and the content in the directory.
And I also find that some hmp_cluster_triplets files appear garbled problem, is that normal phenomenon?
I will be very grateful if you answer my question

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.