Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Nikos Alexandris
..
Moritz:

> >> I hope I'm being understandable...

Nikos Alexandris:

> > Absolutely :-).

Markus Neteler:

> Since this questions comes up from time to time, it would be nice to get
> the summary of this comparative discussion into the Wiki... volunteers
> needed.

Already started working it out!  If there are no objections, leave it to me.  
Please, consider assistance in reviewing it in the end, which is after all 
always useful.

Thanks, Nikos
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Markus Neteler
On Wed, Oct 31, 2012 at 6:06 PM, Nikos Alexandris
 wrote:
> [...]
>
> Moritz:
>
>> I hope I'm being understandable...
>
> Absolutely :-).

Since this questions comes up from time to time, it would be nice to get
the summary of this comparative discussion into the Wiki... volunteers needed.

Markus
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] [off-topic] Problem in compile rgdal on Lion

2012-10-31 Thread William Kyngesburye
Yes, not quite the right list, but I think you're out of luck anyways.  R 
defines the compile flags and other details to use, and it's hard to override 
them.  I gave up and used an old Mac with Snow Leopard to compile.

The problem is that Lion Xcode does not include GCC any more.  clang is the 
main compiler, and R doesn't like it.  There is a llvm-gcc that emulates the 
behavior of gcc, but R finds cc which is a symlink to clang (but configure 
scripts still identify it as gcc).

