code patches item #281, was opened at 2007-02-10 21:30
Status: Open
Priority: 3
Submitted By: Māris Nartišs (marisn)
Assigned to: Nobody (None)
Summary: Fix for gis.m profile dialog division by zero
Patch status: None
Patch type: fix
GRASS component: gis.m
GRASS version: CVS HEAD
GRASS CVS checkout date, if applies (YYMMDD): 070210
Initial Comment:
This patch prevents gis.m profile tool from dividing by zero and makes popup windows to appear on top of profile window and not gis.m main window.
Do you know what is making this divide by 0 and under what circumstances
(e.g., range of elevation values on map, location/projection
characteristics)? On my system, with a build of 2 days ago, the profiling
works fine with the "normal" map of the Spearfish 30m DEM.
This happened a couple times before when the GRASS module used for
calculating the total elevation range was giving incorrect information in
certain circumstances and when there were changes in the function of
g.region flags. It was an example of the cascade of effects that can happen
if a module function is changed in seemingly minor ways.
The error trapping is a good idea in any case. But I want to make sure we
also understand the cause rather than just treat the symptoms.
Michael
On 2/10/07 12:30 PM, "grass-codepatches@wald.intevation.org"
<grass-codepatches@wald.intevation.org> wrote:
code patches item #281, was opened at 2007-02-10 21:30
Status: Open
Priority: 3
Submitted By: M?ris Narti¹s (marisn)
Assigned to: Nobody (None)
Summary: Fix for gis.m profile dialog division by zero
Patch status: None
Patch type: fix
GRASS component: gis.m
GRASS version: CVS HEAD
GRASS CVS checkout date, if applies (YYMMDD): 070210
Initial Comment:
This patch prevents gis.m profile tool from dividing by zero and makes popup
windows to appear on top of profile window and not gis.m main window.
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University
it will divide by zero on any non-normal map - think of binary map (1,null).
It has no sense for such maps to create profiles, but it does not mean
that gis.m should fail if user is dumb. It's one of my thisweekends
efforts to make gis.m foolproof.
Maris.
2007/2/11, Michael Barton <michael.barton@asu.edu>:
Maris,
Do you know what is making this divide by 0 and under what circumstances
(e.g., range of elevation values on map, location/projection
characteristics)? On my system, with a build of 2 days ago, the profiling
works fine with the "normal" map of the Spearfish 30m DEM.
This happened a couple times before when the GRASS module used for
calculating the total elevation range was giving incorrect information in
certain circumstances and when there were changes in the function of
g.region flags. It was an example of the cascade of effects that can happen
if a module function is changed in seemingly minor ways.
The error trapping is a good idea in any case. But I want to make sure we
also understand the cause rather than just treat the symptoms.
Michael
On 2/10/07 12:30 PM, "grass-codepatches@wald.intevation.org"
<grass-codepatches@wald.intevation.org> wrote:
> code patches item #281, was opened at 2007-02-10 21:30
> Status: Open
> Priority: 3
> Submitted By: M?ris Nartiðs (marisn)
> Assigned to: Nobody (None)
> Summary: Fix for gis.m profile dialog division by zero
> Patch status: None
> Patch type: fix
> GRASS component: gis.m
> GRASS version: CVS HEAD
> GRASS CVS checkout date, if applies (YYMMDD): 070210
>
> Initial Comment:
> This patch prevents gis.m profile tool from dividing by zero and makes
popup
> windows to appear on top of profile window and not gis.m main window.
>
> ----------------------------------------------------------------------
>
> You can respond by visiting:
> http://wald.intevation.org/tracker/?func=detail&atid=205&aid=281&group_id=21
>
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University
OK. If it's for foolproofing, then the error trap is perfect. I just wanted
to make sure that there was no new systematic problem with elevation ranges
on a valid map to profile.
Michael
On 2/11/07 11:30 AM, "Maris Nartiss" <maris.gis@gmail.com> wrote:
Hi Michael,
it will divide by zero on any non-normal map - think of binary map (1,null).
It has no sense for such maps to create profiles, but it does not mean
that gis.m should fail if user is dumb. It's one of my thisweekends
efforts to make gis.m foolproof.
Maris.
2007/2/11, Michael Barton <michael.barton@asu.edu>:
Maris,
Do you know what is making this divide by 0 and under what circumstances
(e.g., range of elevation values on map, location/projection
characteristics)? On my system, with a build of 2 days ago, the profiling
works fine with the "normal" map of the Spearfish 30m DEM.
This happened a couple times before when the GRASS module used for
calculating the total elevation range was giving incorrect information in
certain circumstances and when there were changes in the function of
g.region flags. It was an example of the cascade of effects that can happen
if a module function is changed in seemingly minor ways.
The error trapping is a good idea in any case. But I want to make sure we
also understand the cause rather than just treat the symptoms.
Michael
On 2/10/07 12:30 PM, "grass-codepatches@wald.intevation.org"
<grass-codepatches@wald.intevation.org> wrote:
code patches item #281, was opened at 2007-02-10 21:30
Status: Open
Priority: 3
Submitted By: M?ris Narti¹s (marisn)
Assigned to: Nobody (None)
Summary: Fix for gis.m profile dialog division by zero
Patch status: None
Patch type: fix
GRASS component: gis.m
GRASS version: CVS HEAD
GRASS CVS checkout date, if applies (YYMMDD): 070210
Initial Comment:
This patch prevents gis.m profile tool from dividing by zero and makes
popup
windows to appear on top of profile window and not gis.m main window.
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University