Project

General

Profile

Task #3076

Selectively activate MdModules during simulation instead of instantiating all of them

Added by Christian Blau 5 months ago. Updated 12 days ago.

Status:
New
Priority:
Normal
Category:
core library
Difficulty:
uncategorized
Close

Description

Change the interface to MdModules that allows the MdModules to subscribe to callbacks only after they know if they are active or not so that we avoid the

if (module.active())

within the modules that may be to easily overlooked.

History

#1 Updated by Christian Blau 12 days ago

Selective activation of the modules is easier when MdModules don't have to be constructed with the notifications early on, but can be handed the notification handles later.

Currently all notifications are subscribed to during module construction, but some notifications will only be needed during pre-processing at grompp-time, while others are only needed during md run setup, thus

- split notifications into pre-processing notifications, notifications during simulations, and checkpointing notifications
- hand over notification handle for pre-processing callbacks and simulation callbacks seperately instead of all of them at construction time
- callback notifications only if modules are active

Also available in: Atom PDF