I have rgdal on my framework download page, but it's a little old.  I tend to 
forget about it, but I can update my rgdal if you can wait a bit.  (hmm, maybe 
my rgdal doesn't work with your custom R?)

If you really need to compile your own rgdal, one thing I haven't tried is 
creating a symlink to llvm-gcc and putting it in your PATH.  I would NOT put it 
in /usr/local/bin, because that could interfere with software that does work 
with clang from the cc symlink.  Maybe something like:

mkdir ~/binllvm
ln -s /usr/bin/llvm-gcc ~/binllvm/cc
ln -s /usr/bin/llvm-g++ ~/binllvm/c++
export PATH="~/binllvm:$PATH"

then compile/install rgdal in the same terminal window you ran the export.

On Oct 31, 2012, at 6:41 PM, Marcello Benigno wrote:

> Hi,
> 
> I can't install rgdal library on Lion, tried this:
> 
> 
> R CMD INSTALL 
> --configure-args='--with-gdal-config=/Library/Frameworks/GDAL.framework/unix/bin/gdal-config
>  --with-proj-include=/Library/Frameworks/PROJ.framework/unix/include 
> --with-proj-lib=/Library/Frameworks/PROJ.framework/unix/lib' 
> /Users/marcello/Downloads/rgdal_0.7-20.tar.gz 
> 
> 
> * installing to library 
> ‘/usr/local/Cellar/r/2.15.2/R.framework/Versions/2.15/Resources/library’
> 
> * installing *source* package ‘rgdal’ ...
> 
> ** package ‘rgdal’ successfully unpacked and MD5 sums checked
> 
> 
> configure: gdal-config: 
> /Library/Frameworks/GDAL.framework/unix/bin/gdal-config
> 
> 
> checking gdal-config usability... yes
> 
> configure: GDAL: 1.9.1
> 
> checking GDAL version > 1.5.4... yes
> 
> checking for gcc... cc
> 
> checking whether the C compiler works... yes
> 
> checking for C compiler default output file name... a.out
> 
> checking for suffix of executables... 
> 
> checking whether we are cross compiling... no
> 
> checking for suffix of object files... o
> 
> checking whether we are using the GNU C compiler... yes
> 
> checking whether cc accepts -g... yes
> 
> checking for cc option to accept ISO C89... none needed
> 
> 
> checking how to run the C preprocessor... cc -E
> 
> 
> checking for grep that handles long lines and -e... /usr/bin/grep
> 
> 
> checking for egrep... /usr/bin/grep -E
> 
> checking for ANSI C header files... rm: conftest.dSYM: is a directory
> 
> rm: conftest.dSYM: is a directory
> 
> yes
> 
> checking for sys/types.h... yes
> 
> checking for sys/stat.h... yes
> 
> checking for stdlib.h... yes
> 
> checking for string.h... yes
> 
> checking for memory.h... yes
> 
> checking for strings.h... yes
> 
> checking for inttypes.h... yes
> 
> checking for stdint.h... yes
> 
> checking for unistd.h... yes
> 
> checking gdal.h usability... yes
> 
> checking gdal.h presence... yes
> 
> checking for gdal.h... yes
> 
> checking gdal: linking with --libs only... no
> 
> checking gdal: linking with --libs and --dep-libs... no
> 
> 
> clang: warning: treating 'c' input as 'c++' when in C++ mode, this behavior 
> is deprecated
> 
> 
> gdal_test.c:5:1: error: C++ requires a type specifier for all declarations
> 
> 
> main() {
> 
> ^~~~
> 
> 1 error generated.
> 
> clang: warning: treating 'c' input as 'c++' when in C++ mode, this behavior 
> is deprecated
> 
> gdal_test.c:5:1: error: C++ requires a type specifier for all declarations
> 
> main() {
> 
> ^~~~
> 
> 1 error generated.
> 
> configure: Install failure: compilation and/or linkage problems.
> 
> 
> configure: error: GDALAllRegister not found in libgdal.
> 
> 
> ERROR: configuration failed for package ‘rgdal’
> 
> 
> * removing 
> ‘/usr/local/Cellar/r/2.15.2/R.framework/Versions/2.15/Resources/library/rgdal’
> 
> 
> 
> Any Ideas?
> 
> Thanks in advance.
> -- 
> Marcello Benigno B. de Barros Filho
> Prof. do Curso Superior de Tecnologia em Geoprocessamento - IFPB
> Mestre em Ciências Geodésicas e Tecnologias da Geoinformação - UFPE
> Doutorando em Tecnologia Ambiental e Recursos Hídricos - UFPE
> http://profmarcello.blogspot.com
> http://about.me/marcello.benigno
> 
> ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user

-
William Kyngesburye 
http://www.kyngchaos.com/

"History is an illusion caused by the passage of time, and time is an illusion 
caused by the passage of history."

- Hitchhiker's Guide to the Galaxy


___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] [off-topic] Problem in compile rgdal on Lion

2012-10-31 Thread Marcello Benigno
Hi,

I can't install rgdal library on Lion, tried this:

R CMD INSTALL 
--configure-args='--with-gdal-config=/Library/Frameworks/GDAL.framework/unix/bin/gdal-config
--with-proj-include=/Library/Frameworks/PROJ.framework/unix/include
--with-proj-lib=/Library/Frameworks/PROJ.framework/unix/lib'
/Users/marcello/Downloads/rgdal_0.7-20.tar.gz
* installing to library
‘/usr/local/Cellar/r/2.15.2/R.framework/Versions/2.15/Resources/library’
* installing *source* package ‘rgdal’ ...
** package ‘rgdal’ successfully unpacked and MD5 sums checked
configure: gdal-config: /Library/Frameworks/GDAL.framework/unix/bin/gdal-config
checking gdal-config usability... yes
configure: GDAL: 1.9.1
checking GDAL version > 1.5.4... yes
checking for gcc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking gdal.h usability... yes
checking gdal.h presence... yes
checking for gdal.h... yes
checking gdal: linking with --libs only... no
checking gdal: linking with --libs and --dep-libs... no
clang: warning: treating 'c' input as 'c++' when in C++ mode, this
behavior is deprecated
gdal_test.c:5:1: error: C++ requires a type specifier for all declarations
main() {
^~~~
1 error generated.
clang: warning: treating 'c' input as 'c++' when in C++ mode, this
behavior is deprecated
gdal_test.c:5:1: error: C++ requires a type specifier for all declarations
main() {
^~~~
1 error generated.
configure: Install failure: compilation and/or linkage problems.
configure: error: GDALAllRegister not found in libgdal.
ERROR: configuration failed for package ‘rgdal’
* removing 
‘/usr/local/Cellar/r/2.15.2/R.framework/Versions/2.15/Resources/library/rgdal’

Any Ideas?

Thanks in advance.

-- 
*Marcello Benigno B. de Barros Filho*
Prof. do Curso Superior de Tecnologia em Geoprocessamento - IFPB
Mestre em Ciências Geodésicas e Tecnologias da Geoinformação - UFPE
Doutorando em Tecnologia Ambiental e Recursos Hídricos - UFPE
http://profmarcello.blogspot.com
http://about.me/marcello.benigno
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] r.basin morphometry, part 2

2012-10-31 Thread Rich Shepard

  If for one basin defined by r.basin the Horton area ration is 0., and
for another basin the Horton slope ration is infinite, what have I done
incorrectly in defining the outlets of these basins? In both cases the rest
of the morphometric parameters look rational.

TIA,

Rich

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] r.basin: Two Questions

2012-10-31 Thread Rich Shepard

  The morphometric parameters calculated by r.basin include mean slope and
magnitudo and I'd like clarification of these two.

  The mean slope of the main channel is presented as percent; is 'mean
slope' also in percent? Also, is mean slope measured along the prevalent
oreientation from outlet to highest point on the watershed boundary?

  I assume that magnitudo is Italian and the English equivalent is
magnitude. Is this a correct assumption? In any case, magnitude of what is
calculated?

Rich

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] installing Grass 7 on ubuntu 11.04

2012-10-31 Thread Nikos Alexandris
[forgot to cc to the list]

Manish Gautam:


> I am finding it difficult to install Grass 7 on my pc. I use Ubuntu 11.04.
> I have tried to install it using the instructions given in the link
> http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu. However, I am able
> to download and install the dependencies.

Could you please post the exact command you instructed?  And, any positive or 
negative output?


> Another thing is how the command ./configure is to be used on Ubuntu 11.04.
> the terminal says the ./configure command not found though the necessary
> compiler is already been installed on the machine.

Actually, the "configure" executable file/program is to be ran from within the 
directory in which it is located, i.e.  the grass source code root directory.

>From within which directory do you try to execute ./configure?  And along with 
which parameters?


> (Can I download the binary file from here
> http://grass.fbk.eu/grass70/binary/linux/snapshot/ and install from here ?

I haven't tried that yet. Maybe someone else can help with this.


> Though again I am unable to run the installation script given there or
> extracting the tar file)

Nikos
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] installing Grass 7 on ubuntu 11.04

