Solved

NeighborFinder: Try to get elevation but get this error: IFMELine was given an index beyond its current range

  • 5 January 2018
  • 8 replies
  • 5 views

Badge +2

Hello,

I am trying to get the elevation using a NeighborFinder. I get this error:

IFMELine was given an index beyond its current range (see workspace in attached)

And I get 'nan' for the elevation. Any idea why?

icon

Best answer by markatsafe 10 January 2018, 20:47

View original

8 replies

Badge +3

You do not have any z value on neither the line or the point.

(no z value does not mean that the elevation is zero, it means there is no such value)

You could add elevation at the creator(s) or use a 3d forcer to add a z value.

Badge +3

btw nan = not a number

Userlevel 2
Badge +17

I think the error has been caused by a defect of the NeighborFinder. Hope someone from Safe to clarify this.

Badge +2

You do not have any z value on neither the line or the point.

(no z value does not mean that the elevation is zero, it means there is no such value)

You could add elevation at the creator(s) or use a 3d forcer to add a z value.

Oups I have just seen that one of my creator creates a "line" with 0,0 ; 0,0 coordinates. This results from an old test. But the following VertexCreators create indeed a line with z values

 

 

Badge +2

I found a workaround but indeed, it seems there is a bug with the "Take z From Candidate" functionality of the NeighborFinder.

I use a densifier to densify the vertex of the candidates. Then I used a chopper (1 vertex) to get points. I recorded the z in an attribute and use merge attribute in the NeighborFinder. Not efficient but effective :)

Badge +2
@lau This does seem to be a defect in the NeighborFinder. When the point (Base) is past the end point of the line (candidate) then you'll see this error. We'll get this fixed.

 

Badge +2
@lau This does seem to be a defect in the NeighborFinder. When the point (Base) is past the end point of the line (candidate) then you'll see this error. We'll get this fixed.

 

Indeed. Thank you for the follow up!

 

 

Badge +3
@lau This does seem to be a defect in the NeighborFinder. When the point (Base) is past the end point of the line (candidate) then you'll see this error. We'll get this fixed.

 

This issue also counts for Measures. By the way the error is still present in build 18528

 

 

Reply