ccsb-scripps / AutoDock-Vina

AutoDock Vina
http://vina.scripps.edu
Apache License 2.0
561 stars 199 forks source link

different score results from different no_of_poses parameter setting #232

Open jaehongshin opened 10 months ago

jaehongshin commented 10 months ago

I tested with different "no_of_poses" parameter values, then vina scores turn different values quite a lot (e.g. ~2kcal/mol) Are there any other randomness or heuristic things during docking besides the seed. I fixed the all other parameters but "no_of_poses"

diogomart commented 10 months ago

Are scores different for the first pose, or only from the second and subsequent poses?

jaehongshin commented 10 months ago

I have done two individual dockings with the same seed but different value(1, 20) of the "no_of_poses" parameter. The first pose 's scores from two dockings were compared: one score from the "no_of_poses" set to 1 and another score from the default(20) with the same input and the same seed.

diogomart commented 10 months ago

Tried with a system and can't reproduce. Got very similar first poses and very similar scores (-7.090 vs -7.063). Could you share your files and commands/scripts to reproduce?

jaehongshin commented 10 months ago

Sorry for the delay. I cannot share the structure because I am working on a project. The script is very similar to the tutorial example. I compared the first pose from v.energies() Something like this below:

docking

v.dock(exhaustiveness=8, n_poses=20)

#vina docking energy
energies = v.energies()

scores = v.score()

# Minimized locally the current pose
energy_minimized = v.optimize()

print("Results:", energies[0][0], scores[0], energy_minimized[0])
jaehongshin commented 10 months ago

I also did another test with the 1iep_ligand.sdf file by converting pdbqt using meeko. (I also used a similar script to above) I ran 10 times with the randomization of initial conformer, then compared three scores after each docking: 1)an energy score from the first pose using v.energies(), 2) a score using v.score(), and 3) a minimized score using v.opimize() Here is the results average_energy : -13.2638750 (SD: 0.4293485) average_score: -13.2632500 (SD: 0.0106066) average_minimized: -13.20925000 (SD: 0.01343503)

The energy score seems to have a bit large deviation during the multiple runs compared to v.optimize() which calculated by BFGS However, in the pose pdbqt file, I found the energy score is written not one from the v.optimize(). (v.write_poses('', n_poses=1, overwrite=True))

Which score should I use for the score assessment ? Also which vina 1.2 score does it correspond to the score in vina1.1.2 ?

Thank you in advance

diogomart commented 10 months ago

In my tests v.energies()[0][0] and v.score()[0] match exactly. This is the value that is printed to "REMARK VINA RESULT" in output PDBQTs both in v1.1.2 and v1.2.*. Not sure why your average scores (and SDs) differ.

Docking runs local search internally, both during the docking and then again at the end of docking. Thus, v.optimize() should have no noticeable effect, but there is another variable at play, which is whether or not the precalculated grid maps are used to calculate interaction energies involving receptor atoms. The alternative to that is to calculate interactions directly between pairs of atoms, which is slower because receptors typically have many atoms. The local search at the end of docking uses direct interactions, while v.optimize() uses grid maps. We should eventually use direct interactions in v.optimize() (as requested in #67 ) but didn't get to it yet. That is why v.optimize() returns systematically worse (higher) energies.

diogomart commented 10 months ago

Which score should I use for the score assessment ?

Use v.energies()[0][0]. No need to call v.score() as it is called inside v.dock() to populate the energies that are returned by v.energies().