2012-10-31 Thread Vishal Mehta
manish,
remember that you have to be in the folder in which you downloaded the
source code, before ./configure
-vishal

On Wed, Oct 31, 2012 at 9:59 AM, Vaclav Petras  wrote:

> Hi,
>
> On 31 October 2012 17:34, Manish Gautam  wrote:
> > ...
> > Another thing is how the command ./configure is to be used on Ubuntu
> 11.04.
> > the terminal says the ./configure command not found though the necessary
> > compiler is already been installed on the machine.
> >
> Are you in the right directory (in the folder with source codes)? Is
> configure script executable (chmod u+x configure)? It is always good
> idea for me to confirm these things at first.
>
> Note that once you get ./configure working, you will need to set
> parameters for configure script (listed here
> http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu#GRASS_GIS).
>
> Vaclav
> ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user
>



-- 
Vishal K. Mehta, PhD
Scientist
Stockholm Environment Institute - US
133 D St Suite F
Davis CA 95616
www.sei-us.org
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Nikos Alexandris
[...]

Moritz:

> I hope I'm being understandable...

Absolutely :-).
Thank you, Nikos

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] installing Grass 7 on ubuntu 11.04

2012-10-31 Thread Vaclav Petras
Hi,

On 31 October 2012 17:34, Manish Gautam  wrote:
> ...
> Another thing is how the command ./configure is to be used on Ubuntu 11.04.
> the terminal says the ./configure command not found though the necessary
> compiler is already been installed on the machine.
>
Are you in the right directory (in the folder with source codes)? Is
configure script executable (chmod u+x configure)? It is always good
idea for me to confirm these things at first.

