Skip to main content
Question

Merging Multi-Part Annotations into Onne


kristen
Contributor
Forum|alt.badge.img+4

Hello Safers, 

I have a CAD file that has annotations inserted within it that should be one annotation but, for whatever reason, they were created as separate annotations: 

Above is an example of what I am struggling with. The text should simply read 10.88, but FME reads it as 1, and 0, decimal , 8, 8, and 0. What I would like to do is treat this as one annotation, and be able to round or eliminate extra numbers where needed (i.e. I only need two decimal precision, not three). Please note I already figured out the precision and rounding….I just need help with these multi-part annotations.

How would I go about doing this in FME?

Thanks!

2 replies

panda
Enthusiast
Forum|alt.badge.img+18
  • Enthusiast
  • July 18, 2025

I’m not sure if those text number can be link by autocad_entity_handle ID or at least they are in the same block. If they are you can use Aggregator with Group Processing on based on that matching ID. and you merge the attribute of autocad_text_string (i think that’s where the text attribute is?)

I’m also wasn’t sure how the CAD file is generated, but if you view it in CAD application, are those number separate already? if so, the only way I know how currently is to merge them as one is doing the buffer and then aggregate them together if they intersect, but this can introduce some errors, because it can grab near by text as well.


pratap
Contributor
Forum|alt.badge.img+11
  • Contributor
  • July 21, 2025

Combination of transformers must be used in this case. Initial step will be to identify the first letter.

Step1: Assigning unique numbering to all the text features

Step2: Use BoundingBoxReplacer to convert the text to polygon

Step3: Extend the boundary towards left side to check whether it intersects with any other polygon of other alphabet. If not intersected then these alphabets are to be considered as first letter

Step4: Considering the first alphabets from Step3, extend the polygon towards right side and check whether you find another alphabet. If intersected then loop it to find another one till it ends and join the identified alphabet every time one by one. based on the example provided, “10” will be in loop1, “10.”  will be in loop2,  “10.8” will be in loop3, “10.88”  will be in loop4.

Hope this helps


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