-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add units to ExtraBytes attribute definition #60
Comments
In my opinion, self-documenting the units makes ExtraBytes harder to implement because it puts the burden of synchonizing units onto the developer, not the data user. For that reason I'm reluctant to make this change, especially if we provide a mechanism for alternative units. I'm open to differing opinions. |
On the other hand, this provides a very elegant solution for the question about representing different levels of precision for an ExtraByte. For example, one could represent Height From Ground in units of decimeters, centimeters, or Tenths of a Foot if one so desired, without having to change the data_type. |
Can @rapidlasso comment on how alternative units are supposed to work? Does one select their primary unit from amongst the alternatives? Are there only three allowed for a given standard ExtraByte, or is this up to the user to decide? Do we have to provide a standard list of ExtraByte units somewhere, or do we rely on the EPSG list? What if there's a unit not supported by WKT, such as decibels for Riegl Reflectance? As @hobu observed here this isn't as simple as deciding between meters and feet. |
Also tagging @kjwaters because he was the one that brought this up in the first place. :) |
I still prefer hard-coded metric units for storage purposes. In any software has to present them in other units to their users ... a unit conversion really is not rocket science. Although having an overly complex scheme to define units may explode a rocket if boosters are launched too late or too early due to an incorrectly parsed unit description. If we add a unit description it should not happen in this release. A hasty solution will definitely blow up spaceships. Let's go with hard coded metric units for this release and brainstorm if and how other units should be supported. |
The "extra space" could be used to describe two alternate units as follows. After deprecating "tuples" and "triples" we could reuse the array entires [1] and [2] of no_data, min, max, scale, and offset. Below my "old" struct of 192 bytes that is the payload of the official "extra bytes" VLR.
and - just to present a tangible example - we could re-use it as shown below to offer two alternate units assuming the conversion can be done by changing the scale and the offset.
Originally posted by @rapidlasso in #37 (comment)
The text was updated successfully, but these errors were encountered: