[GRASS-dev] [GRASS GIS] #2699: g.gui.iclass doesn't run after selecting training areas

GRASS GIS trac at osgeo.org
Fri Jun 19 00:23:35 PDT 2015


#2699: g.gui.iclass doesn't run after selecting training areas
-------------------------+--------------------------
  Reporter:  ThayseNery  |      Owner:  grass-dev@…
      Type:  defect      |     Status:  new
  Priority:  major       |  Milestone:  7.0.1
 Component:  wxGUI       |    Version:  7.0.0
Resolution:              |   Keywords:  g.gui.iclass
       CPU:  x86-64      |   Platform:  MSWindows 7
-------------------------+--------------------------
Changes (by martinl):

 * keywords:   => g.gui.iclass
 * component:  Default => wxGUI


Old description:

> Hi,
>
> I have been trying to apply supervised classification using
> '''g.gui.iclass''' in GRASS GIS 7.0.1RC1 windows but it doesn't work
> properly. What I do:
>
> 1) Launch g.gui.iclass
> I can open the module by selecting group and imagery subgroup. But when
> the windows GRASS Supervised Classification Tool opens, I observed that
> name of imagery subgroup is missing. By adding it through select imagery
> group I got the following error:
>
>   ''File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iclass\toolbars.py", line 163, in <lambda>
>     lambda event : self.parent.AddBands()),
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iclass\frame.py", line 513, in AddBands
>     subgroup=self.g['subgroup'])
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\etc\python\grass\pydispatch\signal.py", line 229, in emit
>     dispatcher.send(signal=self, *args, **kwargs)
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\etc\python\grass\pydispatch\dispatcher.py", line 349, in send
>     **named
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\etc\python\grass\pydispatch\robustapply.py", line 60, in
> robustApply
>     return receiver(*arguments, **named)
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iscatt\controllers.py", line 1111, in GroupSet
>     self.scatt_mgr.SetBands(bands)
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iscatt\controllers.py", line 164, in SetBands
>     i = GetRasterInfo(b)
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iscatt\iscatt_core.py", line 832, in GetRasterInfo
>     raise GException("r.info failed:\n%s" % msg)
> core.gcmd.GException: r.info failed:
> Illegal filename <PERMANENT
> >. Character not allowed.''
>
> My file name doesn’t have any special character as it is called feb2014.
>
> Although the imagery subgroup cannot been opened, I am able to:
> 2) Add RGB map layer
> 3) Add a class in the class manager and assign a custom color
> 5) I can digitize new area
>
> But After selecting some training areas, I try to run the model and I got
> another error:
>
>   ''File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iclass\frame.py", line 911, in OnRunAnalysis
>     if self.RunAnalysis():
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iclass\frame.py", line 922, in RunAnalysis
>     if not self.CheckInput(group = self.g['group'], vector =
> self.trainingAreaVector):
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\gui\wxpython\iclass\frame.py", line 1087, in CheckInput
>     rasterInfo = grass.raster_info(groupLayers[0])
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\etc\python\grass\script\raster.py", line 70, in raster_info
>     s = read_command('r.info', flags='gre', map=map)
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\etc\python\grass\script\core.py", line 427, in read_command
>     return handle_errors(returncode, stdout, args, kwargs)
>   File "C:\Program Files (x86)\GRASS GIS
> 7.0.1RC1\etc\python\grass\script\core.py", line 312, in handle_errors
>     returncode=returncode)
> grass.exceptions.CalledModuleError: Module run None ['r.info', '-gre',
> u'map=Feb2014_111_112_753mos at PERMANENT\r'] ended with error
> Process ended with non-zero return code 1. See errors in the (error)
> output.''
>

> I have been trying to work with this module for a week and I cannot
> figure out why it doesn’t work.
>
> Many thanks in advance for any help.

New description:

 Hi,

 I have been trying to apply supervised classification using
 '''g.gui.iclass''' in GRASS GIS 7.0.1RC1 windows but it doesn't work
 properly. What I do:

 1) Launch g.gui.iclass
 I can open the module by selecting group and imagery subgroup. But when
 the windows GRASS Supervised Classification Tool opens, I observed that
 name of imagery subgroup is missing. By adding it through select imagery
 group I got the following error:

 {{{
   ''File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iclass\toolbars.py", line 163, in <lambda>
     lambda event : self.parent.AddBands()),
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iclass\frame.py", line 513, in AddBands
     subgroup=self.g['subgroup'])
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\etc\python\grass\pydispatch\signal.py", line 229, in emit
     dispatcher.send(signal=self, *args, **kwargs)
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\etc\python\grass\pydispatch\dispatcher.py", line 349, in send
     **named
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\etc\python\grass\pydispatch\robustapply.py", line 60, in
 robustApply
     return receiver(*arguments, **named)
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iscatt\controllers.py", line 1111, in GroupSet
     self.scatt_mgr.SetBands(bands)
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iscatt\controllers.py", line 164, in SetBands
     i = GetRasterInfo(b)
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iscatt\iscatt_core.py", line 832, in GetRasterInfo
     raise GException("r.info failed:\n%s" % msg)
 core.gcmd.GException: r.info failed:
 Illegal filename <PERMANENT
 >. Character not allowed.''
 }}}

 My file name doesn’t have any special character as it is called feb2014.

 Although the imagery subgroup cannot been opened, I am able to:
 2) Add RGB map layer
 3) Add a class in the class manager and assign a custom color
 5) I can digitize new area

 But After selecting some training areas, I try to run the model and I got
 another error:

 {{{
   ''File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iclass\frame.py", line 911, in OnRunAnalysis
     if self.RunAnalysis():
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iclass\frame.py", line 922, in RunAnalysis
     if not self.CheckInput(group = self.g['group'], vector =
 self.trainingAreaVector):
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\gui\wxpython\iclass\frame.py", line 1087, in CheckInput
     rasterInfo = grass.raster_info(groupLayers[0])
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\etc\python\grass\script\raster.py", line 70, in raster_info
     s = read_command('r.info', flags='gre', map=map)
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\etc\python\grass\script\core.py", line 427, in read_command
     return handle_errors(returncode, stdout, args, kwargs)
   File "C:\Program Files (x86)\GRASS GIS
 7.0.1RC1\etc\python\grass\script\core.py", line 312, in handle_errors
     returncode=returncode)
 grass.exceptions.CalledModuleError: Module run None ['r.info', '-gre',
 u'map=Feb2014_111_112_753mos at PERMANENT\r'] ended with error
 Process ended with non-zero return code 1. See errors in the (error)
 output.''
 }}}

 I have been trying to work with this module for a week and I cannot figure
 out why it doesn’t work.

 Many thanks in advance for any help.

--

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



More information about the grass-dev mailing list