Top Banner
Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF Courtney Maxson Spatial Business Systems (SBS)
34

Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Apr 08, 2017

Download

Technology

Safe Software
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Automated Bulk Conversion of 250,000+

CAD and Corresponding Raster Files to PDF

Courtney MaxsonSpatial Business Systems (SBS)

Page 2: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Hello!Courtney Maxson• Certified FME Professional• Certified FME Trainer• M.S. GIS, Johns Hopkins• SBS Employee – 2.5 years

Spatial Business

Systems• Spatial integration firm based

in Lakewood, CO• FME Gold-level reseller• 5 certified FME professionals

and 2 trainers

Page 3: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Problem

Page 4: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Problem• Utility with 250,000 + MicroStation DGN’s• DGN’s only viewable via Bentley Viewer• Not compatible with mobile devices• Access needed in field• Manual creation process

Page 5: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Project Objectives• Convert DGN’s and associated TIFF’s and Borders

to PDF files• Process multiple DGN’s simultaneously• Produce 1 PDF per DGN with few exceptions• Customize output based on DGN type• Automate PDF conversion process

Page 6: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Production Process Diagram

Page 7: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

FME Solution

Page 8: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Production Process Diagram

Page 9: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

FMESolutionProcess• DGNfilesarecopiedtoatemporarydirectory,thenmergedwiththeborder.

• ClientdevelopedaC#scriptthatinitiatesMicroStationandmergestheborderintotheDGNaslevel“border”.

• Thefilesarecopiedbeforebeingmergedtoavoidalteringtheoriginalfiles.

• FMEcopiestheDGNfilesandassociatedTIFFfiles,callsthemergescript,thenconvertsthemergedDGNfilesandassociatedTIFF’stoPDFfiles.

• Atthebeginningofeachrun,FMEexecutesaPythonscriptthatdeletesallDGNandTIFFfilesfromthetemporarydirectory.

Page 10: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Runner Workspace

WorkspaceParameters:§ TEMP_DIR§ SOURCE_DATASET_CSV§ SOURCE_DATASET_CTL_DGN§ TYPES_TO_COPY_MERGE§ DELTAS_ONLY

Page 11: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Step 1: Copy Files to Temp Directory

StartupPythonScript

§ Empties Temp directory§ Reads DGN directories via

CSV and Directories and File Pathnames Readers

§ Copies DGN’s to Temp directory

§ Copies TIFF’s to Temp directory

Page 12: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Step 2: Merge Temp DGN’s

C#ScriptFunctions:§ MergeDGN’sandborders§ ExtractvaluesforTIFF

alignment• Temppath• LowerLevelX,Y• DimensionY• PixelsizeX,Y

§ CreateRasterTable.csv

Page 13: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Step 3: Create PDF Files

Page 14: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Conversion Workspace

WorkspaceParameters:§ SOURCE_DATASET_DGNV8§ SOURCE_DATASET_TIFF§ SOURCE_DATASET_CSV

§ Converts DGN to single PDF with associated borders and/or TIFF’s

§ Can process multiple file sets simultaneously

§ Generates multiple PDF’s from single source DGN, when required

Page 15: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Conversion: Read DGN Elements

Page 16: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Conversion: Manipulate DGN TextIssues/Workarounds

§ DimensionTextBug• Manualconversion

§ Degree(°)Notavailableinfont• Converttorichtext

§ XMLescapecharacters• Convertedtoescapestring• &replacedwith&

§ ΩandΦ notsupportedbyPDFWriter• ReplacedwithtextOHMand

PH

Page 17: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Conversion: Manipulate Non-Text

§ Removemulti-textnodes§ ResolveLineStyledomains

Page 18: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Conversion: Manipulate TIFF

Issues/Workarounds§ TIFFalignment

• UseRasterTable.csvcreatedbyC#script§ TIFF’sprocessingwithoutDGN§ MultipleDGN’swithsamename

• AdddirectorypathtoRasterTable.csv• Createfanout_attr

Page 19: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Conversion: Style and Write to PDFForeachnon-ZSubeng DGN:§ QueriesSubeng DBtodetermine

#ofoutputPDF’s§ Removesunneededlevelsfor

eachplantype§ Creates1PDFperplan

Page 20: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDFFormatWriter Transformer

TransformerParameters:§ FME_PROCESS_GROUP_BY§ TARGET_DATASET

§ Determines extent of all elements per fanout_attr

§ Calculates extent orientation§ Formats PDF based on orientation§ Writes DGN and TIFF elements to

different layers

Page 21: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

PDF Results

Page 22: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF
Page 23: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF
Page 24: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

SubstationOneLine

Page 25: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF
Page 26: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF
Page 27: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Initial Run

Page 28: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

FME Server Solution

• Distributed environment

• 3 Production Servers• 10 Engines

• ProductionServer:o Dual-coreCPUo 8GBRAMo 300GBHardDriveo 2PermanentEngines

• TemporaryProductionServer1:o Quad-coreCPUo 16GBRAMo 300GBHardDriveo 4TemporaryEngines

• TemporaryProductionServer2:o Quad-coreCPUo 16GBRAMo 300GBHardDriveo 4TemporaryEngines

Page 29: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Estimated Performance

Ctldgn Subeng Trans TOTALTotalDGN 122745 28561 551 151857

AvgTime/Job(Sec) 12 26 15TotalEstHrs- 1Engine 409.15 206.27 2.29 617.71TotalEstHrs - 10Engines 61.771

Page 30: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Automation / Long-Term Solution

Page 31: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Long Term FME Server Solution

• 1 Production Server• 2 Engines• Scheduler - Runs every

hour• DELTAS_ONLY = Yes

Page 32: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Deltas Only SelectionForeachnon-ZSubeng DGN:§ QueriesSubeng DBtodetermine

#ofoutputPDF’s§ Removesunneededlevelsfor

eachplantype§ Creates1PDFperplan

• Onlyprocessesnew/modifiedDGN’s• ComparesmodifieddatesofDGNandPDF

Page 33: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Final Steps

On Production Servers:• Install/ Configure FME

Server• Run subset• Make performance

adjustments• Get final client

approval• Kick-off full initial run• Setup Schedule

Page 34: Automated Bulk Conversion of 250,000+ CAD and Corresponding Raster Files to PDF

Thank you!

Courtney [email protected]

https://www.linkedin.com/in/courtney-maxson-50727983/