Re: [GRASS-user] v.mapcalc

2021-03-14 Thread Micha Silver



On 3/14/21 11:07 AM, Enrico Gabrielli bonushenricus wrote:

Hi
How are you?
After solving thanks to Stefan and his r.slope.direction how to
calculate the slope along the keyline, now I have to solve how to
create parallels to the keyline. Nothing easier: see parallel! But I
have to create many. In the graphical modeler I can't learn how to use
the loop. Damn if I'm ignorant. But maybe v.mapcalc would also be very
handy. But it doesn't work for me. After installing ply it doesn't work
anyway.



Can you add some further information:

What is your operating system?

What version of GRASS?

When you say "I have to create many", do you mean many parallel lines at 
different distances?


Are you working with projected data? (I missed the previous thread on 
r.slope.direction, sorry if this has been mentioned before)


What scripting language do you prefer? python? bash shell script?

If python, what version is installed? (note that GRASS 7.8 has switched 
to python 3)


What is "keyline"? (i.e. please show the output from `v.info keyline`




Traceback (most recent call last):
   File "/usr/lib/grass76/scripts/v.mapcalc", line 429, in

 sys.exit(main())
   File "/usr/lib/grass76/scripts/v.mapcalc", line 415, in
main
 p.parse(expression)
   File "/usr/lib/grass76/scripts/v.mapcalc", line 191, in
parse
 self.parser.parse(expression)
   File "/usr/lib/python2.7/dist-packages/ply/yacc.py", line
333, in parse
 return self.parseopt_notrack(input, lexer, debug,
tracking, tokenfunc)
   File "/usr/lib/python2.7/dist-packages/ply/yacc.py", line
1063, in parseopt_notrack
 lookahead = get_token() # Get the next token
   File "/usr/lib/python2.7/dist-packages/ply/lex.py", line
393, in token
 newtok = self.lexerrorf(tok)
   File "/usr/lib/grass76/scripts/v.mapcalc", line 146, in
t_error
 (t.lineno, t.value))
SyntaxError: syntax error on line 1 near
''buff_l(keyline@PERMANENT,5)''

I used all possible quotes in the expression, but the result is always
the same

I don't want to use qgis (where there would be offset) because
r.slope.direction is in grass and it is very convenient, and also all
the rasters I use have them in grass. I would like to learn how to do
everything in GRASS.
Well, who knows if I'll succeed. As soon as I have some pennies I pay a
friend of mine who is a python developer: maybe it's better.

Thanks


--
Micha Silver
Ben Gurion Univ.
Sde Boker, Remote Sensing Lab
cell: +972-523-665918

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


Re: [GRASS-user] ITRF92 Not found.

2021-03-14 Thread javier Garcia Prieto
Thank you!
You are really great! This is going to be so much useful to Mexican people, You 
are very kind.

How can I help, How can I include other definitions for Mexico like ITRF08?

I remember that Grass has US states projection definitions in order to create 
sites, Is there a way that I can achieve the same?


Thanks again for all your effort and kindness.

Javier GarcĂ­a Prieto.

From: Markus Neteler 
Sent: Sunday, March 14, 2021 11:58 AM
To: javier Garcia Prieto 
Cc: GRASS user list 
Subject: Re: [GRASS-user] ITRF92 Not found.

Dear Javier,

On Sat, Mar 13, 2021 at 8:44 PM javier Garcia Prieto
 wrote:
>
> Dear Grass  fiends.
> I have a little problem and I don't Know if you can help me.
> When I try to create a new location from parameters or from map, or when I 
> try to import an ITRF92 from INEGI map, I got this message from console ITR92 
> not recoggnized and no parameters found.
>
> Is there a way in which I can add this parameters to Grass default list or 
> include them into default creation parameter list?

I have added an alias for the expanded ITRF92 name:

https://github.com/OSGeo/grass/pull/1460

(to be reviewed if correct).

Best,
Markus

PS: please copy terminal text (also) as text into the email, not only
as a screenshot.
___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] ITRF92 Not found.

2021-03-14 Thread Markus Neteler
Dear Javier,

On Sat, Mar 13, 2021 at 8:44 PM javier Garcia Prieto
 wrote:
>
> Dear Grass  fiends.
> I have a little problem and I don't Know if you can help me.
> When I try to create a new location from parameters or from map, or when I 
> try to import an ITRF92 from INEGI map, I got this message from console ITR92 
> not recoggnized and no parameters found.
>
> Is there a way in which I can add this parameters to Grass default list or 
> include them into default creation parameter list?

I have added an alias for the expanded ITRF92 name:

https://github.com/OSGeo/grass/pull/1460

(to be reviewed if correct).

Best,
Markus

PS: please copy terminal text (also) as text into the email, not only
as a screenshot.
___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] v.mapcalc

2021-03-14 Thread Enrico Gabrielli bonushenricus
Hi
How are you?
After solving thanks to Stefan and his r.slope.direction how to
calculate the slope along the keyline, now I have to solve how to
create parallels to the keyline. Nothing easier: see parallel! But I
have to create many. In the graphical modeler I can't learn how to use
the loop. Damn if I'm ignorant. But maybe v.mapcalc would also be very
handy. But it doesn't work for me. After installing ply it doesn't work
anyway.
> Traceback (most recent call last):
>   File "/usr/lib/grass76/scripts/v.mapcalc", line 429, in
> 
> sys.exit(main())
>   File "/usr/lib/grass76/scripts/v.mapcalc", line 415, in
> main
> p.parse(expression)
>   File "/usr/lib/grass76/scripts/v.mapcalc", line 191, in
> parse
> self.parser.parse(expression)
>   File "/usr/lib/python2.7/dist-packages/ply/yacc.py", line
> 333, in parse
> return self.parseopt_notrack(input, lexer, debug,
> tracking, tokenfunc)
>   File "/usr/lib/python2.7/dist-packages/ply/yacc.py", line
> 1063, in parseopt_notrack
> lookahead = get_token() # Get the next token
>   File "/usr/lib/python2.7/dist-packages/ply/lex.py", line
> 393, in token
> newtok = self.lexerrorf(tok)
>   File "/usr/lib/grass76/scripts/v.mapcalc", line 146, in
> t_error
> (t.lineno, t.value))
> SyntaxError: syntax error on line 1 near
> ''buff_l(keyline@PERMANENT,5)''
I used all possible quotes in the expression, but the result is always
the same

I don't want to use qgis (where there would be offset) because
r.slope.direction is in grass and it is very convenient, and also all
the rasters I use have them in grass. I would like to learn how to do
everything in GRASS.
Well, who knows if I'll succeed. As soon as I have some pennies I pay a
friend of mine who is a python developer: maybe it's better.

Thanks
-- 
Perito agrario Enrico Gabrielli
Tessera n. 633 Collegio Periti agrari prov. Di Modena
Biblioteca agricoltura: https://www.zotero.org/groups/aplomb/
https://it.linkedin.com/pub/enrico-gabrielli/9a/186/159
https://enricogabrielli76.wordpress.com/
https://www.inaturalist.org/observations/bonushenricus
skype: enricogabrielli (enricogabrielli76.per...@gmail.com)

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