Re: [GRASS-user] Break lines in vector A at locations of points in vector B

2018-03-06 Thread thepattonian
Vincent,

I’ll try your suggestion, thanks. Vector B is not a subset of vector A, but 
rather it contains all vertices of vector A.

--
Eric

> On Mar 6, 2018, at 1:26 PM, Vincent Bain  wrote:
> 
> Hello Eric,
> did you try v.split on vector A, with the vertices argument set to 2?
> (or maybe does vector B contain only a subset of A vertices)
> 
> Vincent.
> 
> Le mardi 06 mars 2018 à 16:50 +, Patton, Eric (NRCan/RNCan) a
> écrit :
>> Hi,
>> 
>> I have two vector maps, vector A is a line vector representing
>> coastline, and vector B is vector points which are the vertices of
>> vector A. Is there a way to split vector A into line segments using
>> vector B as breakpoints? 
>> 
>> v.edit tool=break kind of does this, but seems to want coordinates
>> given one at a time. I have hundreds of thousands of points, and this
>> doesn't seem an efficient way of doing it. 
>> 
>> Thanks,
>> 
>> ~ Eric. 
>> 
>> ___
>> grass-user mailing list
>> grass-user@lists.osgeo.org
>> https://lists.osgeo.org/mailman/listinfo/grass-user
> ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/grass-user
___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Re: [GRASS-user] Joining attributes of points to spatially-coincident line vertices

2018-03-06 Thread Patton, Eric (NRCan/RNCan)
>Not sure what your overall goal is here. (Won't the slopes along the coastline 
>all be about 0?). If there are >two adjacent points with different slopes from 
>the raster, which value would you want to attach to the line >segment between 
>those points?

I am trying to assign a general raster slope to a segment of coastline that is 
representative of the steepness of that roughly 100m2 raster pixel. Yes, 
technically the slope is 0 at the waterline, but what we are trying to assign 
to the vector shoreline is a slope value that is more representative of the 
backshore, to give an idea of how sensitive the coastline might be to sea-level 
inundation and erosion. I was able to assign the raster slope to the vector 
points using v.distance, but getting the slopes onto the coastline line vector 
with a spatial join seems to be very difficult if not impossible in Grass.
As for the problem of which of two points to assign to a vector line segment, I 
thought there might be a function to choose the median value of the two points, 
or some other statistic – ArcGIS provides a way to do this through their 
spatial join module.
>But you could approach the task in a different, more straightforward way:
>Run the module v.split on your original coastline line vector and split to 
>segments at whatever max distance >you choose, Then run v.rast.stats with that 
>split line as input and use your slope raster to derive slopes. The >result 
>will be an attribute table attached to the coastline vector with min,max,mean, 
>etc raster values for >each line segment.

Your method is interesting, I would like to try that on a sample section and 
see how the processing time compares to the v.distance method. Since I am 
working with the entire coastline of Canada, I don’t think I will have time to 
rerun the process with v.rast.stats. I might take several weeks just to 
complete the v.split portion.
Thanks for the ideas though,
~ Eric.

On 03/06/2018 06:02 PM, thepatton...@gmail.com 
wrote:



I have a high-resolution vector coastline, and I extracted the vertices of this 
coastline to points using 'v.to.points use=vertex'. I am trying to find the 
nearest raster slope value from another map to these points, and then upload 
this slope to the attribute table of the vector points coastline. To do this, I 
converted the raster slope map to points with r.to.vect, and successfully 
uploaded the nearest slope value from the now vector slope map to the vector 
points coastline with v.distance, using a dmax=200.



Ok, now to my problem: I want to get the vector coastline points back onto the 
original vector *lines* coastline, with all the point attributes as well. Since 
the vector coastline points were derived from the vertices of the coastline map 
in the first place, they are spatially  coincident, but I can't find a 
processing method that does this. Ideally, I suppose the coastline points map 
could act as breakpoints to the coastline polyline map, and the attributes 
would be transferred based on a buffer of something like one metre or less.



Any ideas on how I might do this?



Thanks,



--

Eric

___

grass-user mailing list

grass-user@lists.osgeo.org

https://lists.osgeo.org/mailman/listinfo/grass-user



--

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] Joining attributes of points to spatially-coincident line vertices

2018-03-06 Thread Micha Silver

  
  
Not sure what your overall goal is here. (Won't the slopes along the
coastline all be about 0?). If there are two adjacent points with
different slopes from the raster, which value would you want to
attach to the line segment between those points?

But you could approach the task in a different, more straightforward
way:
Run the module v.split on your original coastline line vector and
split to segments at whatever max distance you choose, Then run
v.rast.stats with that split line as input and use your slope raster
to derive slopes. The result will be an attribute table attached to
the coastline vector with min,max,mean, etc raster values for each
line segment.
 

On 03/06/2018 06:02 PM,
  thepatton...@gmail.com wrote:


  
