<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Visual Structure Analysis of Flow Charts in Patent Images</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Roland Morzinger</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Rene Schuster</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Andras Horti</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Georg Thallinger</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>JOANNEUM RESEARCH Forschungsgesellschaft mbH DIGITAL - Institute for Information and Communication Technologies Steyrergasse 17</institution>
          ,
          <addr-line>8010 Graz</addr-line>
          ,
          <country country="AT">Austria</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>This report presents the work carried out for the ow chart recognition task in the course of the CLEF-IP 2012 competition. The goal is to obtain structural information of ow charts based on the visual content of the images. To this end, for each ow chart a list of its nodes and their interconnections, i.e. its edges, is extracted and the type of the nodes and edges and attached text is recognized. The automatic recognition task is done in three stages: (1) ow chart image pre-processing using connected component analysis, morphological lters and line segmentation, (2) identi cation of nodes, junction points, end points and edges and (3) recognition of text, geometric node types and edge directions. Examples demonstrate good recognition results obtained for 100 tested ow chart images.</p>
      </abstract>
      <kwd-group>
        <kwd>patent</kwd>
        <kwd>ow charts</kwd>
        <kwd>images</kwd>
        <kwd>technical drawings</kwd>
        <kwd>structure analysis</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>
        In traditional engineering drawings and diagrams, algorithms, operations and
processes are frequently represented as ow charts. In patents, these drawings
generally are accessible only in image format. For automatic querying the huge
information content of the ow charts available in patents, it is important to
convert the information in the images into a high-level description [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ]. This
problem usually involves techniques in the eld of image binarization, segmentation,
shape extraction and recognition of text and geometric components [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ].
      </p>
      <p>
        This paper describes our approach for automatically analyzing the visual
structure of ow charts and our participation in the ow chart recognition task [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]
in the course of the CLEF-IP 2012 competition.
      </p>
      <p>
        At this, it is assumed that a owchart can be interpreted as a graph with a set
