Core 1: Biomedical Computation Research


OpenMM: particle mechanics simulation



Download 0.87 Mb.
Page2/9
Date01.02.2018
Size0.87 Mb.
#37590
1   2   3   4   5   6   7   8   9

1.2 OpenMM: particle mechanics simulation


Particle mechanics is the key capability required for the molecular scale and mesoscale DBPs. In the previous grant period, we developed OpenMM, a library for performing molecular mechanics on high performance computing architectures [2]. A key design goal of OpenMM was very high performance on multicore architectures. The GPU-acceleration code in OpenMM resulted from a four-year collaboration among the Hanrahan, Darve and Pande labs [3]. Subsequent work from the labs of Klaus Schulten [1], Gianni De Fabritiis [4] and others further developed these methods, particularly in the realm of fine-grained parallelism over multiple GPUs. Nevertheless, OpenMM remains the leader in terms of both single GPU performance as well as schemes for parallelism over tens of thousands of GPUs (see Progress Report).

We propose to build a fully functional DSL for particle dynamics as described in the next 3 subsections.


1.2.1 Generalize OpenMM to a Particle Simulation DSL


We propose to develop OpenMM into a full Domain Specific Language (DSL). This will allow rapid development of novel physics in particle dynamics important for many scales, including the atomic/molecular scale (e.g. novel implicit solvent models) and the mesoscale (important to explore and improve functional forms for particle interactions).
Figure 1.1. Scaling for adaptive sampling: speed-up of a protein folding simulation vs the number of independent trajectories (plotted as log10 (# trajectories) versus log10 (1/Time)) used at each round of sampling, based on estimates from a pre-built MSM for the folding of the villin headpiece. Wall-clock time scaling is linear up to a billion trajectories (thus scaling to a billion cores with 1 core (or more) per trajectory). The black line is a best fit to the linear portion of the data (circles).

We will add the ability to code novel OpenMM interactions (for bonded, non-bonded, and even implicit solvent interactions) directly in terms of mathematical formulae, rather than coding these for a specific multicore architecture. A programmer provides equations for the potential energy of the interaction and OpenMM will calculate the needed derivatives, optimize expressions, and link the new interactions into the appropriate platform libraries. For example, consider nonbonded interactions, such as van der Waals interactions. Many different mathematical forms are used to represent nonbonded interactions in molecular simulations, differing, for example, in how they model van der Waals interactions, smoothing of cutoffs, and solvent screening effects. Ideally, programmers should be able to choose the functional forms of the interactions and expect them to be computed efficiently on the available hardware. We can accomplish this goal through the CustomNonbondedForce class. This class allows the user to specify an arbitrary mathematical function for the pairwise energy between atoms. That function may depend on an arbitrary set of atomic parameters and tabulated functions, as well as a variety of standard mathematical functions. For example, the following lines of code create a CustomNonbondedForce to calculate a Lennard-Jones 12-6 interaction:

CustomNonbondedForce nb("4*epsilon*((sigma/r)^12-(sigma/r)^6);"

"sigma=0.5*(sigma1*sigma2); epsilon=sqrt(epsilon1*epsilon2)");

nb.addPerParticleParameter("sigma");

nb.addPerParticleParameter("epsilon");


The first line specifies the energy of the interaction in the common 12-6 Lenard-Jones function; the second line designates that the two interacting atoms are merged using Lorentz-Bertelot combining rules (the arithmetic mean of the sigmas and the geometric mean of the epsilons). The next two lines specify that the parameters “sigma” and “epsilon” should be associated with each atom. OpenMM would implement this efficiently on a variety of hardware platforms by parsing the user-specified expressions and analytically differentiating the energy to determine an expression for the force; each expression is then converted to a sequence of instructions and then compiled down to the device’s machine code, eliminating the cost of interpreting the expression and yielding nearly as fast performance as if the entire kernel had been written by hand.




Download 0.87 Mb.

Share with your friends:
1   2   3   4   5   6   7   8   9




The database is protected by copyright ©ininet.org 2024
send message

    Main page