[GRASS-dev] [GRASS GIS] #805: i.spectral in GRASS6.4

#805: i.spectral in GRASS6.4
-------------------------------+--------------------------------------------
Reporter: arocha | Owner: grass-dev@lists.osgeo.org
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Keywords: i.spectral; wxGUI | Platform: MSWindows XP
      Cpu: x86-32 |
-------------------------------+--------------------------------------------
I'm using GRASS 6.4.0svn (2009) with wxpython and when I select
Imagery/Spectral Response (i.spectral) I get this error.

***************************************
Traceback (most recent call last):
File "C:/GRASS6/etc/wxpython/wxgui.py", line 521, in
OnMenuCmd

menuform.GUI().ParseCommand(cmd, parentframe=self)
File "C:\GRASS6\etc\wxpython\gui_modules\menuform.py",
line 1809, in ParseCommand

xml.sax.parseString(getInterfaceDescription(cmd[0]).decode(e
nc).encode("utf-8"),
File "C:\GRASS6\etc\wxpython\gui_modules\menuform.py",
line 1748, in getInterfaceDescription

raise IOError, _("Unable to fetch interface description for
command '%s'.") % cmd
IOError
:
Unable to fetch interface description for command
'i.spectral'.
***************************************

Is this something that was expected in this version or anyone has a an
idea
of how to fix this?

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral; wxGUI
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by neteler):

I see this bug in several bug reports: #639, #581, #553, #234

It is not systematic but perhaps there is a chance to reproduce it.

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral; wxGUI
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by cmbarton):

Reading the error message, I'm completely convinced that this is even a
wxGUI problem. The error message suggests that "<command> --interface-
description" is not returning anything.

I do not have any problem launching either i.spectral or v.in.ogr (trac
#581) in the current svn version of GRASS 6.4 (or other versions) on Mac
OS X.

I see that this may be intermittent, but perhaps it is fixed now. Does
this still happen to anyone?

Michael

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral; wxGUI
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by cmbarton):

Replying to [comment:2 cmbarton]:
> Reading the error message, I'm completely convinced that this is even a
wxGUI

This *should* read, I'm NOT completely convinced...

problem. The error message suggests that "<command> --interface-
description" is not returning anything.
>
> I do not have any problem launching either i.spectral or v.in.ogr (trac
#581) in the current svn version of GRASS 6.4 (or other versions) on Mac
OS X.
>
> I see that this may be intermittent, but perhaps it is fixed now. Does
this still happen to anyone?
>
> Michael

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral, wingrass
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Changes (by hamish):

  * keywords: i.spectral; wxGUI => i.spectral, wingrass

Comment:

(use the "wingrass" keyword so it makes it onto the WinGrass errata list
and so gets more visibility)

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral, wingrass
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by cmbarton):

Is this a Windows-only problem?

Michael

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral, wingrass
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by hamish):

as per comments in #581,

* ''Can you try again with a nightly wingrass build >rev41308? I suspect
that Martin may have just fixed this (or something rather similar) in SVN
with r41308.''

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral, wingrass
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by hellik):

Replying to [comment:6 hamish]:
> as per comments in #581,
>
> * ''Can you try again with a nightly wingrass build >rev41308? I suspect
that Martin may have just fixed this (or something rather similar) in SVN
with r41308.''

i've just looked at

http://grass.osgeo.org/grass64/manuals/html64_user/i.spectral.html

is there a example with the nc-sample-dataset for testing?

in the manuals there is

{{{
NOTES
This script needs gnuplot to be installed.
}}}

is there a gnuplot-version in osgeo4w or in osgeo4w-based wingrass-
version?

Helmut

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral, wingrass
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by hamish):

Replying to [comment:2 cmbarton]:
> I do not have any problem launching either i.spectral or v.in.ogr
> (trac #581) in the current svn version of GRASS 6.4 (or other
> versions) on Mac OS X.

yeah, but what if you change language settings to something that uses
chars outside the common western european language set?

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

#805: i.spectral in GRASS6.4
---------------------------+------------------------------------------------
  Reporter: arocha | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Resolution: | Keywords: i.spectral, wingrass
  Platform: MSWindows XP | Cpu: x86-32
---------------------------+------------------------------------------------
Comment (by cmbarton):

I don't know. Maybe someone using another character set can check. But I'm
not sure how an alternate character set would affect the launching of
these 2 modules and not affect the launching of all modules.

Michael

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

