Skip to main content

I was wondering if it would be possible to extract the text information about a pipe, the pipe is represented by a linestring, with the text being in close versinity to the line. And if it's possible, also extract the letter representing a manhole or point to which a line can connect.To_FME_Forum

The red letters "A" represent manholes, the yellow line represents a pipe. Both the letters representing points and the lines have z values.

 

The white text under the yellow line in the center, represents the name of the pipe type (KL200), and the text values in the start and the end of the line represents the elevation of the pipe. The value with the large font text (56186 and 56185) is the ID of the manholes.

 

I have a structure in which I would like the data to fit but the whole, extract text information and apply it to the attribute of the nearest line or point is where my limited experience with FME holds me back. I have no idea if what I'm asking is even possible, but I think it might.

 

Sorry for the wall of text and if I have somehow broken any written/unwritten rules when posting.

 

  • Jan

@maulingo​  You can try the NeighborFinder transformer. Base would be the line and the Candidate the text.

For the elevations use a combination of the CoordinateExtractor/VertexCreator to extract the end points of the lines so you can match the elevation to the correct point, then join those back to your line.

If you can include a small sample of your data I'm sure someone will create a simple working example workspace.


Finder_01Hi @Mark Stoakes​ Thank you for replying. I managed to use NeigborFinder, after a few testfilters (one filtering on level name, and one filtering on content of text string), and I was hoping to use the text string used by the NeigborFinder and assigning it to the attribute of the line in the destination dataset, an Esri Geodatabase. But it seems like NeigborFinder does not output anything in the igds_text_string. I'm thinking it might merge the information onto the line somehow?

 


@maulingo​ At the bottom of the NeighborFinder is the panel "Merge Attributes" & "Generate List" . This tells the NeighborFinder how attributes should be exchanged between Candidate & Base. I think you'll want to use Merge Attributes.

If you can include a small sample of your data I'm sure someone will create a simple working example workspace.


@Mark Stoakes​ 

That did the trick. Under "Attribute Accumulation" I checked the box "Merge Attributes" and used Accumulation mode: "Only use Candidate".

 

Now I'm going to have a go at pulling the string values apart. The values all have one or two spaces before the first character in the string, " B500" or " KL250" and I have to pull out only the numbers in order to make them fit in an interger attribute.

 

I'm quite new to this FME, and to this forum. If there is anything I'm not doing that is concidered "good practice", besides uploading some data examples, please let me know and I will do my best to deliver.

 

Thank you again markatsafe, and I have a feeling you havent heard the last from this very young padawan.


@maulingo​  this tutorial summarizes many of the string operations available in FME. You're probably looking for StringSearcher and regular expressions, which is about halfway down that article.


Reply