Using transformers to modify data.
Recently active
I am reading an excel file, and seems most datetime fail to readIt shows for example HH:MM:SS for 5PM as 166000, and therefore it fails converting it, because 60 minutes is not valid.'20181007166000' is not an FME datetime. YYYYMMDD, HHMMSS[.X+][(+/-)zz] or YYYYMMDDHHMMSS[.X+][(+/-)zz] expected. Use a DateFormatter transformer to adjust the format of datetime strings.any ideas
I have a real-time XML feed that I am consuming that identifies road conditions. The issue is that the provider has changed the XML feed and grouped multiple segments with the same road condition into a single message. This message can grow and and shrink at any time. It can also add additional sub-elements to further describe the condition. In the past we were able to use an xfMap and expose the XML elements that way. This year, it has become more complicated. They've added sub-elements but FME is not resetting the list index to 0 for the sub-elements. Here are some examples:Example with Single Route & Multiple Conditions:Example with Multiple Routes & Single Condition:Example with Multiple Routes & Multiple Conditions:I've tried to leverage the XMLFragmenter, ListExploder, ListIndexer and no luck.The ultimate goal is to have a single record for each road segment with all the corresponding road condition attributes, message information, etc.Here are the full screen
I have to generate dynamically an polygon to cut the border of my raster image.i read this articel: https://knowledge.safe.com/articles/18764/setting-alpha-vs-nodata-color-and-numeric-data.htmlOption #2 sounds good, but there is a static polygon (creator transformer) used.i have to replace the creator and add something like a polygon generator based on my raster data.this is a demo pic. the red polygon is the polygon mentioned that I would have to calculate.I thought of something that compares the neighboring pixels and the strong deviation from this creates the line of the polygon. is there already a transformer? or is there another suitable solution for my problem?sorry, i'm quite new with FMEedit: picture updated. the area with green lines should be removed
have used this workspace to convert cad to shapefile , i want to get a closed polygons as the cad file was lines , so i tried to use area builder to get it , so if worked on the blocks its ok , but if i want parcels i get it not clear like these images 1- is the workspace that i used to solve the topology and build area with the lines 2- the result 3- first workspace that i used and there was no result because of topology.. can any one help getting the result same as the source at least the geometery and i will take the text layers after
When I was thinking of a solution for this question, encountered a strange behavior on conditional value setting.Calculate percentage of how many features in a group have a certain valueMy intention is to create a new attribute "_flag" and assign 1 if the attribute "Type" has a value, 0 otherwise. I believe that this conditional value setting in the AttributeCreator should work as expected.Workspace: (FME 2018.1.0.2)However, the result was:I cannot find any specific reason, but I suspect that the "feature table" technology has a defect related to this symptom. Could you please investigate this?
Hi,I´m transforming some features in DWG file. But I have problems with one specifical line.The DWG Reader show this line below:I´m using DWGStyler to configure the parameters for writter correctly, but I´m not able to keep with the correct line shape.Look below my DWG output.Can help me?Thank´s
I am trying to convert my feature class with its domain attribute values to CAD. I can convert my feature class to CAD (Autodesk AutoCAD Map 3D Object Data) but I have one issue! It converts the feature class perfectly and attaches the attribute to each features in CAD with Object Data in CAD but my domain values from my feature class does not show up in CAD attribute!!! I appreciate your help!Cheers,Mehran
Hi! I need to find Neighbor Lines from Blue (Base) to Red ones (Candidates) and have the average distance between these neighbors. So i splited lines into vertex and for each genererated find the closest line and then calculate average with a StatisticsCalculator. It worked graat but only for one Neighbor. I tried use NeighborPairFinder but it doesn't work to, becouse it found neighbors when Blue lines have more than one neighbor.Any suggestion?
I would like to know if anyone has published a data source to Tableau Server from FME
I have a need to sample 10% of a data set. I use the Counter and then the Statistics Calculator to get the total record count. From there, the Expression Evaluator is used to multiply that total count by 10% (setting to a whole number). The Variable Setter then sets that value to a variable. The variable is used for the N input on the Sampler. I do not get an error, but no records are output from Sampler. I have confirmed there is a value in that variable (using eh Variable Retriever). Enclosed are the details. Any suggestions?
Projections Changes
I have two ways I've been going about this. 1 - dissolving hexagons, keeping any at least 3 contiguous hexagons in size. Any more than 20 hexagons in size need to be divided into being at least 3 contiguous hexagons in size. I've used the PointClusterer transformer (on the centre points) when I had only 2 large polygons that needed to be divided, however, when I have over 12 polygons it's not working so well (perhaps due to the irregular spatial distribution and oddly-shaped polygons).2 - I've looked at trying to divide the polygons directly, with less success (trying to determine the length and width didn't work so well with the irregularly-shaped polygons from the dissolved hexagons). Does anyone have any idea of how to make either method work, or have another idea of how to do this?
HiI have 2 suppliers with the same attribute names. When I link them both to the featuremerger, I can only see one set of attributes to work with. How do I see both sets of data without renaming all the attributes?Andrew
Hi all, I had a script working on 2.7 (our previous default) and have now switched to 3.6 to keep up to date.I am getting a syntax error on line 18, but I can't see why, it is probably something obvious I am missing... Also any feedback on the script would be cool, I am still new to python so would be appreciated! Thanks in advance#import libraries that we will potentially needimport difflibimport fmeimport fmeobjects#create the class for execution, as per the FME spec:#https://docs.safe.com/fme/html/FME_Desktop_Documentation/FME_Transformers/Transformers/pythoncaller.htmclass addressMatch(object): def __init__(self): self.dataD = [] self.pread = '' self.outputIndex = 0 self.tmp = 0 self.matchRate = 0 def input(self,feature): if self.pread <> feature.getAttribute('CURRENT_ADDRESS') and self.pread <> '':#Error here for index, item in enumerate(self.dataD): self.tmp = difflib.SequenceMatcher(Non
I have some DWG files with data drawn as blocks with attributes. When I look at these in Data Inspector, I notice that the block attributes shows up in two ways:I've read through https://knowledge.safe.com/articles/59335/autocad-dwg-block-attribute-extraction.html and see that while I can access the attribute info from the attribute lists (top marking) it would be a lot easier to just grab the info as shown at the bottom. The problem is I can't find this via e.g. the attribute exposer. Anyone got a good idea?(Demo DWG attached)
I am trying to add a GeoTIFF orthophoto to a TIN surface I generated trom a raster (TIFF) DTM. I have used the TINgenerator to get TIN_Surface from my DTM, that I send to the Geometry-port on an ApperanceSetter. The ortophoto is sent trough an ApperanceStyler and then into the Apperance-port of the AppearanceSetter. I expected the ApperanceSetters' Output-port to give me the 3D terrain model in colours. Instead I get the ortophoto added to each triangle of the TIN-model. Doesn't look very nice. I have been trough the articles here, as well as reading on the various possible transformers available. Currently simply baffled. I must have missed the most obvious solution to this, and I must have been looking straight at it several times already. What transformer should I have used? And the settings?
Hi there, I've encountered a strange anomoly that's left me baffled. Etiher that, or I'm missing something quite badly... Anyway, I was wondering if anyone has encountered a similair scenario. I've got set of shape files (Polygons) with the coordinate system LL-WGS84, and in my workspace, I use the reprojector to convert them to AFRICA-LM-CONIC. I then use the AreaCalculator transformer to generate the Square Km measurements for them. However, for those of you who are familiar with ArcMap, if I do it there via reprojection and calculating geometry, my results are out, by a small amount. I've triple check all my input and output projection settings in both FME and Arc, but no matter what, my measurements don't match up. For example. VALLEYS.shp Arc gets - 251936.47 Km² Fme gets - 260142.65 Km² About a 3.15% difference. Enough to create issues for what I'm trying to do. And I just want to make it absolutely clear, that in both application, I conver
Using NeighborFinder and merged two types of lines representing the upper and lower part of the slope in 2d (where bottom's points ware Line Base and Top were candidates) Now I would like to do it in 3d. I've used CoorinateExtractor and 3DForcer, so I have a pit height for short lines, but now I have no idea how to change the direction towards the top.
I want to search attributes from one table in another and extract them irrespective of case sensetive. For example MAB in one table should be searched in another table and find MAB or mab or Mab ?
Hi.I've used RasterMosaicker before without problems, but now it gives me issues.Another FME translation generates a folder of JPEG raster tiles, and I'm now attempting to join them together in a single raster mosaic. This fails, overlaying each tile on top of each other.All the tiles are 2000x2000 pixels, and the resulting raster may easily be 15x that much. Is this a problem ?I've checked both "Generate World File" and "Write EXIF tags" in the final JPEG writer in the original translation, but this doesn't seem to make it work.Any insights into this issue will be appreciated.Cheers
I am creating a DWG file from a Shape file. All features of a certain type in the DWG file have distinct colors, line widths and layer names. When users open the DWG file in AutoCAD, they cannot change the properties globally using the layer table. They can only change the properties interactively per feature. How can I remedy that using FME AutoCAD writer settings?Thanks, Gido
I am looking to capture all features that are duplicated in dataset. The duplicated filter removes duplicates but keeps one unique feature. I need to capture the unique one that has been duplicated as well. Can anyone help?
I would like to create a terrain shadow by mixing Hill shade and Slope. The starting point is a DEM-file. I have used the RasterHillShader and the RasterSlopeCalculator to generate the basics. But in the next step I would like to mix these two by adjusting the min and max values and multiplying one layer on top of the other. Are there any transformers that could do this? I am guessing that the RasterExpressionEvaluator might be able to do the min-max limit? If so I could need some help with the correct syntax. If there is some way to adjust contrast and add some gausian blur that would be a welcome bonus.
I'm trying to convert an XML file to the data I need.Reading the file as text_line_data gives better results as reading it as XML. Probably because FME does not recognize the schema.The problem I encounter is that sometimes the attribute I need is a single child attribute. But sometimes it exists multiple times.Using an XMLFlattener and exposing the child element gives an attribute when it exists 1 time. But with multiple occurrences I need to use a ListExploder to create the attribute.I now use a Tester to test if the child attribute is empty and then reroute the data to ListExploder. But I doubt there is a simple option I don't see?
I am performing a combination of inserts and updates to sde db. I continue to receive this message:Error while retrieving an ArcObjects update cursor for the table/feature class 'TRANS.PipeSegment'. The error number from ArcObjects is: '-2147215975'. The error message from ArcObjects is: {The number of points is less than required for feature}I have read the ESRI documentation regarding this message and performed all workarounds. However, I do not believe they apply to this particular situation. Furthermore, I have inspected the geometry of the features and everything checks out. I have used this workspace in the past with no issues, but since updating to recent builds I have experienced this never-before-seen problem. For all incoming features, I have the fme_db_operation attribute set to either UPDATE or INSERT accordingly. upon checking the failing feature, it does have the expected value for fme_db_operation.The writer is configured as shown below:This is a su