Re: [GRASS-dev] v.rast.stats

2008-07-29 Thread Moritz Lennert
On 28/07/08 19:50, chris carleton wrote: Hello All - I have a question about the v.rast.stats script. I want to maintain a MASK for the process in order to isolate portions of the raster and attaching those stats to the vector table. In the script, any user defined mask is temporarily renamed,

Re: [GRASS-dev] d.thematic.area: need for a bit of help in C-programming/debugging

2008-07-29 Thread Moritz Lennert
On 24/07/08 21:39, Glynn Clements wrote: To use it, you need to link the program with -lmcheck (this ensures that mcheck() is called before the first malloc()), Sorry, need some help on this one. Tried adding -lmcheck to CFLAGS1 in include/Make/Platform.make, but get the following during

Re: [GRASS-dev] d.thematic.area: need for a bit of help in C-programming/debugging

2008-07-29 Thread Moritz Lennert
On 29/07/08 10:01, Moritz Lennert wrote: On 24/07/08 21:39, Glynn Clements wrote: To use it, you need to link the program with -lmcheck (this ensures that mcheck() is called before the first malloc()), Sorry, need some help on this one. Tried adding -lmcheck to CFLAGS1 in

[GRASS-dev] [GRASS GIS] #237: r.watershed: speed improvement

2008-07-29 Thread GRASS GIS
#237: r.watershed: speed improvement ---+ Reporter: mmetz | Owner: grass-dev@lists.osgeo.org Type: enhancement| Status: new Priority: minor |

[GRASS-dev] Re: [GRASS GIS] #201: v.in.geonames wxGUI window crashes or freezes when Verbose module output is checked

2008-07-29 Thread GRASS GIS
#201: v.in.geonames wxGUI window crashes or freezes when Verbose module output is checked ---+ Reporter: msieczka | Owner: martinl Type: defect| Status: reopened Priority:

Re: [GRASS-dev] d.thematic.area: need for a bit of help in C-programming/debugging

2008-07-29 Thread Glynn Clements
Moritz Lennert wrote: To use it, you need to link the program with -lmcheck (this ensures that mcheck() is called before the first malloc()), Sorry, need some help on this one. Tried adding -lmcheck to CFLAGS1 in include/Make/Platform.make, but get the following during

Re: [GRASS-dev] debugging nviz with TclTk 8.5 aqua

2008-07-29 Thread William Kyngesburye
On Jul 28, 2008, at 9:34 AM, Glynn Clements wrote: William Kyngesburye wrote: Looks like we need the tcltk header paths. In that case, I think that we're better off ditching the OSX- specific stuff in its entirety and going back to -I, -L and -l switches. No -F, no -framework. We

[GRASS-dev] Re: [GRASS GIS] #237: r.watershed: speed improvement

2008-07-29 Thread GRASS GIS
#237: r.watershed: speed improvement --+- Reporter: mmetz| Owner: grass-dev@lists.osgeo.org Type: enhancement | Status: new Priority: minor| Milestone: 6.4.0

[GRASS-dev] Re: [GRASS GIS] #237: r.watershed: speed improvement

2008-07-29 Thread GRASS GIS
#237: r.watershed: speed improvement --+- Reporter: mmetz| Owner: grass-dev@lists.osgeo.org Type: enhancement | Status: new Priority: minor| Milestone: 6.4.0

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Michael Barton
Glynn, See below... On Jul 29, 2008, at 6:36 AM, Glynn Clements wrote: Michael Barton wrote: AFAICT, everything works without $PYTHONPATH in all cases EXCEPT in a script running under the GRASS parser. So what changes before and after g.parser? In the scripts which I have seen so far,

Re: [GRASS-dev] d.thematic.area: need for a bit of help in C-programming/debugging

