Skip to main content
Question

Transfer attribute data (elevations) from points to the vertices of a Z enabled polyline?


I’m trying to use FME to transfer attribute data (elevations) from points to the vertices of a Z enabled polyline. I am using an Attribute Keeper so the elevations don’t get dropped, Chopper to break up the lines, SpatialRelator to relate the points and vertices, and rebuilding the lines using the Linejoiner. The Eastings and Northings are transferring over but not the elevations. Any suggesting’s to what the issue could be? Is there an alternative solution?

12 replies

takashi
Influencer
  • October 6, 2017

I suppose the elevations that should be related to a single polyline are multiple numeric values, and the number of them should be equal to the number of vertices of the polyline. Is it right?

If so, how can a single polyline feature contain the multiple elevations? A list attribute (e.g. _elevations{0}="100", _elevatins{1}="110", _elevation{2}="120" ...), or a comma-concatenated string (e.g. _elevations="100,110,120,...", or else?


takashi
Influencer
  • October 7, 2017

If multiple point features other than the polyline feature contain the attribute that stores the elevation for each point, you can insert a 3DForcer between the SpatialRelator and the LineJoiner to set the elevation value to z-coordinate of the vertices.


  • Author
  • February 8, 2018
takashi wrote:

If multiple point features other than the polyline feature contain the attribute that stores the elevation for each point, you can insert a 3DForcer between the SpatialRelator and the LineJoiner to set the elevation value to z-coordinate of the vertices.

Takashi - The 3DForcer didn't work.

 

 

I'm trying to extract z values from a surface. I have a z-enabled line feature that represents the middle of a stream. This line has approximately lets say 50 vertices. Is it possible to extract the elevation for the vertex?

 

 

Without automating this process it becomes time consuming, I have to assign elevations to each vertex manually.

 

 

Hope this helps.

 

Thanks

 

 


takashi
Influencer
  • February 8, 2018
rickyrbanga wrote:
Takashi - The 3DForcer didn't work.

 

 

I'm trying to extract z values from a surface. I have a z-enabled line feature that represents the middle of a stream. This line has approximately lets say 50 vertices. Is it possible to extract the elevation for the vertex?

 

 

Without automating this process it becomes time consuming, I have to assign elevations to each vertex manually.

 

 

Hope this helps.

 

Thanks

 

 

Does (x, y) coordinates of every vertex of the line exactly match (x, y) of a corresponding point? Could there be a small gap (tolerance) between them? If you could share a sample dataset (points and a line) with us, it would help us to understand the conditions correctly.

 

 


gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • February 8, 2018

you could extract begin and end coordinate of every line (after chopping or segmenting the polyline) or use the vertices required, then drape the features on the surface.

Then extract the z of the draped features.

If you rebuild the line, then rebuild the line and want to keep the info, you either need a list (as Takashi said) or set them a a measure (f non-linear..) if needed.

Here is a pic where the roadcenterline is interpolated form the AHN.

I think i posted this befrore including script (acording to the image somewhere feb. 2016)

 

Other method would be to use neighbourfinder or poinptonpoint with tolerance.


  • Author
  • February 16, 2018
takashi wrote:
Does (x, y) coordinates of every vertex of the line exactly match (x, y) of a corresponding point? Could there be a small gap (tolerance) between them? If you could share a sample dataset (points and a line) with us, it would help us to understand the conditions correctly.

 

 

I think there's a misunderstanding or I could have been unclear on the question. I'm not trying to extract a elevations off a point, rather off a surface. So I have a z-enabled line, with 50 vertices. The line is draped on a surface, I would like to extract elevation values and have them assigned to the vertices.

 

 


takashi
Influencer
  • February 16, 2018
rickyrbanga wrote:
I think there's a misunderstanding or I could have been unclear on the question. I'm not trying to extract a elevations off a point, rather off a surface. So I have a z-enabled line, with 50 vertices. The line is draped on a surface, I would like to extract elevation values and have them assigned to the vertices.

 

 

I'm still unclear the requirement, but if you just need to extract coordinates of every vertex of a line as a list attribute, consider using the CoordinateExtractor (Mode: All Coordinates).

 

 


takashi
Influencer
  • February 16, 2018
rickyrbanga wrote:
I think there's a misunderstanding or I could have been unclear on the question. I'm not trying to extract a elevations off a point, rather off a surface. So I have a z-enabled line, with 50 vertices. The line is draped on a surface, I would like to extract elevation values and have them assigned to the vertices.

 

 

I'm afraid that no one could understand your requirement correctly, unless you could post a sample dataset to clarify the actual data conditions.

 

 


  • Author
  • February 16, 2018
takashi wrote:
I'm afraid that no one could understand your requirement correctly, unless you could post a sample dataset to clarify the actual data conditions.

 

 

Do you have an email address where I can send you the sample dataset? Its too big to post here.

  • Author
  • February 17, 2018
rickyrbanga wrote:
Takashi - The 3DForcer didn't work.

 

 

I'm trying to extract z values from a surface. I have a z-enabled line feature that represents the middle of a stream. This line has approximately lets say 50 vertices. Is it possible to extract the elevation for the vertex?

 

 

Without automating this process it becomes time consuming, I have to assign elevations to each vertex manually.

 

 

Hope this helps.

 

Thanks

 

 

fme.zip

 

 

Okay nm I got it small enough. So there are two layers in there. What I'm trying to do is assign z values to the River_Instream dataset.

 

 


takashi
Influencer
  • February 17, 2018
rickyrbanga wrote:
fme.zip

 

 

Okay nm I got it small enough. So there are two layers in there. What I'm trying to do is assign z values to the River_Instream dataset.

 

 

I got an FGDB dataset that contains two feature classes - 'Instream' and 'River_Instream'. The 'Instream' feature class contains a 3D line feature, but the 'River_Instream' (your target layer) contains nothing. Could you elaborate what you want to do with the dataset?

 

 


  • Author
  • February 19, 2018
takashi wrote:
I got an FGDB dataset that contains two feature classes - 'Instream' and 'River_Instream'. The 'Instream' feature class contains a 3D line feature, but the 'River_Instream' (your target layer) contains nothing. Could you elaborate what you want to do with the dataset?

 

 

fme.zip

 

 

Sorry I attached the wrong file.

 

 

So what I have here is a feature class called "River_Instream". It is a z enabled line. If you look at the sketch properties for this layer you'll notice that there is X and Y values but no Z values. My goal using FME is to extract elevations from a surface and populate the missing z values for the "River_Instream" feature class.

 

 

 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings