Salt la conținutul principal

Parse diagrams

Extract information from engineering diagrams by detecting and mapping assets and files. Parse all assets and files from the same location or configure detection parameters to narrow down to a subset. Review and verify the automatic mappings as part of the parsing process.

Before you start

Parse a diagram

  1. Navigate to Data management > Contextualize > Diagram parsing.

  2. Select the location containing the engineering diagrams.

  3. Select the file to parse, and then select

    • Run parsing Select a symbol library for detecting symbols in the diagrams.

    • Run advanced parsing to configure detection parameters:

      Configure filters: Select the assets or files tab and filter to find the items to parse.

      Configure text detection: Adjust the text detection settings to improve accuracy.

  4. Select 👁 under Actions to review the parsed diagram.

Review parsed diagrams

The parsed diagram has three tabs to verify different aspects of the automatic mappings: Symbol, Mapping, and Connection.

Rasterized files

When you parse rasterized files, such as images or scanned PDFs, only the mapping tab is available

  1. On the Symbol tab, verify the relevant symbols are correctly detected.

    • To add a symbol to the library, select the symbol and select which Asset class and Asset type the symbol represents. You can also add the symbol as a geometry to an existing symbol.

    • If a symbol maps to the wrong asset, select the symbol and then Detach from symbol. Only this particular instance of the symbol in that specific file is detached.

    Symbol tab
  2. On the Mapping tab, map the detected tags and symbols to the correct instances in CDF. The mapping process has two steps:

    • Tag detection and mapping: Identifies tags and maps them to instances of CogniteAsset or CogniteFile. The CogniteDiagramAnnotation defines this mapping.

    • Symbol to asset mapping: Maps detected symbols to CogniteAsset instances by comparing the locations of symbols and tags. If a symbol and a tag overlap, the symbol is mapped to the asset instance that serves as the end node of the annotation.

  3. On the Connection tab, verify the symbols are correctly connected.

    • Hover over a symbol to view the entire connection group and select a symbol to view or edit the closest connection.

    • To delete incorrect connections, select Remove connection icon.

    • Select two symbols to create missing connections and then select Create connection.

  4. Rerun the parsing and verify that your changes have been recognized.

note
  • In Edit layer visibility icon, toggle Show background document to show and hide the diagram's background document details (SVG paths).

Colors in diagrams

The diagrams have different indicators to show the mapping status of detected tags and symbols:

  • Blue box indicates an approved CogniteDiagramAnnotation.

  • Purple box indicates a suggested CogniteDiagramAnnotation.

  • Purple symbol indicates the detected symbol is either linked to a suggested CogniteDiagramAnnotation or not linked to any CogniteDiagramAnnotation.

  • Blue symbol indicates the detected symbol is linked to an approved CogniteDiagramAnnotation.

Note

All symbols mapped to an instance in CDF should be blue. If a symbol is purple, you need to review it.

Mapping scenarios

  • For a valid CogniteDiagramAnnotation/symbol, select Verify to verify the mappings and change the annotation status to Approved.

  • If a CogniteDiagramAnnotation/symbol is mapped to the wrong instance, select the CogniteDiagramAnnotation/symbol and Change mapping.

  • For an unmapped symbol, there are two options:

    • When the CogniteDiagramAnnotation links to a correct CDF instance, select the CogniteDiagramAnnotation and the symbol, and Link. This maps the symbol to the instance and changes the status of CogniteDiagramAnnotation to Approved. When the CogniteDiagramAnnotation links to an incorrect CDF instance, select the CogniteDiagramAnnotation and link it to the correct instance before linking it to the symbol.

    • Select the unmapped symbol and Add asset mapping +. Select the asset to map it to. This creates a CogniteDiagramAnnotation with the status Approved.

  • Select 🗑 to remove incorrect mappings of detected symbols. This unlinks and deletes the linked CogniteDiagramAnnotation.

  • To unlink a symbol and its linked CogniteDiagramAnnotation, select the symbol and Unlink.

  • To add an annotation manually, select the + (Add mapping). Create a bounding box and select an asset to link it to. This creates a CogniteDiagramAnnotation with the status Approved.

Manage parsed output

Use the API to retrieve your parsed output. For more information, see API documentation.