2008-07-29 Thread Moritz Lennert
On 29/07/08 15:40, Glynn Clements wrote: Moritz Lennert wrote: To use it, you need to link the program with -lmcheck (this ensures that mcheck() is called before the first malloc()), Sorry, need some help on this one. Tried adding -lmcheck to CFLAGS1 in include/Make/Platform.make, but get

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread William Kyngesburye
On Jul 29, 2008, at 11:22 AM, Michael Barton wrote: GRASS 7.0.svn (Spearfish60_test):~ histogram_mpldemo.py * sys.argv *** /Applications/Grass/GRASS-7.0.app/Contents/MacOS/scripts/ histogram_mpldemo.py * sys.path ***

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Michael Barton
On Jul 29, 2008, at 9:37 AM, William Kyngesburye wrote: [coming out of lurking on this one] It looks like, when run from a python script in GRASS, you're getting the system python. Yet, when you run python itself from GRASS, you get the python.org Python. What is the shebang line

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Michael Barton
On Jul 29, 2008, at 9:54 AM, Michael Barton wrote: On Jul 29, 2008, at 9:37 AM, William Kyngesburye wrote: [coming out of lurking on this one] It looks like, when run from a python script in GRASS, you're getting the system python. Yet, when you run python itself from GRASS, you get

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Michael Barton
On Jul 29, 2008, at 10:10 AM, William Kyngesburye wrote: On Jul 29, 2008, at 11:59 AM, Michael Barton wrote: On Jul 29, 2008, at 9:54 AM, Michael Barton wrote: Weird. When I do 'show original' for /usr/bin/python, it shows as a symlink to

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread William Kyngesburye
On Jul 29, 2008, at 11:54 AM, Michael Barton wrote: So it IS the shebang at the top. So what to do to make this work? #!/usr/bin/env python This works on my Mac. Does it work for others? Are those literally in the shebang? I don't know the finer details of env, but that doesn't

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Michael Barton
On Jul 29, 2008, at 10:16 AM, William Kyngesburye wrote: On Jul 29, 2008, at 11:54 AM, Michael Barton wrote: So it IS the shebang at the top. So what to do to make this work? #!/usr/bin/env python This works on my Mac. Does it work for others? Are those literally in the

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread William Kyngesburye
On Jul 29, 2008, at 12:15 PM, Michael Barton wrote: cmb-MBP-2:~ cmbarton$ ls -l /usr/bin/python lrwxr-xr-x 1 root wheel 72 May 9 15:32 /usr/bin/python - ../../ System/Library/Frameworks/Python.framework/Versions/2.5/bin/python cmb-MBP-2:~ cmbarton$ ls -l /usr/local/bin/python lrwxr-xr-x

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread William Kyngesburye
On Jul 29, 2008, at 11:59 AM, Michael Barton wrote: On Jul 29, 2008, at 9:54 AM, Michael Barton wrote: Weird. When I do 'show original' for /usr/bin/python, it shows as a symlink to /System/Library/Frameworks/Python.framework/Versions/2.5/bin/python ...which is a symlink to

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread William Kyngesburye
On Jul 29, 2008, at 12:42 PM, Michael Barton wrote: Looking more closely, one is in... /Library/Frameworks/Python.framework/Versions/2.5/bin/python and the other is in... /System/Library/Frameworks/Python.framework/Versions/2.5/bin/python Is one of these a System Python, or has MacPython

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Michael Barton
On Jul 29, 2008, at 11:03 AM, William Kyngesburye wrote: On Jul 29, 2008, at 12:42 PM, Michael Barton wrote: Looking more closely, one is in... /Library/Frameworks/Python.framework/Versions/2.5/bin/python and the other is in...

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Glynn Clements
Michael Barton wrote: It looks like, when run from a python script in GRASS, you're getting the system python. Yet, when you run python itself from GRASS, you get the python.org Python. What is the shebang line (first line) in your python script, it may be pointing to the

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Glynn Clements
Michael Barton wrote: See below... William has already identified the core problem: scripts are using a different version of Python to the interactive interpreter, and presumably only one of the two versions has matplotlib installed. If you set PYTHONPATH, all interpreters will find modules

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread William Kyngesburye
On Jul 29, 2008, at 3:30 PM, Glynn Clements wrote: Michael Barton wrote: See below... William has already identified the core problem: scripts are using a different version of Python to the interactive interpreter, and presumably only one of the two versions has matplotlib installed. If

[GRASS-dev] Re: [GRASS-user] r.watershed speed-up

2008-07-29 Thread Michael Barton
I just want to note something very tactfully mentioned below. That is, all such algorithms are estimates of real watershed behavior. AFAICT, r.watershed produces a very good estimate of these parameters and dynamics. Nevertheless, we should be careful about trying to exactly replicate its

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Glynn Clements
Michael Barton wrote: Anyway, it looks like the shebang should be #!/usr/bin/env python unless that is a problem on a non-Mac system. What about Windows? For MSys, #!/usr/bin/env python is fine. Natively, Windows doesn't understand #! syntax, so you would need to either: 1. Add a .py

Re: [GRASS-dev] PYTHONPATH question

2008-07-29 Thread Glynn Clements
Michael Barton wrote: So it IS the shebang at the top. Is python an alias? In the shell, type alias python and type python. anthgradpc7:~ cmbarton$ alias python -bash: alias: python: not found anthgradpc7:~ cmbarton$ type python python is hashed