[gmx-developers] Understanding disparity in field values of "t_state" class

Sanyam Kapoor sanyam at nyu.edu
Thu Mar 1 22:20:50 CET 2018


That is right. It is the PaddedRVecVectors.

Just to clarify if I understand correctly, I can safely use the first
*natoms* positions from the PaddedRVecVectors without worrying about the
rest. Is that correct?

On Thu, Mar 1, 2018 at 4:11 PM Berk Hess <hess at kth.se> wrote:

> Hi,
>
> state->natoms is the count. But note that this will not match the topology
> when you are using domain decomposition.
>
> In your case it looks like the mismatch is due to padding for SIMD
> operations. The extra elements will not be used to generate results.
>
> Cheers,
>
> Berk
>
>
> On 03/01/2018 10:04 PM, Sanyam Kapoor wrote:
>
> @Mark Sorry to have left the version information out. I'm currently pinned
> to version *v2018*.
>
> @Erik I can't seem to find another count variable. Do you mind pointing me
> to it? Also, just to put it out, I'm trying to inspect this after the
> threads have been joined (right before the return). Is there a way for me
> to find one-to-one correspondence between the atom number and this state
> structure?
>
> Thank you so much for the prompt responses!
>
> On Thu, Mar 1, 2018 at 3:59 PM Mark Abraham <mark.j.abraham at gmail.com>
> wrote:
>
>> Hi,
>>
>> What Erik said, plus also this behaviour varies whether there is more
>> than one rank, whether there are virtual sites, and with GROMACS version.
>>
>> Mark
>>
>> On Thu, Mar 1, 2018 at 9:57 PM Erik Lindahl <erik.lindahl at gmail.com>
>> wrote:
>>
>>> Hi Sanyam,
>>>
>>> Not entirely sure what your debugger reports, but it is likely due
>>> either to padding (which we do to avoid false sharing between threads), or
>>> over-allocation (which we do to avoid repeatedly re-allocating and freeing
>>> memory when particles drift between nodes during domain decomposition).
>>>
>>> This is also why we have separate fields to keep track of the number of
>>> atoms vs. the number of allocated entries.
>>>
>>> Cheers,
>>>
>>> Erik
>>>
>>> On Thu, Mar 1, 2018 at 9:52 PM, Sanyam Kapoor <sanyam at nyu.edu> wrote:
>>>
>>>> Hello everyone,
>>>>
>>>> I was trying to understand fields in the t_state class and it looks
>>>> like there is some disparity during the run which I cannot make sense of. I
>>>> ran the code for two topologies experiments with the following arguments
>>>>
>>>> mdrun -s m.tpr -rerun m.gro -e m.edr -g m.log
>>>>
>>>> 1. A topology which had *1960 atoms *but the *fields for coordinates
>>>> (x) and velocities (v) had 1968* items.
>>>> 2. A topology which had *1793 atoms *but the *fields for coordinates
>>>> (x) and velocities (v) had 1808* items.
>>>>
>>>> These numbers that I am reporting have been retrieved while debugging
>>>> for the fields natoms, x and v of t_state.
>>>>
>>>> The comments for t_state state that the lists should have been of the
>>>> same size as number of atoms. However this doesn't seem to be the case.
>>>> Could somebody verify if this is expected? If yes, why so?
>>>>
>>>> Thank you!
>>>> --
>>>> Regards,
>>>> Sanyam Kapoor
>>>> Masters in Computer Science
>>>> Courant Institute, New York University
>>>> https://www.sanyamkapoor.com
>>>>
>>>> --
>>>> Gromacs Developers mailing list
>>>>
>>>> * Please search the archive at
>>>> http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List
>>>> before posting!
>>>>
>>>> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>>>>
>>>> * For (un)subscribe requests visit
>>>> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers
>>>> or send a mail to gmx-developers-request at gromacs.org.
>>>>
>>>
>>>
>>>
>>> --
>>> Erik Lindahl <erik.lindahl at dbb.su.se>
>>> Professor of Biophysics, Dept. Biochemistry & Biophysics, Stockholm
>>> University
>>> Science for Life Laboratory, Box 1031, 17121 Solna, Sweden
>>> --
>>> Gromacs Developers mailing list
>>>
>>> * Please search the archive at
>>> http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List before
>>> posting!
>>>
>>> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>>>
>>> * For (un)subscribe requests visit
>>> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers
>>> or send a mail to gmx-developers-request at gromacs.org.
>>
>> --
>> Gromacs Developers mailing list
>>
>> * Please search the archive at
>> http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List before
>> posting!
>>
>> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>>
>> * For (un)subscribe requests visit
>> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers
>> or send a mail to gmx-developers-request at gromacs.org.
>
> --
> Regards,
> Sanyam Kapoor
> Masters in Computer Science
> Courant Institute, New York University
> https://www.sanyamkapoor.com
>
>
>
> --
> Gromacs Developers mailing list
>
> * Please search the archive at
> http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List before
> posting!
>
> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>
> * For (un)subscribe requests visit
> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers
> or send a mail to gmx-developers-request at gromacs.org.

-- 
Regards,
Sanyam Kapoor
Masters in Computer Science
Courant Institute, New York University
https://www.sanyamkapoor.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://maillist.sys.kth.se/pipermail/gromacs.org_gmx-developers/attachments/20180301/3baff7f8/attachment-0001.html>


More information about the gromacs.org_gmx-developers mailing list