[GRASS5] Re: [GRASSLIST:2304] Re: s.sample gets killed

Hamish hamish_nospam at yahoo.com
Thu Jan 22 01:29:39 EST 2004


> > I added the lines to sites.c and recompiled the whole thing, but
> > unfortunately the result is the same. Instead of 'killed' I now get
> > a'Bus Error' message. More ideas?
> 
> Unfortunately not.
> 
> Memory exceptions (i.e. "Segmentation Fault" or "Bus Error") are
> almost impossible to track down without a suitable test case (and
> sending me a 2.5-million entry sites file or an equally large raster
> are out of the question).
> 
> Can you reproduce the error with one of the sample data sets (e.g. 
> spearfish), either alone or with a small additional sites file? Or
> with data which can be generated? If so, post the details and I'll try
> to reproduce it.


use s.random, but you have to modify it to allow n to be bigger than
32k. I made "int n" into "long int n" and commented out parm.nsites->options

(Maybe worth doing properly in CVS.. 32k is pretty small)


Spearfish:

g.region rast=elevation.dted
s.random sites=random_sites n=2500000  #  (122mb)
s.sample input=random_sites rast=elevation.dted > sample_sites

and watch it go..


I think 3-4gig of virtual/swap memory will make it through the 2.5M points.



Hamish




More information about the grass-dev mailing list