Re: [AMBER] Different number of processes give different nonbonded energy in sander trajectory analysis

From: Daniel Roe via AMBER <amber.ambermd.org>
Date: Thu, 20 Mar 2025 08:36:11 -0400

Hi,

Is this from a trajectory generated in the NPT ensemble (i.e. the box
size changes)? If so, that could be the source of the discrepancy; I'm
not certain but I think that the imin=5 code will adjust PME
parameters based on box sizes for each input frame where the box size
changes. That would fit with only the nonbonded terms changing. If I
get a free moment I'll try to look into this further.

If you have an NVT trajectory you could try that and see if you still
see the same differences.

-Dan

On Thu, Mar 20, 2025 at 7:43 AM Yunhao Mei via AMBER <amber.ambermd.org> wrote:
>
> Dear AMBER developers and users,
>
>
>
> I recently encountered an issue when using sander with imin=5 to extract energy from a trajectory. Specifically, I observed that sander.MPI produced different nonbonded energy values when different numbers of processes were used. For example:
>
>
>
> With mpirun -np 4:
>
>
> NSTEP ENERGY RMS GMAX NAME NUMBER
> 1 -1.3656E+05 1.6835E+01 1.3896E+02 O 34549
> BOND = 684.2128 ANGLE = 1452.6058 DIHED = 1207.5225
> VDWAALS = 20144.5207 EEL = -172841.5000 HBOND = 0.0000
> 1-4 VDW = 1038.9863 1-4 EEL = 11518.6327 RESTRAINT = 0.0000
> CMAP = 239.2315
> minimization completed, ENE= -.13655579E+06 RMS= 0.168353E+02
> |Largest sphere to fit in unit cell has radius = 31.533
>
>
>
> With mpirun -np 8:
>
>
> NSTEP ENERGY RMS GMAX NAME NUMBER
> 1 -1.3653E+05 1.6819E+01 1.1655E+02 CG 3132
> BOND = 684.2128 ANGLE = 1452.6058 DIHED = 1207.5225
> VDWAALS = 20145.8189 EEL = -172818.4430 HBOND = 0.0000
> 1-4 VDW = 1038.9863 1-4 EEL = 11518.6327 RESTRAINT = 0.0000
> CMAP = 239.2315
> minimization completed, ENE= -.13653143E+06 RMS= 0.168189E+02
> |Largest sphere to fit in unit cell has radius = 31.533
>
>
>
> However, when I set imin=1 for structure optimization, the results from np=4 and np=8 showed only minor energy differences, with each term varying by no more than 0.001, while GMAX remained identical. This suggests that the issue is specific to trajectory analysis. Given that the differences in energy and gradients are not negligible, I suspect that there might be an issue in the trajectory analysis implementation of sander.MPI.
>
>
> I would appreciate any insights or suggestions regarding this behavior. Thank you for your time and help.
>
>
> Best regards,
>
>
> Yunhao Mei
> College of Chemistry and Chemical Engineering
> Peking University
>
>
>
>
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber

_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Thu Mar 20 2025 - 06:00:02 PDT
Custom Search