[gmx-developers] TPR parsing

David van der Spoel spoel at xray.bmc.uu.se
Sat Mar 9 10:18:33 CET 2013


On 2013-03-08 12:02, Gunther Lukat wrote:
> Hi,
> thank you for the hints.
> I will take a look into tpxio.h.
>
Why don't you simply link to the gromacs library and call the 
appropriate reading function?

Note that all floating point numbers are coded for portability using the 
xdr libraries, so it will be close to impossible to read with anything 
but the native code.
>
> Dipl.-Inf. Gunther Lukat
> www.aplvoro.org <http://www.aplvoro.org>
>
>
>
> Am 07.03.2013 um 15:18 schrieb Erik Marklund <erikm at xray.bmc.uu.se
> <mailto:erikm at xray.bmc.uu.se>>:
>
>> Note that the precision will be affected by printing by gmxdump and
>> subsequent reading by whatever program. So if you want to use the
>> exact numbers from the tpr, don't go through gmxdump.
>>
>> Erik
>>
>> On Mar 7, 2013, at 1:47 PM, francesco oteri wrote:
>>
>>> Hi gunther,
>>> as far as I know there is no library to parse tpr because it changes
>>> in nearly all the
>>> versions. In any case you can use the functions in include/tpxio.h.
>>> Alternatively, and depending upon the programming language you are
>>> going top use, I suggest you to parse the output of gmxdump.
>>> You can open I pipe directly inside your program (C,C++ and Python
>>> have this functionality) in order to make the interaction between the
>>> parser and gmxdump user-transparent!
>>>
>>> Francesco
>>>
>>>
>>> 2013/3/7 Gunther Lukat<g.lukat at gmx.net <mailto:g.lukat at gmx.net>>
>>>
>>>     Hello developers.
>>>
>>>     I am interested in accessing the binary .tpr files.
>>>
>>>     Is there a library like the xdr lib to read those .tpr files?
>>>
>>>
>>>     Greetings
>>>
>>>     Dipl.-Inf. Gunther Lukat
>>
>> --
>> gmx-developers mailing list
>> gmx-developers at gromacs.org <mailto:gmx-developers at gromacs.org>
>> http://lists.gromacs.org/mailman/listinfo/gmx-developers
>> Please don't post (un)subscribe requests to the list. Use the
>> www interface or send it to gmx-developers-request at gromacs.org.
>
>
>


-- 
David van der Spoel, Ph.D., Professor of Biology
Dept. of Cell & Molec. Biol., Uppsala University.
Box 596, 75124 Uppsala, Sweden. Phone:	+46184714205.
spoel at xray.bmc.uu.se    http://folding.bmc.uu.se



More information about the gromacs.org_gmx-developers mailing list