diff --git a/mdpow/equil.py b/mdpow/equil.py index 1f2fe7ab..247274b3 100644 --- a/mdpow/equil.py +++ b/mdpow/equil.py @@ -55,8 +55,10 @@ # BOX <-- forcefields.get_solvent_model(id).coordinates +# TODO: change to water distance 1.2 in the future (1.0 for +# compatibility with our SAMPL5 runs) #: minimum distance between solute and box surface (in nm) -DIST = {'water': 1.2, 'octanol': 1.5,'cyclohexane':1.5} +DIST = {'water': 1.0, 'octanol': 1.5, 'cyclohexane': 1.5} class Simulation(Journalled): @@ -186,7 +188,8 @@ def __init__(self, molecule=None, **kwargs): raise ValueError(msg) self.solventmodel = forcefields.get_solvent_model(self.solventmodel_identifier) - distance = kwargs.pop('distance', DIST[solvent]) + distance = kwargs.pop('distance', None) + distance = distance if distance is not None else DIST[solvent] self.solvent = AttributeDict(itp=self.solventmodel.itp, box=self.solventmodel.coordinates, diff --git a/mdpow/run.py b/mdpow/run.py index e674bd9a..679e3f7b 100644 --- a/mdpow/run.py +++ b/mdpow/run.py @@ -203,7 +203,7 @@ def equilibrium_simulation(cfg, solvent, **kwargs): # custom mdp files mdpfiles = get_mdp_files(cfg, Simulation.protocols) try: - distance = cfg.get('setup','distance') + distance = cfg.get('setup', 'distance') except KeyError: distance = None # if no distance is specified, None = default