[GRASS-dev] v.what.rast speedup

Hamish hamish_nospam at yahoo.com
Mon Oct 22 23:55:57 EDT 2007


Markus
> Still everything is not extremely fast given that I tested 5000 points but
> need to work with 300k points for my real work (ideally for several
> thousand maps).


how about using r.what:

 v.out.ascii | r.what in=rastmap_to_query | v.in.ascii -z

?

example:  (DBF)

G63> time v.out.ascii rand10k fs=space | \
       r.what in=elevation.dem null=NULL| grep -v '|NULL$' | \
       v.in.ascii -z out=rand10k_elev x=1 y=2 cat=3 z=4

Scanning input for column types ...
Maximum input row length: 44
Maximum number of columns: 4
Minimum number of columns: 4
Importing points ...
Building topology ...
9905 primitives registered      
[...]
v.in.ascii complete.

real    0m12.864s
user    0m11.449s
sys     0m1.256s


If you leave off "-z z=4" (thus let v.in.ascii create a table) it only
takes 1 second more.

real    0m13.578s
user    0m11.953s
sys     0m1.448s



Hamish


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 




More information about the grass-dev mailing list