Note that once you get ./configure working, you will need to set
parameters for configure script (listed here
http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu#GRASS_GIS).

Vaclav
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Moritz Lennert

On 31/10/12 00:48, Nikos Alexandris wrote:

NikosA:


I wonder why the term ISODATA [2] is not to be traced anywhere in the
GRASS manuals, nor in the GRASS book (3rd ed.).  Can someone confirm
that i.cluster is an(other) implementation of the ISODATA clustering
algorithm?


MarkusN:


I search in my inbox and found some earlier discussion with the
Subject: "Re: [GRASS-user] Re: algorithm used in i.cluster", see
below.



PS: Still we need a text snippet to improve the manual...



Things to keep in mind from the archived discussions (below):



- the ISODATA algorithm (Ball and Hall, 1967) is a common modification of
the K-means algorithm



- the algorithm implemented in the "i.cluster" module involves merging of
classes (I_cluster_merge) though no splitting function seems to be
implemented


Moritz:


To add: i.cluster output is also not equivalent to ISODATA in so far as
it does not classify all pixels, but only creates signature files for
the classes. Classification is then done by i.maxlik which is not
equivalent to ISODATA. It might be an interesting addition to i.cluster
to work with all pixels (not only a subset) and to create an output
assigning each pixel to a given class which would be close (but not
equal) to ISODATA output.


Moritz,

please correct me if I am wrong.  I feel that the above sentences draw
actually an unnecessary confusion.

The first step is to cluster pixels according to their (similar, spectral)
properties.  The second step is to classify the clusters, meaning labeling of
the resulted clusters.   So, I don't see were confusions might arise, apart
from the question whether "i.cluster" is an exact implementation of the
ISODATA algorithm or not.


In GRASS, you don't have exactly these steps. i.cluster does not cluster 
all pixels, but only a sample (see parameter 'sample'). The result of 
that clustering is not that all pixels are assigned to a given cluster, 
but only that you have signatures that are "representative" of a given 
cluster. If you run i.cluster on the same data asking for the same 
number of classes, but with different sample sizes, you will probably 
get slightly different signatures for each cluster at each run.


In the second step, you use i.maxlik to then assign each pixel to one of 
the clusters / classes created by i.cluster.


Labelling is actually a third step in that process.

So, i.cluster is used for creating signatures of representative classes, 
just as i.gensig.


ISODATA, OTOH, clusters all pixels and thus already assigns each pixel 
to a given cluster / class, without going through the i.maxlik phase.


i.cluster with a sample=1,1 (if you can get that to run without an alloc 
error on your machine) should use all pixels for the creation of the 
clusters, but it does not allow you to produce a raster layer indicating 
for each pixel the cluster it is assigned to. You have to do i.maxlik to 
do that.


However, i.maxlik does not use the same algorithm to assign pixels to 
clusters / classes as ISODATA. So the result is not exactly the same.



- ISODATA is a clustering algorithm, not a classification algorithm per se --
skimming through Richards book (1999) [1], pages 182, 189, 225.  And the
"i.cluster" module might not be identical to the ISODATA clustering algorithm,
yet, it performs clustering. So, both do the same job, most likely in a more
or less similar way.


Well, as explained above, i.cluster does not cluster the entire map, and 
does not show you the result of the clustering other than in form of a 
signature file, so i.cluster does not perform clustering in the same 
meaning as ISODATA.



-  "i.maxlik" performs the classification of the clusters, which is not a
clustering process. Thus, the module can/should not be identical to the
ISODATA clustering algorithm.  I might have missed something (skimming through
the manuals), but I didn't read anywhere that "i.maxlik" is performing
clustering.


i.maxlik does not perform clustering but assignment of pixels to 
classes/clusters based on signatures of such classes that are either 
created by clustering or through training maps. ISODATA assigns pixels 
to classes through clustering.


I hope I'm being understandable...

Moritz
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] installing Grass 7 on ubuntu 11.04

2012-10-31 Thread Manish Gautam
Hi,

I am finding it difficult to install Grass 7 on my pc. I use Ubuntu 11.04.
I have tried to install it using the instructions given in the link
http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu. However, I am able
to download and install the dependencies.

Another thing is how the command ./configure is to be used on Ubuntu 11.04.
the terminal says the ./configure command not found though the necessary
compiler is already been installed on the machine.

(Can I download the binary file from here
http://grass.fbk.eu/grass70/binary/linux/snapshot/ and install from here ?
Though again I am unable to run the installation script given there or
extracting the tar file)

Thanks.

-

Manish
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Renewal of GRASS-PSC

2012-10-31 Thread Markus Neteler
Dear all,

the nomination phase for new PSC member is over,
thanks for all contributions.

The current PSC will decide in short time about the candidates.

Best
Markus

