Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-04-03 Thread Roberto Marzocchi
Thanks Helmut. I have corrected the script. Now it works also from GUI R 2018-03-29 17:48 GMT+02:00 Helmut Kudrnovsky : > >Removing the mapset from input name (ztd_temp@meteo --> >ztd_temp) the > module works correctly. I do not know how to solve >this problem. Perhaps > it >

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-29 Thread Helmut Kudrnovsky
>Removing the mapset from input name (ztd_temp@meteo --> >ztd_temp) the module works correctly. I do not know how to solve >this problem. Perhaps it has an easy solution for you. Just have a look into GRASS scripts, e.g.

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-29 Thread Roberto Marzocchi
Ok. I do a commit with some changes to nnbathy.py command: - correction in read region - correction due to the problem of v.out.ascii -r - correction suggested by Luca for string concatenation A problem remains open when using v.surf.nnbathy from GUI because the name of the vector map with

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-27 Thread Martin Landa
Hi, 2018-03-27 14:48 GMT+02:00 Roberto Marzocchi : > fout.write(parts[0]+' '+parts[1]+' '+parts[3]) --> is part of the > actual command. > > I can do debug, but I would like to be cautious in completly rewriting the > module without the endorsement of the

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-27 Thread Roberto Marzocchi
Hi Luca, fout.write(parts[0]+' '+parts[1]+' '+parts[3]) --> is part of the actual command. I can do debug, but I would like to be cautious in completly rewriting the module without the endorsement of the authors. R 2018-03-27 12:06 GMT+02:00 Luca Delucchi : > On 26

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-27 Thread Luca Delucchi
On 26 March 2018 at 14:50, Roberto Marzocchi wrote: > from grass.pygrass.vector import VectorTopo > pnt = VectorTopo(options['input']) > pnt.open(mode='r') > test=pnt.read(1) > if test.is2D==True: >fout.write(parts[0]+' '+parts[1]+' '+parts[3]) > else: >

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-26 Thread Roberto Marzocchi
from grass.pygrass.vector import VectorTopo pnt = VectorTopo(options['input']) pnt.open(mode='r') test=pnt.read(1) if test.is2D==True: fout.write(parts[0]+' '+parts[1]+' '+parts[3]) else: fout.write(parts[0]+' '+parts[1]+' '+parts[4]) Maybe not the best code.. but it seem to works..

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-26 Thread Helmut Kudrnovsky
>I have no idea of a possible python command.. I will do some >search.. Have you any suggestion? Have a look into pygrass https://grass.osgeo.org/grass74/manuals/libpython/pygrass_vector.html - best regards Helmut -- Sent from: http://osgeo-org.1560.x6.nabble.com/Grass-Dev-f3991897.html

Re: [GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-26 Thread Roberto Marzocchi
I have tested my solution and it works. Can I do the push on SVN? My question is for Martin Landa who is mentor for the authors of the command and did the last commit of nnbathy.py command? I found also two more problem in the v.surf.nnbathy command. 1) The command crash. It is probaby due to

[GRASS-dev] ERROR grass addon v/r.surf.nnbathy using a lat/lon location

2018-03-23 Thread Roberto Marzocchi
Dear all, I am using r.surf.nnbathy (on GRASS 7.4) Using a projected location (meters) I obtain a result Using lat/lon location I see the following error: > Traceback (most recent call last): > File > "/home/roberto/.grass7/addons/scripts/r.surf.nnbathy", line > 80, in > main() >