Question

Finding the closest lines close to GPS points


Badge +1

Hi all,

I have a GPS trajectory and I would like to select the lines (roads) close to GPS point. I am using NeigborFinder to do that. However, all lines are getting matched even though as you can see in the images I have roads that should be not selected . When NeigborFinder finds a closest lines to a point, does it not find the same line as closest line to consecutive point?

How can I solve this problem? Thanks in advance.

 

 


5 replies

Badge

When the points cross a road that is not travelled NeighborFinder won't know that it's not travelled. However, if you make a line out of the points you can filter away results that differ too much in angle.

Userlevel 5
Badge +25

I think what might work for you is:

  • GeometryExtractor on the points to store the original point geometry
  • AnchoredSnapper using the lines as anchor
  • GeometryReplacer to get the original points back, but now they have the attributes of the line they snapped to.
Badge +2

@jugoslaviaa I think what you want is to match the track of the GPS points, not the individual points. If you match the individual points, then you'll probably get the cross streets matched where the GPS trajectory crosses an intersection. So you might want to try using:

- LineBuilder to string the GPS points into a GPS track

- Matcher or ChangeDetector - use the new ChangeDetector and the Fréchet distance (2019 and up)

Badge +1

@jugoslaviaa I think what you want is to match the track of the GPS points, not the individual points. If you match the individual points, then you'll probably get the cross streets matched where the GPS trajectory crosses an intersection. So you might want to try using:

- LineBuilder to string the GPS points into a GPS track

- Matcher or ChangeDetector - use the new ChangeDetector and the Fréchet distance (2019 and up)

Exactly, I would like to snap this GPS trajectory to road network. I am digging the ChangeDetector but could figure out. Road network should go to the Original port and lines from GPS track to the revised or the otherway?

Badge +2

Exactly, I would like to snap this GPS trajectory to road network. I am digging the ChangeDetector but could figure out. Road network should go to the Original port and lines from GPS track to the revised or the otherway?

@jugoslaviaa I think I should have suggested Matcher instead of ChangeDetector in this case. I edited the comment above to reflect this... If you upload a small sample dataset as, say, a Geopackage we might be able to experiment a bit

Reply