of nodes and edges [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. To semantically process the data therein, the extracted
information should contain:
1. the number of nodes,
2. the type of each node (e.g. rectangle, diamond, oval, etc),
3. the text annotations (if any) within each node for creating the link between
the image and the patent text,
4. the interconnections, i.e. edges, between the nodes and
5. the type of the edges (e.g. continuous, dotted, etc.).
      </p>
      <p>The rest of this paper is organized as follows: Section 2 describes the applied
image processing methods for producing the above mentioned metadata and
results are presented in Section 3.
2</p>
    </sec>
    <sec id="sec-2">
      <title>Visual Structure Analysis</title>
      <p>
        A summary of the ow chart recognition process is shown in Figure 2,
understandably a ow chart itself. First, textual descriptions in the input image are
extracted using optical character recognition, followed by pre-processing, line
segmentation and grouping. Next, junctions and end points are detected and
based on that, nodes and their interconnections (edges) are recognized. Finally,
the type of the nodes and the direction of the edges is computed and the visual
information content from the ow chart is provided in a textual graph
representation (for the format see [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]).
      </p>
      <p>
        The quality of Figure 2 was deliberately modi ed in a way to match the
look&amp;feel and (sometimes bad) image quality of many technical drawings found
in patents. When viewed in full detail, lines are frequently frayed, non-contiguous
and not strictly vertical or horizontal, which clearly presents challenges for
image processing. The following subsections explain the processing steps of our
approach necessary for recognizing the visual structure of ow charts.
(a)
(b)
(c)
Fig. 1. Example showing details of di erent processing steps. The black and white
input image (a) is pre-processed and based on the resulting cleaned and thinned image
(b) the nal visual structure (c) is recognized. It shows nodes (solid colored border),
edges (dashed line), junction points (red lled circle), end points (green lled circle)
and the nodes' IDs (numbers in red boxes). Best viewed in color
A commercial optical character recognition (OCR) software [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ] is used to extract
text from the ow chart images. String matching using a regular expression is
performed for identifying possible references, like "Fig. x ". The locations (image
coordinates) of the extracted text blocks are kept for subsequent association
with detected nodes and edges.
2.2
      </p>
      <sec id="sec-2-1">
        <title>From Binary Image to Line Segments</title>
        <p>First, in the binary input image all connected components with a small number of
pixels and aspect ratio typical to characters (as opposed to lines) are removed.
Second, the image that is now cleaned from text-like fragments is subjected
to a morphological close and binary image thinning operation, see Figure 1(b).
Third, edge points are identi ed and linked to segments. By respecting a speci ed
minimum line length and maximum deviation from the original data, the pixel
image can now represented as a list of linked line segments.
2.3</p>
        <p>Detection of Junctions, End Points, Nodes and Connecting
Edges
Junctions and end points can be easily found by scanning the linked line segments
from the previous step for areas where three or more segments meet (junction) or
where a segment has no further connection (end point). In many cases, end points
are actually the end of wiggly edges that connect the nodes of the owchart with
their labels.</p>
        <p>Next, the nodes of a ow chart are detected by iteratively nding for each
segment another linking segment that is close enough (allowing for nodes with
small gaps between segments) and that has the smallest angle between them. A
combination of linked segments that meets certain criteria, such as a maximum
number of segments per node and sum of angle values, constitutes a node.</p>
        <p>Subsequently, connecting edges are derived from the remaining segments that
that link nodes, junctions or end points. These edges may obviously consist of
multiple segments.
2.4</p>
      </sec>
      <sec id="sec-2-2">
        <title>Recognition of Node Type and Edge Direction</title>
        <p>
          The goal is to classify 10 types of nodes (oval, rectangle, double-rectangle,
parallelogram, diamond, circle, point, cylinder, no-box and unknown). Their exact
de nition is given in the task description document [
          <xref ref-type="bibr" rid="ref1">1</xref>
          ]. The node types "no-box"
and "point" are a direct result of the methods described in Section 2.3. For the
classi cation of the remaining node types, the input is a sequence of segments
with start and end point coordinates. Based on those segments, the following
features are calculated:
{ Number of edges
{ Ratio between maximum and median edge length
{ Ratio between minimum and median edge length
{ Ratio between maximum and minimum angle
{ Median of the angles
{ Sum of the angles
{ TopPositionRatio: normalized ratio between top most and second top most
point
{ Normalized ratio between right most and second right most point
{ Extent: ratio between the area of the bounding box and the convex hull
        </p>
        <p>By using 400 annotated examples, discriminating features and their statistics
have been empirically determined for each type. The statistics consist of average,
standard deviation, minimum and maximum values for each feature and node
type. Figure 3 plots 3 features over 3 node types. The characteristics of the data
show that it is possible to classify the node types. With help of these statistics a
score for each class is calculated and the maximum score results in the classi ed
node type. If the maximum score is below 50% the node type is declared as
"unknown". An unknown node type is an indication of a possibly inaccurate
preceding node detection result and as a consequence the node can be discarded
(c.f. runs with node type lter in Section 3).</p>
        <p>The edge direction is estimated by comparing the number of black pixels of
the edge segments. A window is centered at the end of the edges and the edge is
directed if one the windows has clearly more pixels than the other. The related
thresholds have been determined using annotations (c.f. Section 3).
3</p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>Results and Evaluation</title>
      <p>
        For the ow chart recognition task of the CLEF-IP 2012 competition [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ], 50
images containing owcharts and the corresponding annotations were provided.
The images were used for developing the recognition system and the annotations,
i.e. the number and type of the nodes and edges, were used to tune data-speci c
parameter values.
      </p>
      <p>For evaluating our approach and di erent con gurations thereof, we produced
a set of runs described in Table 1.</p>
      <p>
        All of the di erent con gurations of our ow chart recognition system were
applied on a test set of 100 images. Details on the evaluation and the applied most
common subgraph metric can be found in the task description document [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]. At
the time of writing this paper, quantitative evaluation results for the ow chart
recognition track in CLEF-IP 2012 were not available yet.
      </p>
      <p>Nevertheless, the examples shown in Figure 4 and 5 should give an impression
of the quality of the ow chart recognition system.</p>
      <p>
        (a)
(b)
(c)
(d)
This paper presented the experiments for our participation in the CLEF-IP 2012
ow chart recognition challenge [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]. Structural information of ow charts, such
as nodes, their interconnections and annotating labels were obtained based on
image processing technology using the visual image content only. Although the
nodes and interconnections of ow charts seem to be easily recognizable by
humans, automatic processing is quite a challenge. On the pixel level, the black
lines are frequently non-contiguous, frayed, of varying width and not strictly
vertical or horizontal. Flow chart images show di erent types of nodes (circles,
boxes, parallelograms, etc), edges (directed, undirected), typewritten and
sometimes handwritten labels. When text is not clearly separated from nodes or lines,
di culties increase. Generally, nding proper values for critical thresholds, such
as the minimum length of segments and parameters for morphological ltering,
is one of the most crucial parts. For that purpose, the provided annotations have
proved very useful. Examples demonstrate good recognition results obtained for
100 tested ow chart images.
      </p>
    </sec>
    <sec id="sec-4">
      <title>Acknowledgments</title>
      <p>This work was supported by the Austrian Research Promotion Agency (FFG)
FIT-IT project IMPEx 1 Image Mining for Patent EXploration (No. 825846).
1 http://www.joanneum.at/?id=3922</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          <article-title>1. CLEF-IP ow chart recognition task 2012</article-title>
          . Available online at http://www.ifs. tuwien.ac.at/~clef-ip/flowcharts.shtml, visited on Aug.
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <surname>Transym</surname>
            <given-names>OCR</given-names>
          </string-name>
          engine. Available online at http://www.transym.com/, visited on Aug.
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <given-names>M.</given-names>
            <surname>Lupu</surname>
          </string-name>
          , R. Morzinger, T. Schleser,
          <string-name>
            <given-names>R.</given-names>
            <surname>Schuster</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F.</given-names>
            <surname>Piroi</surname>
          </string-name>
          ,
          <article-title>and</article-title>
          <string-name>
            <given-names>A.</given-names>
            <surname>Hanbury</surname>
          </string-name>
          .
          <article-title>Patent images - a glass encased tool / opening the case</article-title>
          .
          <source>In Proc. of iKnow Conference</source>
          ,
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <given-names>B. G.</given-names>
            <surname>Vasudevan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Dhanapanichkul</surname>
          </string-name>
          , and
          <string-name>
            <given-names>R.</given-names>
            <surname>Balakrishnan</surname>
          </string-name>
          .
          <article-title>Flowchart knowledge extraction on image processing</article-title>
          .
          <source>In IJCNN</source>
          , pages
          <volume>4075</volume>
          {
          <fpage>4082</fpage>
          . IEEE,
          <year>2008</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <given-names>Y.</given-names>
            <surname>Yu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Samal</surname>
          </string-name>
          , and
          <string-name>
            <given-names>S. C.</given-names>
            <surname>Seth</surname>
          </string-name>
          .
          <article-title>A system for recognizing a large class of engineering drawings</article-title>
          .
          <source>IEEE Trans. Pattern Anal. Mach. Intell</source>
          ,
          <year>1997</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>