Re: [GRASS-user] sunmask

2010-05-06 Thread Markus Neteler
On Thu, May 6, 2010 at 2:17 AM, Hamish hamis...@yahoo.com wrote:
 Markus wrote:
 Yes: the second parameter is missing.

 maybe in future the seconds param (but not others) could be set
 to default to 0? any problems with that?

Sounds good to me.

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


Re: [GRASS-user] sunmask

2010-05-06 Thread Paolo Cavallini

Thanks. Fixed in https://trac.osgeo.org/qgis/changeset/13427
All the best.

On Wed, 5 May 2010 23:52:43 +0200, Markus Neteler nete...@osgeo.org
wrote:

 Yes: the second parameter is missing.
 
 Markus

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


[GRASS-user] r.proj or r.resamp.rst issues

2010-05-06 Thread Bulent Arikan
Hi,

I am running GRASS 6.5 svn (Snow Leopard). I have several ASTER GDEMs
(Latlong, 30m res.), which I reprojected into UTM using both 'nearest' and
'cubic' methods ('r.proj'). Only in some imagery that are reprojected in
cubic, I ended up having couple of cells (literally, 1-2 cells out of 8
million in average) with minus (-) values. For example, in a DEM where the
elevation values are between 800-2600 meters, I have cell values between
-150 and -85 meters. This does not seem to be an issue in reprojected
imagery with the nearest method. I am not sure how these minus values are
introduced at the first place.

Since I interpolate GDEMs from 30m to 10m using 'r.resamp.rst' (keeping
tension at 40.), I need to fix this problem. I thought of making negative
value cells null but this may create more problems during interpolation
(actually, I tried and r.resamp.rst could not complete interpolation). If I
take absolute values of cells to make negative cells positive, then I
introduce cells with unrealistic elevation data. It seems like after
interpolation –without any correction of negative values–, the number of
negative value cells do not increase, they are still less than 1% of total
cells.

I will appreciate any suggestions why cubic method produces negative values
in some imagery and how to fix this before or after interpolation.

* I did not try changing default r.resamp.rst values, such as tension,
because most of the imagery I interpolated have very accurate results; the
elevation difference between interpolated (10m res) and original (30m res)
is around 1 meter.

Thank you for your comments.

-- 
BÜLENT ARIKAN
School of Human Evolution and Social Change
Arizona State University
Tempe - AZ
85287-2402
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Problem with running Python script in GRASS

2010-05-06 Thread Glynn Clements

LeeDaniel wrote:

 I've written a Python script, doing my best to use the Python I know and
 reverse engineer the python scripts I found in the Internet. As far as I can
 tell, the script should be fine, although I naturally can't execute it
 independently. My goal is to run it as a command from inside GRASS so that
 the user can input the parameters through the GUI. I think GRASS recognizes
 that the script is there but isn't able to generate the GUI.

 After loading that into the appropriate directory:
 C:\GRASS-64\scripts
 and restarting GRASS, I enter the command r.solar into the command line.
 
 The result is the following message:

 Unable to fetch interface description for command 'r.solar'.

Windows, Python and 6.4 isn't the most reliable combination.

At a minimum, you need a fairly recent version of 6.5 to be able to
use Python scripts on Windows (the hacks required to get shell scripts
to work on Windows get in the way of running other scripts). 6.4.0-RC6
won't work (g.parser was updated, but lib/python wasn't).

You also need a clean Python install with the correct registry
entries, and you may need to hack the GRASS startup scripts (the
WinGRASS installer fails quite badly with regard to Python, and the
OSGeo4W installer fails even harder).

-- 
Glynn Clements gl...@gclements.plus.com
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Re: Problem with running Python script in GRASS

2010-05-06 Thread Glynn Clements

LeeDaniel wrote:

 Thanks for the answer. Yeah, that's really strange. Now I've installed Linux
 on top of Windows and tried running it there. I seem to get a step further.
 Rather than spitting out that strange error message I get the following: 
 
 child process exited abnormally

Do you get any more detail than that?

That error indicates that an external command failed. In that
situation, it's helpful to know *which* external command failed.

Also, it's worth checking whether the script works without the GUI,
e.g. typing r.solar help from the command line.

-- 
Glynn Clements gl...@gclements.plus.com
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Call an external function from GRASS-Pythons Scripts

2010-05-06 Thread Markus Neteler
On Wed, May 5, 2010 at 5:30 AM, Nikos Alexandris
nikos.alexand...@felis.uni-freiburg.de wrote:
 On Thu, Apr 22, 2010 at 1:52 PM, Martin Landa landa.mar...@gmail.com wrote:
 ...
  PS: Probably it would be reasonable to change configuration of ML
  (send replay to the list instead to 'from') to avoid this mistake.

 On Thursday 22 of April 2010 15:36:37 Markus Neteler wrote:
 Hi Martin,

 I would strongly advise against that (see '90s archive for some damages
 and OSGeo list archive too and others):

 http://www.unicom.com/pw/reply-to-harmful.html
 http://woozle.org/~neale/papers/reply-to-still-harmful.html

 It is too risky. I have been asked several times in the past to remove
 posting from a list archive which is not only a PITA but also a can
 or worms (think censorship; which message to delete, which not etc.).

 My strong 0.02 cents :)
 Markus

 Markus,

 I just read about this past debate. So, it is always better to use the Reply
 to Mailing-List button (KMail here)?

I don't know such button... (no KMail knowledge).

 Pohhh... I am really sorry if I caused any problem since I've always been
 using the Reply-to-All for the list and the Reply-to for personal
 messages.

But Reply-to-All for the list and the Reply-to for personal messages
is perfect! Just go on. Nothing changed. I suggested to not change anything :)

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


[GRASS-user] r.proj and r.resamp.rst issues -2

2010-05-06 Thread Bulent Arikan
Hi,

I might have found a solution to my problem, which I shared with you earlier
today. I am writing about it in case someone else has a similar issue and
this may be a way of solving the problem. However, I am not certain if this
is the easiest or the most practical way of getting the results.

The problem was the presence of few negative value cells in 'cubic'
reprojected DEMs (from Latlong to UTM). I ran r.mapcalc to make these
negative cells NULLs. Then, I ran 'r.fillnulls' in that part of the DEM and
patched the 'filled' map with the original map (the one that has NULLs).
Finally, I interpolated the resultant (i.e., patched) imagery from 30m to
10m. The values in 10m DEM look accurate and free of negative value cells.

If you know another way of doing it and share with me, I will greatly
appreciate.

-- 
BÜLENT ARIKAN
School of Human Evolution and Social Change
Arizona State University
Tempe - AZ
85287-2402
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] rainfall data

2010-05-06 Thread Marco Alicera
2010/5/5 Markus Neteler nete...@osgeo.org:
 On Wed, May 5, 2010 at 1:36 PM, Sandile Gumede akasand...@gmail.com wrote:
 which command do I use to model rainfall data in GRASS6?

 There are several option. See here for GRASS related publications:

 http://www.citeulike.org/user/neteler/article/4509581
 http://www.citeulike.org/user/neteler/article/4078343

Thanks, the publications were great!

In the same context, I would like to ask for very simple tips about
how to import several rainfall gauge stations.

For instance, a csv or txt file with the following columns gauge
station name, owner, North, East, annual rainfall, Elevation, max
24 hrs.

I have failed from the db.connection or db.in.org (if that is the
begining) and the availa

Then, it would be nice to link a data serie (date, rain) with its gauge station.

Any tips to make it easer will be very welcome,
--
Marco

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

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