CA2071036A1 - Method for parsing images - Google Patents

Method for parsing images

Info

Publication number
CA2071036A1
CA2071036A1 CA002071036A CA2071036A CA2071036A1 CA 2071036 A1 CA2071036 A1 CA 2071036A1 CA 002071036 A CA002071036 A CA 002071036A CA 2071036 A CA2071036 A CA 2071036A CA 2071036 A1 CA2071036 A1 CA 2071036A1
Authority
CA
Canada
Prior art keywords
symbols
symbol
ordered
searching
grammar
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Abandoned
Application number
CA002071036A
Other languages
French (fr)
Inventor
Hosagrahar Visvesvaraya Jagadish
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
AT&T Corp
Original Assignee
Hosagrahar Visvesvaraya Jagadish
American Telephone And Telegraph Company
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hosagrahar Visvesvaraya Jagadish, American Telephone And Telegraph Company filed Critical Hosagrahar Visvesvaraya Jagadish
Publication of CA2071036A1 publication Critical patent/CA2071036A1/en
Abandoned legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/40Document-oriented image-based pattern recognition
    • G06V30/41Analysis of document content
    • G06V30/416Extracting the logical structure, e.g. chapters, sections or page numbers; Identifying elements of the document, e.g. authors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/253Grammatical analysis; Style critique

Abstract

A METHOD FOR PARSING IMAGES
Abstract Parsing of partially orderable sets of symbols is achieved by first forming a total order of the given terminal symbols. The relationships between the terminal symbols are formulated, and the given grammar is broken up into a set of production rules. Based on the production rules, a determination is made as to what kind of symbol is needed to comply with the given grammar. This determination encompasses both the type of terminal symbol that is to be found as well as the partial order relationships that such a symbol must have. The set of totally ordered symbols are searched, in order, and the first symbol that meets the specified criteria is selected. When appropriate, the symbols retrieved from the totally ordered set are reduced to non-terminal symbols, with the ultimate goal being the inclusion of all of the symbols in the totally ordered set within one reduced non-terminal symbol.

Description

2 ~

A METHOD FOR PARSING IMAGES
Backg~ound of the Invention Currently, one of the common means for interfacing with a small computer such as a PC comprises a screen, a keyboard, and a pointing s device (e.g., a mouse). The pointing device arrangement includes an icon that is prescnted on the scrcen, a moveable "mouse" connected to the computer, software for moving the icon in response to the movement of the "mouse" and software for rccognizing the position of the icon.
The icon mouse arrangcment is very effective for obtaining 0 information from the user when the amount of information that is needed is small, such as when computer commands are, effectively, selected. At such a command selection session, the computer presents various options to the user and the user selects from among the presented options.
The schema for presenting the options and for identifying the 1S selection made by the user, via the icon mouse interface, involves creating an image on the screen where specified areas on the screen correspond to specific selections, identifying the position of the icon on the screen, and establishing a correspondence between the icon position, the established screen areas, and the effective command selection.
Typically there is no logical relationship between one area of a screen and another area of the screen. That is, no action that is associated with one area is taken simply because the icon is in some proximal relationship to that area. The question is not asked whether the icon is to the right, left, above, or below area, but only whether the icon is in the 2s area. That is not to say that logical relationships cannot exist between areas, and in some applications they do. However, the programs that recognize and implement the controls associated with such logical relationships are "tailor made" for the specific applications.
Aside from the "control" aspect of the interaction between the 30 computer and the user, there are other situations where different areas of a display screen share a logical relationship. For example, when an image of a business letter (of a known format) is formed on the screen, it is known where the date of the letter can be found, where the addressee can be found in relation to the date, where the salutation can be found in relation to the 3s addressee, etc. The same applies to many database output "screens", which often are presented in tabular form.

- 2 ~ 3 ~

The ques~ion is: how to program ~he computer to recogni~e and analy7e these logical relationships, and how to approach thc programming task in a logically robust way. A careful stutly of this question reveals that it basically is a grammar problem. That is, the problem involves the s question of what is the best way to parse the image and what is the best way to make sense of the parsed information.
Parsing of information and deriving contextual information as a result of the parsing has bcen studied extensively in connection with formal languages. Such languages comprise a collection of symbols and a set of 10 rule-derlned manipulations of the symbols (grammar). The set of symbols includes both terminal symbols, which are the elemental units in the language (such as words) and non-terminal symbols which are constructed from terminal symbols (such as phrases). The symbol manipulation rules are sometimes termed the production rules, and those define valid mappings 15 of symbols. For example, the production rule A ~ bcN (I) states that when the sequence of symbols bcN is found in the input, that sequence may be replaced with the symbol A. (In this disclosure, lower case letters designate terminal symbols and upper letters designate non-terminal 20 symbols.) Obviously, the notion of "next" and "previous" is very important to the production rules, and that imposes a strict concept of sequencing on the symbols in any candidate "sentence" of the language. The ordering of symbols is clearly definable in one dimensional strings (which natural languages are). In higher order strings, however, the concept of a sequential 2s order is not well defined. That is the reason why parsing of multi-dimensional strings has not progressed very far.
Summary of the Invention Parsing of partially ordered sets of symbols is achieved by first forming a total order of the given terminal symbols. The relationships 30 betweén the terminal symbols are formulated, and the given grammar is broken up into a set of production rules. Based on the production rules a determination is made as to what kind of symbol is needed to comply with the given grammar, which determination encompasses both the type of terminal symbol that is to be found as well as the partial order relationships 3s that such a symbol must have. The set of totally ordered symbols are 2~71~

