marrink-lab / vermouth-martinize

Describe and apply transformation on molecular structures and topologies
Apache License 2.0
97 stars 43 forks source link

ENH: run_residue method for Processor #375

Open pckroon opened 3 years ago

pckroon commented 3 years ago

Some workloads are done per residue, such as repair graph. This would result in an appealing target for multiprocessing (separate molecules will have very different sizes, but residues will be roughly the same size).

The pipeline invokes run_system on all processors in order. The default implementation of this is to call run_molecule, which must currently be overridden by processor implementations. I suggest the default implementation will call a run_residue method, which must be overridden by implementations. This is a non-breaking/opt-in change, since all processors currently implement their own run_molecule method, and are thus not affected by this.