I have a high-resolution vector coastline, and I extracted the vertices of this coastline to points using 'v.to.points use=vertex'. I am trying to find the nearest raster slope value from another map to these points, and then upload this slope to the attribute table of the vector points coastline. To do this, I converted the raster slope map to points with r.to.vect, and successfully uploaded the nearest slope value from the now vector slope map to the vector points coastline with v.distance, using a dmax=200.

Ok, now to my problem: I want to get the vector coastline points back onto the original vector *lines* coastline, with all the point attributes as well. Since the vector coastline points were derived from the vertices of the coastline map in the first place, they are spatially  coincident, but I can't find a processing method that does this. Ideally, I suppose the coastline points map could act as breakpoints to the coastline polyline map, and the attributes would be transferred based on a buffer of something like one metre or less. 

Any ideas on how I might do this?

Thanks,

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


-- 
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] Break lines in vector A at locations of points in vector B

2018-03-06 Thread Vincent Bain
Hello Eric,
did you try v.split on vector A, with the vertices argument set to 2?
(or maybe does vector B contain only a subset of A vertices)

Vincent.

Le mardi 06 mars 2018 à 16:50 +, Patton, Eric (NRCan/RNCan) a
écrit :
> Hi,
> 
> I have two vector maps, vector A is a line vector representing
> coastline, and vector B is vector points which are the vertices of
> vector A. Is there a way to split vector A into line segments using
> vector B as breakpoints? 
> 
> v.edit tool=break kind of does this, but seems to want coordinates
> given one at a time. I have hundreds of thousands of points, and this
> doesn't seem an efficient way of doing it. 
> 
> Thanks,
> 
> ~ Eric. 
> 
> ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/grass-user
___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

[GRASS-user] Break lines in vector A at locations of points in vector B

2018-03-06 Thread Patton, Eric (NRCan/RNCan)
Hi,

I have two vector maps, vector A is a line vector representing coastline, and 
vector B is vector points which are the vertices of vector A. Is there a way to 
split vector A into line segments using vector B as breakpoints? 

v.edit tool=break kind of does this, but seems to want coordinates given one at 
a time. I have hundreds of thousands of points, and this doesn't seem an 
efficient way of doing it. 

Thanks,

~ Eric. 

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

[GRASS-user] r.in.lidar build errors

2018-03-06 Thread Rich Shepard

  I think there was a recent thread on *.in.lidar modules, but I paid no
attention as I'm not currently using lidar data.

  After checking out the latest from the grass7_trunk svn repository I
configured the source tree and tried to build it. There are errors in the
*.in.lidar modules; each has errors when I try to build each one separately:

(r.in.lidar)
: /error while loading shared libraries: libproj.so.12: cannot open shared 
object file: No such file or directory
../../include/Make/Html.make:14: recipe for target 'r.in.lidar.tmp.html' failed
make: *** [r.in.lidar.tmp.html] Error 1
rm r.in.lidar.tmp.html

(r3.in.lidar)
: /error while loading shared libraries: libproj.so.12: cannot open shared 
object file: No such file or directory
../../include/Make/Html.make:14: recipe for target 'r3.in.lidar.tmp.html' failed
make: *** [r3.in.lidar.tmp.html] Error 1
rm r3.in.lidar.tmp.html

(v.out.lidar)
: error while loading shared libraries: libproj.so.12: cannot open shared 
object file: No such file or directory
../../include/Make/Html.make:14: recipe for target 'v.out.lidar.tmp.html' failed
make: *** [v.out.lidar.tmp.html] Error 1
rm v.out.lidar.tmp.html

(v.in.lidar)
:: error while loading shared libraries: libproj.so.12: cannot open shared 
object file: No such file or directory
../../include/Make/Html.make:14: recipe for target 'v.in.lidar.tmp.html' failed
make: *** [v.in.lidar.tmp.html] Error 1
rm v.in.lidar.tmp.html

  Your suggestions on resolving these issues will be appreciated.

TIA,

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

[GRASS-user] Joining attributes of points to spatially-coincident line vertices

2018-03-06 Thread thepattonian

I have a high-resolution vector coastline, and I extracted the vertices of this 
coastline to points using 'v.to.points use=vertex'. I am trying to find the 
nearest raster slope value from another map to these points, and then upload 
this slope to the attribute table of the vector points coastline. To do this, I 
converted the raster slope map to points with r.to.vect, and successfully 
uploaded the nearest slope value from the now vector slope map to the vector 
points coastline with v.distance, using a dmax=200.

Ok, now to my problem: I want to get the vector coastline points back onto the 
original vector *lines* coastline, with all the point attributes as well. Since 
the vector coastline points were derived from the vertices of the coastline map 
in the first place, they are spatially  coincident, but I can't find a 
processing method that does this. Ideally, I suppose the coastline points map 
could act as breakpoints to the coastline polyline map, and the attributes 
would be transferred based on a buffer of something like one metre or less. 

Any ideas on how I might do this?

Thanks,

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