-- 
GRASS GIS PSC Chair
http://grass.osgeo.org/wiki/PSC
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Unable to locate Curses Includes

2012-10-31 Thread Rebecca Bennett
Great thanks Madi - I'd used that approach for the two earlier errors when 
running this command but couldn't find a package relating to curses in my 
search for unintalled packages (probably due to the curses but being surrounded 
by other letters!)

Incedentally non-of the add-ons are working through the gui - I know this is a 
freqently reported problem to which the only guaranteed solution (after 
scouring the mailing list and trying solutions posted here 
http://planetflux.adamwilson.us/2012/02/installing-grass-extensions-on-ubuntu.html
 and http://comments.gmane.org/gmane.comp.gis.grass.user/43974) appears to be 
to compile from source.

...I wanted large file support anyway so I was just being lazy to only use the 
Ubuntu:GIS repository version :)

cheers!
Rebecca





>
> From: Margherita Di Leo 
>To: Rebecca Bennett  
>Cc: "grass-user@lists.osgeo.org"  
>Sent: Wednesday, 31 October 2012, 10:46
>Subject: Re: [GRASS-user] Unable to locate Curses Includes
> 
>
>Dear Rebecca,
>
>
>On Wed, Oct 31, 2012 at 3:30 PM, Rebecca Bennett  wrote:
>
>Dear Grass Users,
>>
>>Trying to compile 6.4.3 from source on Ubuntu 12.04 in order to get at the 
>>add-ons which are not working in my prepackaged install.
>>
>
>
>Which add-on is not working? 
>
>>Following these instructions 
>>(http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu) I check out the 
>>release_20121024_grass_6_4_3RC1 get as far as 
>>./configure \
>>
>>but get the following error:
>>checking for long long int... yes
>>checking for W11... no
>>checking for X... no
>>checking whether to use Curses... yes
>>checking for curses.h... no
>>configure: error: *** Unable to locate curses includes.
>>
>>Any suggestions / ideas welcome!
>>
>
>
>I think you miss libncurses5-dev.
>In general, when you get an error like this, you can do the search yourself 
>here: http://packages.ubuntu.com/ 
>You have to search "contents of packages" and specify your 
>version/distribution.
>
>
>Hope this helps,
>
>
>madi
>
>-- 
>Margherita DI LEO  
>
>Postdoctoral Researcher   
>European Commission - DG JRC  
>Forest Resources and Climate     
>I-21020 Ispra (VA) - Italy - TP 261 
>        
>Tel. +39 0332 78 3600    
>margherita.di-...@jrc.ec.europa.eu
>
>
>
>
>___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Unable to locate Curses Includes

2012-10-31 Thread Margherita Di Leo
Dear Rebecca,

On Wed, Oct 31, 2012 at 3:30 PM, Rebecca Bennett wrote:

> Dear Grass Users,
>
> Trying to compile 6.4.3 from source on Ubuntu 12.04 in order to get at the
> add-ons which are not working in my prepackaged install.
>

Which add-on is not working?

>
> Following these instructions (
> http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu) I check out the
> release_20121024_grass_6_4_3RC1 get as far as
>
> ./configure \
>
> but get the following error:
> checking for long long int... yes
> checking for W11... no
> checking for X... no
> checking whether to use Curses... yes
> checking for curses.h... no
> configure: error: *** Unable to locate curses includes.
>
> Any suggestions / ideas welcome!
>
>
I think you miss libncurses5-dev.
In general, when you get an error like this, you can do the search yourself
here: http://packages.ubuntu.com/
You have to search "contents of packages" and specify your
version/distribution.

Hope this helps,

madi

-- 
Margherita DI LEO
Postdoctoral Researcher
European Commission - DG JRC
Forest Resources and Climate
I-21020 Ispra (VA) - Italy - TP 261

Tel. +39 0332 78 3600
margherita.di-...@jrc.ec.europa.eu
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] Unable to locate Curses Includes

2012-10-31 Thread Rebecca Bennett
Dear Grass Users,

Trying to compile 6.4.3 from source on Ubuntu 12.04 in order to get at the 
add-ons which are not working in my prepackaged install.