searched, in order, and the first symbol that mects the specified crileria is selected. When appropriate, the symbols retrieYed from the totally ordered set are reduced to non-terminal symbols, with the ultimate goal being the inclusion of all of the symbols in the totally ordered set within one reduced s non-terminal symbol.
Brief Description of the Drawin~
FIG. 1 illustrates the contents of a stack in a finite state machine as it parses a given sentence;
FIG. 2 presents a pictorial view of a title page in an ACM
10 journal;
FIG. 3 is a block diagram of a parser in accordance with the principles of this invention; and FIG. 4 is a flowchart describing the parsing process of this invention .
5 Detaiied Description Ordering and Guiding It may be surmised from the above that before the parsing of multi-dimensional strings can take place, a reasonable ordering schema must be developed for such strings, and a parsing process must be created that 20 couples well to such an ordering schema.
Disclosed herein is an efficient parsing process which operates effectively in any environment where the set of symbols can be partial~
ordered in the multi-dimensional space (having a dimensions or senses). A
partially ordered set is a set of elements where a relation may exist between 2s any two elements, but when it exists, it possesses the transitive property (if a< b and b< c then a< c). In a totally ordered set there is some relationship between the elements and the transitive property holds.
Given a set of symbols that are partially ordered, what is necessary for the practice of this invention is a total ordering of the 30 symbols. Any ordering schema will do, but the following presents a reasonable ordering methodology that works for a wide variety of the symbols sources interest.
A partially ordered set of symbols is totally ordered, according to this methodology, only if in the given set of symbols, every symbol, u, is less 3s than or greater than the symbol v (where "less than" may mean "precedes") in at least one dimension or sense. The relation "v is less than, or precedes, 2 ~ 7 ~

v in the I dimension sense" is written as v < u. When it is not known whether v is less than u or vise-versa in the I dimension sense, the expression v - u is used. Describing the total ordering methodology in the more concisc mathemalical terms, for any pair of symbols, u and v, s if u < u then u < v if v < v ~hen v < u if u - v then:
if u < v then u < v if v ~ u then v < u if u - v then: (2) if u < v then u < v if v < u then v < u if u - v error. Possible only if u = v The above ordering establishes a methodology for unambiguous total ordering of the input symbols.
In addition to the partial ordering of the input, the parsing 20 process of this invention employs the concept of "guiding". A symbol "u" is said to be "i-guiding" the symbol "v" if and only if the following conditions are met:
i. u < v, ii. u- v 2s iii. there exists no w such that u < w < v.
That is, "u 1-guides v" if u is less than v in dimension 1 sense, there is no w between u and v in that dimension, and u and v are incomparable in all dimensions j other than i.
A parsing process that employs the above-defined ordering and 30 guiding principles is formulated below. The description of this parsing process is aided with a simple example of a contrived two-dimensional "first cousin" of the English language, but f~rst a grammar for that language must be de~lned.

s 2~7~3~

