Skip to content
GitLab
    • Why GitLab
    • Pricing
    • Contact Sales
    • Explore
  • Why GitLab
  • Pricing
  • Contact Sales
  • Explore
  • Sign in
  • Get free trial
  • GROMACS
  • GROMACS GROMACS
  • Issues
  • #3774

Converge on gmxapi Context as the only way to manage running a simulation

There are currently three ways to manage running a simulation within the current source:

  • by invoking a gmxapi::Workflow on a gmxapi::Context
  • by calling gmx mdrun
  • by using gmx::test::SimulationRunner in the mdrun integration tests

There's noteworthy duplication between the first and both of the subsequent two. Having to consider all three use cases complicates #3688 (closed) because responsibility for initializing MPI libraries is handled in three places. Likewise #3768 (closed) needs similar changes in three places.

In the long term, we should use only one way to run a simulation. Simplest and most generalizable is to re-use the gmxapi implementation for the other two. That prepares for re-using some of the infrastructure currently used for testing to provide capabilities to the user also via the API.

Tasks have been identified to achieve this:

  • Discuss with nblib any efforts to re-use or further de-duplicate
  • Make gmx::test::SimulationRunner use a gmxapi::Context to run mdrun
  • Identify an approach that lets gmx::test::SimulationRunner call grompp
  • Make gmx::test::SimulationRunner use that approach to call grompp
  • Understand whether the apparent need to broadcast gmx command-line arguments before invoking gmx_mdrun can be resolved within the approach of gmxapi::Context
  • Have gmx infrastructure implement gmx mdrun by creating a gmxapi::Context and transforming the command-line arguments to a gmxapi::Workflow
  • Move sole responsibility for MPI library initialization to gmxapi::Context (see also #3688 (closed))
  • Eliminate any superseded infrastructure, e.g. gmx::init()/finalize()
Edited Mar 02, 2021 by Mark Abraham
Assignee
Assign to
Time tracking