Re: [core] [Last-Call] Last Call: <draft-ietf-core-senml-more-units-02.txt> (Additional Units for SenML) to Proposed Standard

Carsten Bormann <> Thu, 31 October 2019 08:36 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 09464120876 for <>; Thu, 31 Oct 2019 01:36:57 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -4.199
X-Spam-Status: No, score=-4.199 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id VFT6fYIR8uh9 for <>; Thu, 31 Oct 2019 01:36:54 -0700 (PDT)
Received: from ( []) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 32D8D120864 for <>; Thu, 31 Oct 2019 01:36:54 -0700 (PDT)
Received: from ( []) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPSA id 473dwJ4L3DzywV; Thu, 31 Oct 2019 09:36:47 +0100 (CET)
Content-Type: text/plain; charset=utf-8
Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\))
From: Carsten Bormann <>
In-Reply-To: <>
Date: Thu, 31 Oct 2019 09:36:31 +0100
Cc: core <>
X-Mao-Original-Outgoing-Id: 594203789.584443-4faba0252243bc10d5aecee509e3914e
Content-Transfer-Encoding: quoted-printable
Message-Id: <>
References: <> <> <> <>
To: Hytonen Harri <>
X-Mailer: Apple Mail (2.3445.9.1)
Archived-At: <>
Subject: Re: [core] [Last-Call] Last Call: <draft-ietf-core-senml-more-units-02.txt> (Additional Units for SenML) to Proposed Standard
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Thu, 31 Oct 2019 08:36:57 -0000

(Limiting CC list to CoRE WG:)

> On Oct 31, 2019, at 08:17, Hytonen Harri <> wrote:
> As explained before, it's not matter of saving floating point calculations, but preserving the original precision of the measurement. 

I think this is an interesting statement.
This certainly was not the reason why we were going for the secondary units (as Ari said, these are about support for legacy data models).
But I’m still curious how, say, expressing precipitation in mm/h is preserving the precision better than expressing it in m/s after scaling it by 3.6e6.  Sure, that floating point calculation has a rounding error, but that will usually be on the order of 1/2**24 (or 1/2**53 if your sensor has double precision floating point), while the instrument resolution is likely on the order of 1/2**10 or 1/2**12 (as you can see, I know nothing about precipitation sensors).

Note that formats such as CBOR or JSON cannot *indicate* precision or accuracy (or uncertainty in general) within a single number; there is no way to say what conventionally is written down as 8.0 vs. 8.000 (even in JSON, where both forms can be written, these have exactly the same semantics).  So that would be a separate issue (easily addressed by putting information about the uncertainty into separate numbers, often in the metadata as it often doesn’t change between measurements).

Note also that the terminology here often requires clarification or explicit referencing; e.g., IEEE 754 uses “precision” essentially for “resolution”, not for “precision” as used in metrology(*) (which is essentially “repeatability” and “reproducibility” in the VIM [1]).

Grüße, Carsten

“International vocabulary of metrology — Basic and general concepts and associated terms (VIM)”

(*) applying metrology to meteorology sensors :-)