Grammar of the Two-Dimensional English Lan~uage To make sense of ordered words -- i.e., to parse the input -- rules of grammar must be presented. E~or purposes of this disclosure, the contrived two-dimensional language follows the following grammar where s the symbols of the language are italicized:
Rule Meaning 1. FIN ~ X symbol X maps to symbol FIN which designates a successful finish of the parsing process;
2. X ~ S < P a subject clause S to the left of a predicate lo clause, P, maps to X;
3.
S ~ art < S
article to the left of S maps to S;
4.
S S ~ S < adj S above an adjective maps to S;
5.
P ~ verb < O
verb above an object clause, O, maps to P;
6. 0 -~ noun a noun maps to 0; and 7. S -~ noun a noun maps to S.
Finite State Machine States As will be described more fully below, the parsing process of this invention may be carried out with a finite state machine (FSM~, which is 2s characterized by discrete states. The FSM enters a given state when a specified input is given, performs certain operations that are prede~med for that state and stays there until another input is given. The states of the FSM parser of this invention can be developed from the above grammar.
Specifically, from rule 1 of the grammar we get state O
FIIV ~ * X
The * to the left of X means that X is sought to be "observed". From rule 2 of the grammar, seeking to observe X is also seeking to observe S, as in the transformation, or item X~ *S P, 3s and from rules 3, 4 and 7, seeking to observe S is also seeking to observe art, 2~71~

S, or noun, to wit:
S~ *art S
S~ *S adj S~ *art noun .
s Thus, state O corresponds to:
FIN~ *X
X~ ~S P
S~ *art S
S~ *S adj o S ~ * noun When X is observed, the FSM moves from state O to state 1;
when S is observed, the FSM moves to state 2; when art is observed, the FSM moves to state 3; and when noun is observed, the FSM moves to state 4. Expanding each of the states, the entire set of states and items in those 15 states is developed, as shown in the following listing.

-7- ~7~ ~3~

state 0: FlN~ *X (seek first) X~ *S P
S~ *art S
S~ *S adj S S-~ *noun state 1: FIN -~ X * R
state 2: X~ S *P (S,1) S~ S *adj (S,2) P~ * verb O
lo state 3: S~ art *S (art,1) S~ *art S
S--~ *S adj S-~ *noun state 4: S-~ noun * R
15 state 5: X~ S P * R
state 6: S~ S adj * R
st at e 7: P ~ verb * O (verb,2) 0-~ * noun state 8: P~ verb O * R
20 state 9: O~ noun * R
state 10: S~ art S * R
S~ S * adj (s,2) In the above listing, the R designation next to some items indicates that those are reducible. Those are "reduce items". A "kernel 2s item" is an item that is not reducible and there is at least one symbol to the left of the * on its right hand side. The guidance relationship of the kernel items is important, so it is included in the parenthetical expression to the right of the kernel item. The item FIN ~ * X is a pseudo kernel item. It specifies a seek of the first item in the ordered list of elements.
FSM states that include a kernel item are states that require new information. In response to that information, in some instances the FSM
enters a state where a reduction takes place, and in other instances the FSM enters a state where more information is needed (sometimes termed a `'shift'`). The reduction items and the kernel item, i.e., the items in the 3s above list that have a parenthetical comment to the right, are the "decision items" .
-8- 2~7~ ~3$

An FSM state may exist whcre a shift/reduction conflic~ is present. State 10 above has such a conflict, where it is not specified which action to perform~ Normally, the conflict between reduce and shift is resolved in favor of the shift~ The rationale for this is based on the s objective, which is to find the largest grouping of symbols that can be reduced~ It may be noted that state 2 has two kernel items, representing a seek, or shift conflict~ According to the ~lrst item, the FSM must seek something that is 1-guided by S, while according to the sccond item the FSM must seek something that is 2-guided by S~ This seek conflict really 10 means that the grammar is not well defined. However, that may be resolved by either creating an additional rule or by the user simply selecting a preference. In the case at hand, the second item transforms an observed S
into another S It makes sense in this case, therefore, to promulgate the rule that such transformations take precedence over the transformation of 5 the first item~ Thus, the order of operations in state 2 shall be to seek symbols in the ordered input list in accordance with the second item, and if none are found to seek symbols in the ordered input list in accordance with the first item.
The rules set for the conflicts of state 2 can be addressed also in 20 the more conventional manner of adding additional non-terminal symbols and additional statements to the grammar that would eliminate the conflicts and impose the particular desired seek/reduce parsing order.
Table 1 presents the state transition matrix for the states identified above. It may be noted that some states of the finite state 2s machine do not appear as lines in the transition matrix of Table 1. These are states that correspond to a single reduction item.

Table 1 _ :

Sample Sen~ence to be Parsed Given a sentence which states:
The dog ate (3) S good bread the first step is to order the input symbols (words). Taking the five words of the sentence in pairwise combinations and applying the ordering schema described above, the following results:
The < dog The < good The < good The < bread dog < ate dog < bread (4) dog < good dog < bread good < ate good < bread ate < good ate < bread It may be noted that some combinations were not taken, because either there is no information about the relation, or because the relation can be developed from the transitive property of the "< " operator.

~7 ~ ~3~
~o In the above listing of pairwise combinations, the term "The" is clearly the lead symbol. It precedes cvery other symbol in both dimensions.
Initiating the ordering proccdure, the syrnbols that are related to symbol "The" in dimension 1 sense are "good" and "dog". It is known that they 5 succeed the symbol " The" but their order relation to each o~her is not known. When "good" and "dog" are ordered, it is noted that they are incomparable in dimension 1 sense. However, in dimension 2 sense "dog" is above "good" and, thercfore, in accordance with the partial ordering rules above, they line up behind the symbol "The" as follows:
The < dog < good .
The two remaining words, "ate" and "bread", succecd "dog" and "good" in dimension 1 sense but, between them, a dimension 2 sense ordering must again be established. Applying the procedure designated by (2), the final order obtained for the entire sentence of (3) is The < dog < good < ate < bread . (S) The string (4) may not have the structure of a valid sentence in the English language, but that is completely unimportant. What is important is that a clear unambiguous order has been established. The input words are accessed in that order in the course of this invention's parsing process, as 20 described more fully below.
With respect to the "guiding" relations, applying the relations list (4) to the sentence designated by (3), results in the following "The" l-guides "dog"
"dog" l-guides "ate"
"good" l-guides "bread" (6) "dog" 2-guides "good"
"ate" 2-guides "bread"
This is the "guiding list", which is augmented in the course of the parsing process as described below. The relation list (4) is also augmented in the 30 course of the parsing process, and is described below.
Augmenting the Relations List and the Guiding List The grammar must specify a rule according to which partial order relationships can be determined between non-terminal symbols that are newly created in the parsing process and other symbols that already 35 exist. The rule is that a relationship exists between a non-terminal and another symbol if and only if ~he relationship exists between each of the conslituents of the said non-terminal and the said other symbo~. When a reduction is applied to create a new non-tcrminal symbol, this rule is used to augment the relations list. Thereafter, all occurrences in the relations list5 of symbols constituent in the new non-terminal are deleted.
The changes made to the rclations list must also be reflected in the guiding list. Any guiding relationship with respect to constituent symbols of the new non-terminal are no longer required, and should be deleted. New guiding relationships with respect to the new non-terminal 10 symbol, if any, are determined in the usual way, and these are added to the guiding list.
The parsing process The parsing procedure starts with state 0 in the stack, as depicted in step a of FIG. 1. There are no conditions imposed on what is to 15 be re~rieved from ordered list (5) and, therefore, the first symbol ("The", which is an art) is retrieved. Since, according to table 1, ar~ is an acceptableinput, the tuple "The:art:3" is stored in the stack and the FSM moves to state 3, as specified by table 1 and shown in step b of FIG. 1. Having observed and accepted the symbol "The", it is deleted from ordered list (5).
In state 3, there is one kernel item. It directs a seek of something that is l-guided by art. The art that is in the stack is "The".
Going over to the guiding list above, the first entry that "The" l-guides is "dog" (first item in the list), which is a noun. According to table 1, noun is an acceptable input at state 3, directing the FSM to state 4. Hence, the 25 tuple "dog:noun:4" is pushed onto the stack, as shown in step c of FIG. 1, and the symbol "dog" is deleted from the ordered list.
State 4 reduces a noun to S. Accordingly, the tuple "dog:noun:4" is popped from the stack and the noun is replaced with S.
Concurrently, the relations list is augmented with the entries The < S fdog~
Sldogl < ate S [dog J < bread S[dog] < good S[dog3 < bread 2 ~ 3 ~

and ~he "guiding lis~" is augmented with the entries S[dog] l-guides "ate"
S[dog] 2-guides " good" .
Replacement of the noun with S, in effect, provides an input S to the FSM
5 while it is in state 3. According to table 1, when in state 3 and S is observed, the FSM moves to state 10. Hence, the popped tuple is changed to "dog:S:10" and pushed onto the stack as shown in step d of FIG. 1.
In state 10, the FSM proceeds to seek something that is 2-guided by S. There is only one such entry in the guiding list (S[dog] 2-guides 10 "good") and "good", being an ad;" meets lhe requirement of the seek item S-~ *adj. Hcnce, "good" is taken from the ordered list, the tuple "good:adj:6" is created (with reference to table 1) and pushed onto the stack as shown in step e of FIG. 1. As with the other accepted symbols, "good"is deleted from the ordered list.
State 6 is a reduce state. The two tuples in the stack are popped, and the reduction is performed, yielding S. Again the FSM is cognizant of state 3 and the input symbol is S. According to table 1, the next state is 10 and, therefore, the new tuple "good,dog:S:lO"is created and pushed into the stack, as shown in step f of FIG. 1. The relations list is 20 again augmented, with the entries The < S[dog,good]
S[dog,good] < ate S[dog,good] < bread and the guiding list is augmented with the entries S[dog,good] l-guides "ate"
S~dog,good~ l-guides "bread"
Being back in state 10, once again an attempt is made to shift in an adj that is 2-guided by S. This attempt fails, however; therefore, the next decision items is applied, which is the reduce item S~ artS *. That 30 yields S once again, which is pushed back onto the stack after popping the top two tuples. The FSM is cognizant of state 0 and it observes an S so, according to table t the FSM advances to state 2, as shown in step of FIG.
1. Once again the relations list is augmented, this time with entries S[The,dog,good] < ate S[The,dog,good] < bread 2 ~

and the guiding list is augmented with the entries S[The,dog,good] l-guides "ate"
S lThe, dog, good ] 1 -gu id es " bread "
In state 2 there are two different seeks that are possible. As 5 discussed earlier, it is preferred to scek something that is 2-guided by S.
Not finding anything, a seek is made for something that is l-guided by S
(per item S~ S*P). The first symbol in the remaining list "ate< bread"
that is l-guided by S (or, more specifically, SlThe,dog,goodll) "ate"). That is a verb, and according to table 1, a verb is an acceptable symbol which drives 10 the FSM to state 7. The tuple "ate:verb:7" is created and pushed onto the stack as shown in step h of FIG. 1.
State 7 includes a kernel item which directs a seek of something that is 2-guided by verb. According to the "guiding list", the symbol "ate", which is a verb, 2-guides the symbol "bread", the symbol "bread" is found in 15 the ordered list (indeed, it is the last and only symbol left in the ordered list). Also, the symbol "bread" is a noun, which table 1 states that it is an acceptable symbol. Consequently, the tuple "bread:noun:9" is created and pushed onto the stack as shown in step i of FIG. 1.
State 9 is a reduce state. The top tuple is popped, the noun is 20 reduced to O, the tuple "bread:0:8" is created pursuant to table 1, and pushed onto the stack as shown in step j of FIG. 1.
State 8 is also a reduce state. The two top tuples are popped, the reduction P~ verb 0* is performed, the new tuple "bread,ate:P:5" is created with the aid of table 1 and is pushed onto the stack, as shown in 25 step k of FIG. 1.
State 5 is also a reduce state. Again, the two top tuples are popped, the reduction X~ S P* is performed, the new tuple "bread,ate,good,dog,The:X:l" is created with the aid of table 1 and is pushed onto the stack, as shown in step I FIG. 1.
The relations list and the guiding list are, of course, updated after each of the above reductions. Since nothing that is different or interesting happens in these updates, they are not shown for sake of brevity.
Finally, in state 1, the transformation FIN~ X~ is performed, 35 bringing the parse to a successful end. One of the conclusions of the parse is that the sentence of (3) is a valid sentence according to the given 2 ~ 7.~

grammar.
Parsin~ an image The above example of a contrivcd two-dimensional language was presented as a vehicle for introducing the concepts associated with the 5 parsing process of this invention. The following presents a practical use for the parsing process and apparatus of this invention. In particular, FIG. 2 presents a pictorial representation of the title page of the Journal of the Association of Computing Machinery. It includes blocks of text, and each block of text has a meaning that's contained in the words within the block 10 and an additional meaning that's embedded in the position of the block of text in relation to the position of other blocks of text. It would be beneficialif electronic scanning and signal processing of FIG. 2 could uncover both the text that's embedded in the scanned image and its meaning. For example, the string of letters making up the word "Hover" is found in the FIG. 2 15 image. Aside from ascertaining that this word is in the image, it may be determined that this word is the name of an author rather then, perhaps, a word in the title of an article pertaining to hovering vehicles. Being able to assign a category to scanned image elements goes a long way toward a more effective interaction with computer-based systems.
~ perusal of FIG. 2 reveals that it contains structural blocks (comprising text), or elements such as a Heading, a Body, a Category, a Group Heading, an Article, a Page Number, a Writer, and a Title. It may be noted that all of the above elements have initial caps, to designate (as before) that these are non-terminal elements. The terminal elements, which 25 are the basic scanned elements are line blocks, such as the upper case and lower case collection of letters making up the title; caps blocks, such as the collection of all capital letters making up a Group Heading; and number blocks, such as the page numbers. It may also be noted that some of the non-terminal elements can be subdivided into other non-terminal elements, 30 but for sake of brevity that was not done in the FIG. 2 image. The Heading block, which can be divided into three basic sub-blocks, is a notable example of that and, henceforth, the element Heading is assumed to be a terminal element (heading).
A study of the structure present in the FIG. 2 image reveals that 35 the following grammar is embedded in that structure.
S ~ heading Body (heading < Body) ?., ~ 7 ~ ~3~

Body ~ Category Body (Category < Body) Body ~ Category Category ~ GroupHead Article (GroupHead < Article) Category ~ Category Article (Category < Article) S Article ~ PageNum Title Writer (PageNum < Title, PageNum < Writer, PageNum < Writer, PageNum < Writer) PageNum ~ numberblock Title ~ lineblock Writer ~ lineblock GroupHead ~ capsblock Deriving states for a finite state machine that is based on the above grammar results in the following.
state 0: FIN~ *S (seek first) S~ *hB
state 1: FIN~ S * R
state 2: S~ h *B (h,2) B~ *C
B~ *CB
C~ *CA
C~ *GA
G~ *c state 3: S~ hB * R
state 4: B~ C * R
B~ C *B (C,2) C~ C *A (C,2) B~ *C
B~ *CB
C~ *CA
C~ *GA
G~ *c A ~ * PTW
P~ *n state 5: C~ G *A (G,1) A ~ ~ PTW

P~ *n state 6: G--~ c * R
s~ate 7: B~ CB * R
state 8: C~ CA * R
state9: C--~GA * R
state 10: A~ P *TW (P,l) T~ *l state 11: P~ n * R
state 12: A--> PT *W (T,2) W~ *l state 13: T~ I * R
state 14: A~ PTW * R
state 15 W~ I * R
It may be noted that state 4 above is the most complex state. It includes a 15 reducible item (B~ c*) and two kernel items (B~ C*b and c~ C*A).
The shift-reduce conflict is resolved in favor of the shift. The two different kernel items do not represent a seek conflict because both look for something that is 2-guided by C. The state transition matrix is shown in Table 2 below. States in which no input is accepted (i.e., states with no 20 kernel items) are not shown in the matrix because the rows corresponding to those states would be all blank.
Table 2 ~5 4 6 ~ l ~ 8 r 4 5 ~ -1O r 13 __ _ _ __ 12 _ 1 12 __ 15 = --_ ~ --= 14 - 17 - 2 ~ 7 ~

The Parsing Apparatus and Process Flow FIG. 3 depicts a block diagram of the parsing apparatus embodying the principles of this invention The scanned input symbols are inserted into block 170 wherein a relations list is formed based on the 5 partial order relationships of the input elements. From the block 170 information processor 100 develops a to~al ordering of the input elements in accordance with the process dcfned in (2) and the ordered elements are stored in block 110. Control block 120 has access to the ordered symbols and to the rela~ions list and based on the available information and the a 10 priori known grammar, block 120 creates a guiding list which is stored in block 130. Control 120 also interacts with stack 140 and state transition matrix store 150. In operation, as described hereinafter in greater detail, control 120, in consultation with stack 140, state transition matrix in block 150, relations list in block 170 and the guiding list in block 130 determines 15 whether information that is contained in the stack should be reduced or, alternatively, whether a particular type of element should be searched for in the ordered collection of elements found in block 110. When such an element is found, it is basically transferred from block 110 to stack 140.
Whether a reduction is performed or a new element is searched for and selected, the result is that a new tuple of information is pushed into stack 140. The process repeats until, in the absence of errors (which happens when the grammar cannot be satisfied), the process terminates when the entire set of elements stored in block 110 is transferred out of block 110 and onto stack 140.
FIG. 4 presents a flow chart of the parsing process. It begins with block 190 where, based on the grammar, the states of the FSM are determined. Also in that block, the relationships list and the guiding list are formulated in their initial state. Thereafter, in block 180, the total order is established for the given set of input symbols in accordance with 30 the described methodology.
The actual parsing starts at block 200 where the finite state machine (control block 120 in combination with blocks 140, 150, 160 and 170) is at state 0. The directive to place the finite state machine in state 0 is effected by the initial placing of the tuple " ::0" in stack 140. It is the 0 in 35 the third field of the tuple (the " ::0" being the tuple that was most recently pushed onto the stack and, hence, at the top of the stack) that dictates the 3 ~

state of the FSM.
The production items block (160) is peruscd for all decision items in state 0 and, the "seek first" decision iterm is found. It, in effect, specifies a seek of the first entry in the ordered input of block 110 -- which is the 5 leader element. In block 201 an index variable i is set to 1 and the parse proceeds to block 202. In block 202 a sclection is made of the first decision itcm (i= 1) in the current state, from among the other dccision items in block 160 for that state. This may be a kcrnel item or an item that represents a reduction. Some states of the finite state machine may have a 10 number of such items. If a state has M decision items and the value of i reaches M+ 1, block 202 declares an error. Othcrwise, the parse continues to block 203 where the nature of the decision item is determined. If it is determined that the decision item calls for a reduction, the parse proceeds to block 204. A tuple is popped out of stack 140 and the parse advances to 15 block 205 where the popped tuple is compared to what is expected by the selected decision item. If the popped tuple is valid, decision block 206 determines whether additional tuples need to be popped from the stack;
and if that is the case, control returns eO block 204. If a popped tuple is determined to be invalid in block 205, all of the popped tuples are pushed 20 back onto stack 140 in block 207, the value of i is incremented by 1 in block 208, and control returns to block 202.
When block 206 determines that all of the necessary tuples have been popped, the parse proceeds to block 209 where the reduction is performed in accordance with the selected decision item. Block 209 also 25 creates a new tuple in accordance with information derived from state transition matrix block 150. In block 210 the relations list of block 170 is augmented as well as the guiding list of block 130, and control passes to block 211. Block 211 stores the tuple created in block 209 and thereby advances the finite state machine to the next state. Following block 211, 30 block 216 determines whether the finite state machine has reached state 1.
If so, the process terminates. Otherwise, control returns to block 201.
When it is determined in block 203 that the decision item selected in block 202 is a seek item, guiding list 130 is consulted in block 212 and, based on information derived from the guiding list, the input 35 elements in block 110 are searched in order. The f1rst element that matches the requirements of the search, as determined by block 213, is deleted from 2 ~

block 110 by block 214. A tuple is created for the ncwly accepted element in block 215 in cooperation with information dcrivcd from state transition matrix block 150 and control thcn passes to block 211.

Claims (8)

1. A method for parsing a set of symbols in accordance with a grammar, including the step of obtaining a symbol (212) from the set of symbols and the step of combining (209, 215) the obtained symbol with previously obtained symbols when such combining is called for by said grammar, wherein the improvement comprises the steps of:
creating a process table, based on said grammar (190);
ordering the set of symbols (180) when said set of symbols is not ordered, to form an ordered set of symbols;
based on said grammar, determining characteristics of an acceptable symbol (190); and searching said ordered set of symbols (212, 213) for the first acceptable symbol as part of said step of obtaining.
2. The method of claim 1 wherein said step of determining characteristics comprises the steps of:
developing relationships of the symbols in the ordered set with other symbols (190, 210).
determining, from said process table, the relationships that said acceptable symbol shall have with other symbols (212); and
3. The method of claim 2 wherein said step of searching, in co-action with said step of obtaining, searches the ordered set, in order, for a symbol characterized by developed relationships that match the determined relationships of the acceptable symbol.
4. The method of claim 1 wherein said step of combining comprises the steps of:
ascertaining, based on said grammar and following the steps of searching and obtaining, whether a symbol found by said step of searching is to be combined with previously stored symbols (203);
combining the symbol found by said step of searching with previously stored symbols when called for by said step of ascertaining, to form a new symbol, and storing the new symbol (204, 205, 206, 209, 211);
and storing the symbol found by said step of searching when said step for combining is not called for by said step of ascertaining (211).
5. The method of claim 4 wherein said steps determining characteristics of an acceptable symbol, searching said ordered set of symbols, obtaining, ascertaining whether a symbol searched and is to be combined, combining the found acceptable symbol to form a new symbol and storing the new symbol when called for, and storing the found acceptable symbol without combining when called for, are iteratively carried out until all symbols in the total order have been stored.
6. A method for parsing a set of partially ordered symbols in accordance with the specification of a grammar, comprising the steps of:
based on said grammar, developing a set of process states (190);
based on the partial order of said set, developing relationships (190) of each symbol in said ordered set with other symbols in said ordered set and with symbols in a stack;
ordering said set of partially ordered symbols when said set of symbols is not ordered (180), to form an ordered set of symbols;
based on a current process state, determining characteristics of an acceptable symbol (212);
searching said ordered set of symbols for the first acceptable symbol (212);
storing in said stack the symbol found by said step of searching (211);
evaluating a new current process state (211), based on symbols stored in said stack, and returning to said step of determining characteristics of an acceptable symbol (216).
7. The method of claim 6 wherein said step of storing comprises a step of combining the symbol found by said step of searching with other symbols stored in said stack and augmenting said relationships (209, 210), when such combining is called for by said grammar.
8. A method for parsing a set of partially ordered symbols in accordance with the specification of a grammar comprising the steps of:
based on the partial order of said set, developing relationships (190) of each symbol in said ordered set with other symbols in said ordered set and with symbols in a stack;
based on said grammar, developing a set of process states and for each process state developing one or more items, each item defining characteristics of an acceptable symbol (190);
ordering said set of partially ordered symbols when said set of symbols is not ordered (180), to form an ordered set of symbols;
based on a current process state, selecting an item belonging to said process state (202);
determining whether the selected item designates a "seek" or a "reduce" (203);
when it is determined that the selected item designates a "seek", a) searching said ordered set in consultation with said relationships for an acceptable symbol (213);
b) returning to said step of selecting an item to select another item belonging said process state (217) when said step of searching fails;
removing from said ordered set the acceptable symbol found by said step of searching (214); and forming a tuple that correlates the symbol found by said step of searching with a new process state (215);
when it is determined that the selected item designates a "reduce", determining whether a reduction is possible based on information stored in a stack (204, 205, and 206);
returning to said step of selecting an item to select another item belonging said process state (217) when said step of determining whether a reduction is possible concludes that a reduction is not possible;
combining the selected symbol with symbols stored in said stack;
forming a tuple that correlates the combined symbol created by said step of combining with a new process state (215); and augmenting said set of relationships;
storing said tuple in a stack and assigning said new process state to said current state (211); and returning to said step of selecting an item.
CA002071036A 1991-06-25 1992-06-11 Method for parsing images Abandoned CA2071036A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US720,318 1991-06-25
US07/720,318 US5365430A (en) 1991-06-25 1991-06-25 Method for parsing images

