[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [h5md-user] Unit attribute versus non-dimensionless quantities

From: Konrad Hinsen
Subject: Re: [h5md-user] Unit attribute versus non-dimensionless quantities
Date: Mon, 9 Sep 2013 12:37:48 +0200

Pierre de Buyl writes:

 > I think that v1.0 should not specify anything unit-related
 > [1]. This will be missed but as I see it, the only "good" solution
 > is to use named types. Using the unit attribute is, in light of the
 > recent discussions too limited. And we don't want to have a dual
 > solution as a basis for the future.

I don't see how I could use H5MD in any meaningful way if the data has
neither explicit unit information nor any convention about the unit
system being applied. At the very least, the specification should
contain certain constraints that reading programs can rely on.  For
example, one could say that the units of the positions divided by the
units of the time labels must be the same as the units of any velocity

Like for the species information, a possible way to procrastinate
about this is to introduce conventions, to be defined externally to
H5MD. However, unlike for species, I am not sure it's a good solution,
because unit information is much more fundamental than species
information. Generic programs reading H5MD files should not have to
know about a dozen different conventions.

For Mosaic, I decided to store units as strings conforming to a subset
of the udunits specification
stored in an attribute. Mosaic always stores dimensional data in
datasets, not in attributes, so it doesn't have the same problem as

BTW, I wonder if storing data in attributes is really worth the
trouble it generates, considering units or in fact any other kind of
annotation.  If size is the motivation, then compact datasets can
provide nearly the same advantages without the inconvenience.

Konrad Hinsen
Centre de Biophysique Moléculaire, CNRS Orléans
Synchrotron Soleil - Division Expériences
Saint Aubin - BP 48
91192 Gif sur Yvette Cedex, France
Tel. +33-1 69 35 97 15
E-Mail: research AT khinsen DOT fastmail DOT net
ORCID: http://orcid.org/0000-0003-0330-9428
Twitter: @khinsen

reply via email to

[Prev in Thread] Current Thread [Next in Thread]