Following these instructions 
(http://grass.osgeo.org/wiki/Compile_and_Install_Ubuntu) I check out the 
release_20121024_grass_6_4_3RC1 get as far as 
./configure \

but get the following error:
checking for long long int... yes
checking for W11... no
checking for X... no
checking whether to use Curses... yes
checking for curses.h... no
configure: error: *** Unable to locate curses includes.

Any suggestions / ideas welcome!

Many thanks for reading,

Rebecca___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Nikos Alexandris
Angelos Tzotsos wrote:

> Hi all, 
> This is an ISODATA implementation in C, written under GPL by Christos
> Iossifidis, a colleague of mine at NTUA.

> Would anyone be interested porting it to GRASS? 
> http://users.ntua.gr/chiossif/Free_As_Freedom_Software/isodata.c

Nice!

...
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Angelos Tzotsos

Sorry, I forgot to CC Christos :)

On 10/31/2012 11:32 AM, Angelos Tzotsos wrote:

Hi all,

This is an ISODATA implementation in C, written under GPL by Christos 
Iossifidis, a colleague of mine at NTUA.

Would anyone be interested porting it to GRASS?

http://users.ntua.gr/chiossif/Free_As_Freedom_Software/isodata.c

Cheers,
Angelos

On 10/31/2012 01:48 AM, Nikos Alexandris wrote:

NikosA:

I wonder why the term ISODATA [2] is not to be traced anywhere in 
the

GRASS manuals, nor in the GRASS book (3rd ed.).  Can someone confirm
that i.cluster is an(other) implementation of the ISODATA clustering
algorithm?

MarkusN:


I search in my inbox and found some earlier discussion with the
Subject: "Re: [GRASS-user] Re: algorithm used in i.cluster", see
below.
PS: Still we need a text snippet to improve the manual...

Things to keep in mind from the archived discussions (below):
- the ISODATA algorithm (Ball and Hall, 1967) is a common 
modification of

the K-means algorithm
- the algorithm implemented in the "i.cluster" module involves 
merging of

classes (I_cluster_merge) though no splitting function seems to be
implemented

Moritz:


To add: i.cluster output is also not equivalent to ISODATA in so far as
it does not classify all pixels, but only creates signature files for
the classes. Classification is then done by i.maxlik which is not
equivalent to ISODATA. It might be an interesting addition to i.cluster
to work with all pixels (not only a subset) and to create an output
assigning each pixel to a given class which would be close (but not
equal) to ISODATA output.

Moritz,

please correct me if I am wrong.  I feel that the above sentences draw
actually an unnecessary confusion.

The first step is to cluster pixels according to their (similar, 
spectral)
properties.  The second step is to classify the clusters, meaning 
labeling of
the resulted clusters.   So, I don't see were confusions might arise, 
apart

from the question whether "i.cluster" is an exact implementation of the
ISODATA algorithm or not.

- ISODATA is a clustering algorithm, not a classification algorithm 
per se --

skimming through Richards book (1999) [1], pages 182, 189, 225. And the
"i.cluster" module might not be identical to the ISODATA clustering 
algorithm,
yet, it performs clustering. So, both do the same job, most likely in 
a more

or less similar way.

-  "i.maxlik" performs the classification of the clusters, which is 
not a

clustering process. Thus, the module can/should not be identical to the
ISODATA clustering algorithm.  I might have missed something 
(skimming through

the manuals), but I didn't read anywhere that "i.maxlik" is performing
clustering.

Your attention to details is highly appreciated.
Thanks, Nikos

---
[1] @BOOK{Richards1999,
   title = {{{R}emote {S}ensing {D}igital {I}mage {A}nalysis. {A}n
{I}ntroduction,
3rd revised and enlarged edition.: xxi + 363 pp.}},
   publisher = {Berlin, Heidelberg, New York, London, Paris, Tokyo, 
Hong Kong:

Springer-Verlag.},
   year = {1999},
   author = {JA Richards and X Jia},
   pages = {363},
   edition = {3},
   note = {Hard cover},
   isbn = {3-540-64860-7}
}
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user







--
Angelos Tzotsos
Remote Sensing Laboratory
National Technical University of Athens
http://users.ntua.gr/tzotsos

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Is "i.cluster" an implementation of the ISODATA algorithm?

2012-10-31 Thread Angelos Tzotsos

Hi all,

This is an ISODATA implementation in C, written under GPL by Christos 
Iossifidis, a colleague of mine at NTUA.