Publications (1)

Publication Number Publication Date
CA2071036A1 true CA2071036A1 (en) 1992-12-26

Family

ID=24893552

Family Applications (1)

Application Number Title Priority Date Filing Date
CA002071036A Abandoned CA2071036A1 (en) 1991-06-25 1992-06-11 Method for parsing images

Country Status (4)

Country Link
US (1) US5365430A (en)
EP (1) EP0520684A3 (en)
JP (1) JPH0765003A (en)
CA (1) CA2071036A1 (en)

Families Citing this family (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5499329A (en) * 1992-04-30 1996-03-12 Ricoh Company, Ltd. Method and system to handle context of interpretation in a document processing language
JPH07121733A (en) * 1993-10-20 1995-05-12 Fuji Xerox Co Ltd Document image processor
US8478732B1 (en) 2000-05-02 2013-07-02 International Business Machines Corporation Database aliasing in information access system
US6704728B1 (en) * 2000-05-02 2004-03-09 Iphase.Com, Inc. Accessing information from a collection of data
US8640017B1 (en) * 2000-05-02 2014-01-28 International Business Machines Corporation Bootstrapping in information access systems
US6711561B1 (en) 2000-05-02 2004-03-23 Iphrase.Com, Inc. Prose feedback in information access system
US6408277B1 (en) 2000-06-21 2002-06-18 Banter Limited System and method for automatic task prioritization
US8290768B1 (en) 2000-06-21 2012-10-16 International Business Machines Corporation System and method for determining a set of attributes based on content of communications
US9699129B1 (en) 2000-06-21 2017-07-04 International Business Machines Corporation System and method for increasing email productivity
US7644057B2 (en) 2001-01-03 2010-01-05 International Business Machines Corporation System and method for electronic communication management
US7343372B2 (en) 2002-02-22 2008-03-11 International Business Machines Corporation Direct navigation for information retrieval
US20050187913A1 (en) 2003-05-06 2005-08-25 Yoram Nelken Web-based customer service interface
US8495002B2 (en) 2003-05-06 2013-07-23 International Business Machines Corporation Software tool for training and testing a knowledge base
US10679230B2 (en) 2009-04-07 2020-06-09 The Boeing Company Associative memory-based project management system
US9501455B2 (en) 2011-06-30 2016-11-22 The Boeing Company Systems and methods for processing data
US8521769B2 (en) 2011-07-25 2013-08-27 The Boeing Company Locating ambiguities in data
US8527695B2 (en) 2011-07-29 2013-09-03 The Boeing Company System for updating an associative memory

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4688195A (en) * 1983-01-28 1987-08-18 Texas Instruments Incorporated Natural-language interface generating system
JPS6225324A (en) * 1985-07-26 1987-02-03 Hitachi Ltd Document understanding system
US4984178A (en) * 1989-02-21 1991-01-08 Texas Instruments Incorporated Chart parser for stochastic unification grammar

Also Published As

Publication number Publication date
US5365430A (en) 1994-11-15
EP0520684A2 (en) 1992-12-30
JPH0765003A (en) 1995-03-10
EP0520684A3 (en) 1993-10-20

Similar Documents

Publication Publication Date Title
CA2071036A1 (en) Method for parsing images
US5349368A (en) Machine translation method and apparatus
JP3666004B2 (en) Multilingual document search system
EP0439937B1 (en) A direct manipulation interface for boolean information retrieval
US5826220A (en) Translation word learning scheme for machine translation
EP0911744B1 (en) Method for processing digital textdata
EP0366142B1 (en) Method and apparatus of machine translation
US5495413A (en) Translation machine having a function of deriving two or more syntaxes from one original sentence and giving precedence to a selected one of the syntaxes
US4831529A (en) Machine translation system
JPH0877155A (en) Information processor and information processing method
US5761666A (en) Document retrieval system
JPH0630066B2 (en) Table type language translation method
JPH077408B2 (en) Method and system for changing emphasis characteristics
JPH05303590A (en) Automatic translating device
EP0196898A2 (en) Machine translation system
JP3612769B2 (en) Information search apparatus and information search method
EP0265280B1 (en) Machine translation system and method
Currie et al. KAPPA—Kernel Application Package
JP3483585B2 (en) Document search device and document search method
JP2947686B2 (en) Search result display method in translation support system
JPH01214963A (en) Device for consulting dictionary
JPH11328179A (en) Dictionary management method and dictionary management system
JP2004348768A (en) Document retrieval method
JP2002183134A (en) Translating device
JPH08297659A (en) Character string conversion processing system

Legal Events

Date Code Title Description
EEER Examination request
FZDE Discontinued