#805: i.spectral in GRASS6.4
----------------------------------+-----------------------------------------
Reporter: arocha | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.0
Component: wxGUI | Version: 6.4.0 RCs
Keywords: i.spectral, wingrass | Platform: MSWindows XP
      Cpu: x86-32 |
----------------------------------+-----------------------------------------

Comment(by hamish):

and someone using a non-western European language set give it a try? is
i.spectral still broken from the wxgui menu?

worksforme,
Hamish

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

#805: i.spectral in GRASS6.4
----------------------------------+-----------------------------------------
Reporter: arocha | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.2
Component: wxGUI | Version: 6.4.0 RCs
Keywords: i.spectral, wingrass | Platform: MSWindows XP
      Cpu: x86-32 |
----------------------------------+-----------------------------------------
Changes (by martinl):

* cc: martinl (added)
  * milestone: 6.4.0 => 6.4.2

Comment:

Replying to [comment:10 hamish]:
> and someone using a non-western European language set give it a try? is
i.spectral still broken from the wxgui menu?

no problem here

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

#805: i.spectral in GRASS6.4
----------------------------------+-----------------------------------------
Reporter: arocha | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.3
Component: wxGUI | Version: 6.4.0 RCs
Keywords: i.spectral, wingrass | Platform: All
      Cpu: x86-32 |
----------------------------------+-----------------------------------------
Changes (by neteler):

  * platform: MSWindows XP => All
  * milestone: 6.4.2 => 6.4.3

Comment:

Still failing in wxGUI (tested on Linux):

North Carolina example:
  * display "lsat7_2002_20"
  * start i.spectral from command line with -i -m

--> d.where and r.what zombie processes occur

CLI example:
{{{
g.region rast=lsat7_2002_10 -p
d.mon x0
d.rast lsat7_2002_40
i.spectral -i -m
rast=lsat7_2002_10,lsat7_2002_20,lsat7_2002_30,lsat7_2002_40,lsat7_2002_50,lsat7_2002_70
}}}

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

#805: i.spectral in GRASS6.4
----------------------------------+-----------------------------------------
Reporter: arocha | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.3
Component: wxGUI | Version: 6.4.0 RCs
Keywords: i.spectral, wingrass | Platform: All
      Cpu: x86-32 |
----------------------------------+-----------------------------------------

Comment(by hamish):

The original --interface-description problem on wingrass seems fixed now.

Xmons are not available in Wingrass, so picking interactively won't work
there anyway even if gnuplot was installed. I've now added a test in
devbr6 (r56946) to bail out early if no Xmon is open.

Gnuplot is not shipped with our Wingrass package, so the module won't work
there.
If you try to run it you hit that error message first, asking you to
install.

BUT:
  'd.mon -L' as a command layer in the wxGUI shows all monitors as
running?!
same for "grass.run_command('d.mon', flags = 'L')" from the Python shell
tab.
??

I don't know of a good way for the script to test if it was called from
the wxGUI or not (especially after laundering through g.parser), so the
solution probably needs to be in menudata.xml.

trying MarkusN's example from comment:12 works fine for me in Linux from
the command line. it also doesn't lock up from the wxGUI _without_ the -m
flag, even without an Xmon open. trying from the wxGUI on linux (with an
Xmon open) with the -m flag causes the zombie mayhem. Perhaps in
menudata.xml the handler for i.spectral needs to be changed to `OnXTerm`
instead of `OnMenuCmd`? Another idea is to write a wrapper --script for
the wxGUI menu entry which forces non-interactive mode.

In addition to a number of other cleanups, I've also just added a new
east_north= option in devbr6 to allow non-interactive operation (so no
Xmonitor needed), and a couple new output graphics formats. I'll sync
those with trunk asap.

I'm not sure how much to backport to 6.4.3, at least the group= input
option is totally broken there since the i.group output text changed (but
luckily the new i.group -g flag makes the parsing much easier).

Hamish

ps- interestingly enough, while reading through the Gnuplot manual I
noticed that a "grass" graphics terminal exists for gnuplot which will
render your plots directly to a GRASS Xmonitor. It wasn't built into my
copy though so I couldn't test it.

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

#805: i.spectral in GRASS6.4
----------------------------------+-----------------------------------------
Reporter: arocha | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.3
Component: wxGUI | Version: 6.4.0 RCs
Keywords: i.spectral, wingrass | Platform: All
      Cpu: x86-32 |
----------------------------------+-----------------------------------------

Comment(by cmbarton):

i.spectral is a very good candidate to be implemented in a wxPlot
interface like profiling and image scatterplots.

Michael

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