Would anyone be interested porting it to GRASS?

http://users.ntua.gr/chiossif/Free_As_Freedom_Software/isodata.c

Cheers,
Angelos

On 10/31/2012 01:48 AM, Nikos Alexandris wrote:

NikosA:


I wonder why the term ISODATA [2] is not to be traced anywhere in the
GRASS manuals, nor in the GRASS book (3rd ed.).  Can someone confirm
that i.cluster is an(other) implementation of the ISODATA clustering
algorithm?

MarkusN:


I search in my inbox and found some earlier discussion with the
Subject: "Re: [GRASS-user] Re: algorithm used in i.cluster", see
below.
PS: Still we need a text snippet to improve the manual...

Things to keep in mind from the archived discussions (below):
- the ISODATA algorithm (Ball and Hall, 1967) is a common modification of
the K-means algorithm
- the algorithm implemented in the "i.cluster" module involves merging of
classes (I_cluster_merge) though no splitting function seems to be
implemented

Moritz:


To add: i.cluster output is also not equivalent to ISODATA in so far as
it does not classify all pixels, but only creates signature files for
the classes. Classification is then done by i.maxlik which is not
equivalent to ISODATA. It might be an interesting addition to i.cluster
to work with all pixels (not only a subset) and to create an output
assigning each pixel to a given class which would be close (but not
equal) to ISODATA output.

Moritz,

please correct me if I am wrong.  I feel that the above sentences draw
actually an unnecessary confusion.

The first step is to cluster pixels according to their (similar, spectral)
properties.  The second step is to classify the clusters, meaning labeling of
the resulted clusters.   So, I don't see were confusions might arise, apart
from the question whether "i.cluster" is an exact implementation of the
ISODATA algorithm or not.

- ISODATA is a clustering algorithm, not a classification algorithm per se --
skimming through Richards book (1999) [1], pages 182, 189, 225.  And the
"i.cluster" module might not be identical to the ISODATA clustering algorithm,
yet, it performs clustering. So, both do the same job, most likely in a more
or less similar way.

-  "i.maxlik" performs the classification of the clusters, which is not a
clustering process. Thus, the module can/should not be identical to the
ISODATA clustering algorithm.  I might have missed something (skimming through
the manuals), but I didn't read anywhere that "i.maxlik" is performing
clustering.

Your attention to details is highly appreciated.
Thanks, Nikos

---
[1] @BOOK{Richards1999,
   title = {{{R}emote {S}ensing {D}igital {I}mage {A}nalysis. {A}n
{I}ntroduction,
3rd revised and enlarged edition.: xxi + 363 pp.}},
   publisher = {Berlin, Heidelberg, New York, London, Paris, Tokyo, Hong Kong:
Springer-Verlag.},
   year = {1999},
   author = {JA Richards and X Jia},
   pages = {363},
   edition = {3},
   note = {Hard cover},
   isbn = {3-540-64860-7}
}
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user




--
Angelos Tzotsos
Remote Sensing Laboratory
National Technical University of Athens
http://users.ntua.gr/tzotsos

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] aspect with r.param.scale

2012-10-31 Thread Micha Silver

  
  
On 31/10/2012 06:02, Stephen Roecker
  wrote:

Is their a simple way to convert the aspect raster
  produced from r.param.scale to the conventional geographic
  convention of 0 to 360, rather than 0 to +/-180? I see that this
  issue has been discussed before, but the previous threads solution
  was specific to r.slope.aspect and the programming was frankly
  beyond my understanding.
  
  http://osgeo-org.1560.n6.nabble.com/Aspect-direction-in-r-slope-aspect-td3918139.html
  
  Is their a simple solution that doesn't involve reclassifying the
  raster?
  


I think this mapcalc _expression_ will convert an r.param.scale aspect
map to the "conventional" north=0, clockwise angles:
r.mapcalc aspect0to360 = "if(aspect >= 90, aspect - 90, aspect +
270)"

Thanks,
  
  Stephen
  
  
  This mail was received via Mail-SeCure System.
  
  
  
  ___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

This mail was received via Mail-SeCure System.






-- 
Micha Silver
GIS Consulting
052-3665918
http://www.surfaces.co.il

  

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user