cusbg / prankweb

Web application for protein-ligand binding sites analysis and visualization
https://prankweb.cz
Apache License 2.0
9 stars 4 forks source link

Different prediction results for alphafold structures #142

Closed AlexLam37 closed 5 months ago

AlexLam37 commented 6 months ago

Pocket probability is different if i input through "Predicted structure" (Alphafold uniprot ID) vs if I download the Alphafold structure off uniprot and running on "Custom structure"

For example if I input A0A644EZV9 into Predicted structure I get a pocket probability that I expect Screen Shot 2024-04-05 at 12 36 16 pm But if I download the A0A644EZV9 alphafold structure off uniprot and upload that as a "Custom structure" I get different results? Screen Shot 2024-04-05 at 12 38 56 pm

Any help would be great as I intend to use the standalone p2rank to perform many predictions, but it seems that p2rank performance for my downloaded structures are not as good as I expect?

davidhoksza commented 5 months ago

Thanks for reporting this @AlexLam37 !

The problem is that PrankWeb has two different models, one for X-ray structures and one for AF structures. The reason is, that when predicting binding sites from X-ray structures, we use the atoms' b-factors as one of the features. However, AF models use the b-factor field to store information about prediction confidence. Therefore, we have a separate model that does not use the b-factor field and this model is used for AF structures. That is the reason we have two models.

Now, when the user chooses to use a predicted structure, the server knows it is an AF structure and forces P2Rank (the backend tool that serves PrankWeb with predictions) to use the appropriate model. But when you upload the structure, there is no way to find out that it is actually a CIF file with an AF model, and the server by default uses the default model which uses the b-factor field as one of the features. Which is wrong in this case, because the values in the b-factor field are not b-factors and this can lead to wrong predictions. Anyway, the reason why you are seeing different predictions is that two different models are used.

Currently, there is no direct solution. We are considering enabling the user to specify whether he or she is uploading an AF model when using the "Custom structure" feature. But it will take a week or so.

davidhoksza commented 5 months ago

One more thing @AlexLam37 . If you want to use the standalone version, you can specify a model. You can do it via the -c option where you specify the config within which you can set the model. And you will probably use this one for AF structures.

rdk commented 5 months ago

Actually it's this one from distro dir which gets packed into the release tar.gz.

You can use it like this: prank predict -c alphafold ...

AlexLam37 commented 5 months ago

Thank you,

I did in fact run prank predict -c alphafold. however for the example above, it did not match either prankweb scores (see below). I also tried running -c alphafold_conservation_hmm but the scores were lower than that of -c alphafold

image