TechnionYP5779 / SimuMole

Computer simulation method that displays the physical movements of atoms and molecules.
5 stars 0 forks source link

issue #97: add a live simulation progress log #99

Closed IlanitSmul closed 5 years ago

IlanitSmul commented 5 years ago

Description:

Immediately after the user clicks on the "submit" button, he moved to the page "create_simulation_result.html" (the address is not changed, it is still "create_simulation").

This page shows the following steps in the simulation creation process:

  1. Processing your parameters: Preparation before using OpenMM, for example: loading the PDB files, determining the relative position, merging into a single PDB file, and calls to "fix_pdb" function.
  2. Minimizing energy (this is one of the steps that OpenMM performs).
  3. Equilibrating (this is one of the steps that OpenMM performs).
  4. Running simulation (this is one of the steps that OpenMM performs): Two details are displayed: "Progress" and "Remaining time".
  5. Done.

Notes about the implementation:

In order to complete this feature, I used the "AJAX request", which allows us to update an html page without refreshing. The AJAX request makes repeated calls to a view function (called "update_simulation_status"), which checks the status of the run by reading the files that updated by the thread running the simulation. Both files are saved under "media/ files" folder. File Description:

Sample screenshots:

image

image

image