[GRASS-dev] [GRASS GIS] #618: rfe: r.md5sum or equivalent

#618: rfe: r.md5sum or equivalent
-----------------------------------------+----------------------------------
Reporter: hamish | Owner: grass-dev@lists.osgeo.org
     Type: enhancement | Status: new
Priority: normal | Milestone: 6.5.0
Component: Raster | Version: svn-trunk
Keywords: testsuite, r.univar, md5sum | Platform: All
      Cpu: All |
-----------------------------------------+----------------------------------
Hi,

It would be helpful for comparing maps if there was some r.md5sum or
equivalent.

Actually I think a new flag for r.univar might be all that is needed.

presently this is what we got, and it's a bit less than optimal,
especially for quickly running through a test suite
{{{
r.mapcalc diff=map1-map2
r.univar diff
g.remove diff
}}}

thanks,
Hamish

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/618&gt;
GRASS GIS <http://grass.osgeo.org>

#618: rfe: r.md5sum or equivalent
--------------------------+-------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: enhancement | Status: new
  Priority: normal | Milestone: 6.5.0
Component: Raster | Version: svn-trunk
Resolution: | Keywords: testsuite, r.univar, md5sum
  Platform: All | Cpu: All
--------------------------+-------------------------------------------------
Old description:

Hi,

It would be helpful for comparing maps if there was some r.md5sum or
equivalent.

Actually I think a new flag for r.univar might be all that is needed.

presently this is what we got, and it's a bit less than optimal,
especially for quickly running through a test suite
{{{
r.mapcalc diff=map1-map2
r.univar diff
g.remove diff
}}}

thanks,
Hamish

New description:

Hi,

It would be helpful for comparing maps if there was some r.md5sum module
or equivalent.

Actually I think a new flag for r.univar might be all that is needed.

presently this is what we got, and it's a bit less than optimal,
especially for quickly running through a test suite:
{{{
r.mapcalc diff=map1-map2
r.univar diff
g.remove diff
}}}

thanks,
Hamish

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/618#comment:1&gt;
GRASS GIS <http://grass.osgeo.org>

#618: rfe: r.md5sum or equivalent
--------------------------+-------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: enhancement | Status: new
  Priority: normal | Milestone: 6.5.0
Component: Raster | Version: svn-trunk
Resolution: | Keywords: testsuite, r.univar, md5sum
  Platform: All | Cpu: All
--------------------------+-------------------------------------------------
Comment (by hamish):

see also [source:grass/trunk/testsuite/raster/raster_md5test.sh] for a
r.out.ascii | md5sum solution

Hamish

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/618#comment:2&gt;
GRASS GIS <http://grass.osgeo.org>

#618: rfe: r.md5sum or equivalent
--------------------------+-------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: enhancement | Status: new
  Priority: normal | Milestone: 6.5.0
Component: Raster | Version: svn-trunk
Resolution: | Keywords: testsuite, r.univar, md5sum
  Platform: All | Cpu: All
--------------------------+-------------------------------------------------
Comment (by glynn):

Replying to [ticket:618 hamish]:

> It would be helpful for comparing maps if there was some r.md5sum module
or equivalent.

What '''exactly''' should this module compute? MD5 and other hash
algorithms operate on a sequence of bytes, so you need to decide exactly
how to serialise the data.

Should it operate upon the raw map data, or after reclassing, MASKing, and
clipping and resampling according to the current region? How are nulls
represented? Are numeric values serialised big-endian, little-endian, or
in the host's native format? Or as decimal values in ASCII?

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/618#comment:3&gt;
GRASS GIS <http://grass.osgeo.org>

#618: rfe: r.md5sum or equivalent
--------------------------+-------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: enhancement | Status: new
  Priority: normal | Milestone: 6.5.0
Component: Raster | Version: svn-trunk
Resolution: | Keywords: testsuite, r.univar, md5sum
  Platform: All | Cpu: All
--------------------------+-------------------------------------------------
Comment (by hamish):

- for this task we care about data not how it is stored, so probably after
endian translation
  - not sure if the differences in how FPs are stored makes this an
impossiblity. (false negatives)
  - probably for this task we care about entire map not subregion(?) so not
clipped to current region. or maybe you want to check that a subregion is
the same (eg r.patch result..)

?,
H

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/618#comment:4&gt;
GRASS GIS <http://grass.osgeo.org>

#618: rfe: r.md5sum or equivalent
--------------------------+-------------------------------------------------
  Reporter: hamish | Owner: grass-dev@…
      Type: enhancement | Status: closed
  Priority: normal | Milestone: 6.5.0
Component: Raster | Version: svn-trunk
Resolution: fixed | Keywords: testsuite, r.univar, md5sum
  Platform: All | Cpu: All
--------------------------+-------------------------------------------------
Changes (by hamish):

  * status: new => closed
  * resolution: => fixed

Comment:

done as g.md5sum addon, see source:grass-addons/grass6/general/g.md5sum

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/618#comment:5&gt;
GRASS GIS <http://grass.osgeo.org>