<div dir="ltr">Hello Cesar,<br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Nov 26, 2013 at 4:47 PM, Cesar Augusto Ramírez Franco <span dir="ltr"><<a href="mailto:caesarivs@gmail.com" target="_blank">caesarivs@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div style="color:rgb(39,78,19)">Hello everyone,</div>
<div style="color:rgb(39,78,19)"><br></div><div style="color:rgb(39,78,19)">I've been trying to do a supervised classification from landsat8 imagery using i.class and then i.maxlik, but I'm getting an error when running i.maxlik saying it can't read the signature file.</div>
<div style="color:rgb(39,78,19)"><br></div><div style="color:rgb(39,78,19)">I tested my procedure on the NC sample dataset and I'm getting the same error, I'm using Grass 6.4.2 on Debian Wheezy, installed from the debian repo. Here's the command set:</div>
<div style="color:rgb(39,78,19)"><br></div><div><font color="#274e13" face="courier new, monospace">#Display RGB enhanced map</font></div><div><font color="#274e13" face="courier new, monospace">i.landsat.rgb blue=lsat7_2000_10 green=lsat7_2000_20 red=lsat7_2000_30</font><br>
</div><div><font color="#274e13" face="courier new, monospace"><div>d.rgb blue=lsat7_2000_10 green=lsat7_2000_20 red=lsat7_2000_30</div><div>#"Real color" map</div>
<div>r.composite red=lsat7_2000_30 green=lsat7_2000_20 blue=lsat7_2000_10 output=lsat7_2000_RGB</div><div>#Group images to process</div><div>i.group group=lsat7_2000_RGB subgroup=lsat7_2000_RGB input=lsat7_2000_10,lsat7_2000_20,lsat7_2000_30<br>
</div><div>#Unsupervised classification</div><div><div>i.cluster group=lsat7_2000_RGB subgroup=lsat7_2000_RGB sigfile=clustlsat7 classes=20 report=rep_clust_lsat7.txt</div>
<div>i.maxlik group=lsat7_2000_RGB subgroup=lsat7_2000_RGB sigfile=clustlsat7 class=lsat7_classes reject=lsat7_classes_rej<br></div></div><div>#Supervised classification</div>
<div>
<div>i.class map=lsat7_2000_RGB group=lsat7_2000_RGB subgroup=lsat7_2000_RGB outsig=classlsat7</div><div>i.maxlik group=lsat7_2000_RGB subgroup=lsat7_2000_RGB sigfile=classlsat7 class=lsat7_class_sup</div></div></font></div>
</div></blockquote><div><br></div><div style>I reproduced your example here (thanks for providing it, makes testing easy!).</div><div style><br></div><div style> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div dir="ltr"><div style="color:rgb(39,78,19)">Here I get the error in which i.maxlik can't read the signature file created by i.class (classlsat7) but read the one created by i.cluster flawlessly</div></div></blockquote>
<div><br></div><div style>Here it went through (Fedora 19 64bit, 6.4.4svn).</div><div style><br></div><div style><br></div><div style><div>GRASS 6.4.4svn (nc_spm_08):~ > i.class map=lsat7_2000_RGB group=lsat7_2000_RGB subgroup=lsat7_2000_RGB outsig=classlsat7</div>
<div><br></div><div>RESULT SIGNATURE</div><div><br></div><div>GRASS 6.4.4svn (nc_spm_08):~ > i.maxlik group=lsat7_2000_RGB subgroup=lsat7_2000_RGB sigfile=clustlsat7 class=lsat7_classes reject=lsat7_classes_rej --o</div>
<div> 100%</div><div><br></div></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">
<div style="color:rgb(39,78,19)">This is what I'm selecting on the i.class monitor, I named it vegetation:</div></div></blockquote><div>...</div><div><br></div><div style>My map looked similar.</div><div> </div><div>
</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div style="color:rgb(39,78,19)"></div>
<div style="color:rgb(39,78,19)">And the contents of the classlsat7 signature file are the following:<br></div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="color:rgb(39,78,19);display:inline">
<font face="courier new, monospace"></font></div></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<font color="#274e13" face="courier new, monospace">#</font></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<font color="#274e13" face="courier new, monospace">#vegetation</font></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<font color="#274e13" face="courier new, monospace">166</font></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div style="color:rgb(39,78,19);display:inline"></div></blockquote></div></blockquote><div><br></div><div style>This is strange... Here I get</div><div style><br></div><div style><div>GRASS 6.4.4svn (nc_spm_08):~/grassdata/nc_spm_08/landsat/group/lsat7_2000_RGB/subgroup/lsat7_2000_RGB/sig > cat classlsat7</div>
<div>#</div><div>#lake</div><div>899</div><div>68.2458 49.1224 38.317 </div><div>2.30345 </div><div>1.26392 2.63753 </div><div>1.82294 2.67163 5.90938 </div><div>#vegetation</div><div>92</div><div>76.3804 66.6957 57.2391 </div>
<div>120.414 </div><div>116.029 116.236 </div><div>160.886 158.447 222.206 </div><div><br></div></div><div style>Maybe you remove the unfortunate signature from the ASCII file and digitize it again?</div><div style><br></div>
<div style>Best,</div><div style>Markus</div></div><br></div></div>