JP2020057362A - Information processing apparatus, information processing circuit, information processing system, and information processing method - Google Patents

Information processing apparatus, information processing circuit, information processing system, and information processing method Download PDF

Info

Publication number
JP2020057362A
JP2020057362A JP2019129643A JP2019129643A JP2020057362A JP 2020057362 A JP2020057362 A JP 2020057362A JP 2019129643 A JP2019129643 A JP 2019129643A JP 2019129643 A JP2019129643 A JP 2019129643A JP 2020057362 A JP2020057362 A JP 2020057362A
Authority
JP
Japan
Prior art keywords
information processing
state
data
time
buffer
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.)
Granted
Application number
JP2019129643A
Other languages
Japanese (ja)
Other versions
JP7383273B2 (en
Inventor
正樹 和賀
Masaki Waga
正樹 和賀
一郎 蓮尾
Ichiro Hasuo
一郎 蓮尾
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.)
Research Organization of Information and Systems
Original Assignee
Research Organization of Information and Systems
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 Research Organization of Information and Systems filed Critical Research Organization of Information and Systems
Priority to US16/583,876 priority Critical patent/US11537415B2/en
Publication of JP2020057362A publication Critical patent/JP2020057362A/en
Application granted granted Critical
Publication of JP7383273B2 publication Critical patent/JP7383273B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

To make it possible, in an information processing apparatus that performs filtering for pattern matching, to efficiently perform processing compared with a conventional example.SOLUTION: In an information processing system, a sensor device comprises a pre-information processing circuit that creates a finite state machine on the basis of a predetermined matching condition related to sequence data of an event to be input, and outputs sequence data that is processed to substantially remove data not matching the matching condition from the sequence data by using the created finite state machine.SELECTED DRAWING: Figure 1

Description

本発明は、パターンマッチングのためのフィルタリングを行う情報処理装置、上記情報処理装置を備えた情報処理システム、及び情報処理方法に関する。   The present invention relates to an information processing apparatus that performs filtering for pattern matching, an information processing system including the information processing apparatus, and an information processing method.

例えば、特許文献1において、時系列データのフィルタリングを行う時系列相関抽出装置であって、トランザクションの数が増えても、処理に多大の時間が掛かるのを防止することができる時系列相関抽出装置が開示されている。この従来例に係る時系列相関抽出装置は、複数の属性からなるレコードの集合からレコードの組み合わせを検索する場合、レコード内の所定属性が特定の値をとることをそれぞれ定義する複数のイベントと、その属性値の順序に基づいて定義された該複数のイベントの間の順序関係とを用いて検索パターンを指定する指定手段と、レコードの集合から指定された検索パターンに対応するレコードの組み合わせを検索する検索手段と、検索結果を出力する出力手段とを有する時系列フィルタ部を備えると共に、時系列相関エンジン部により時系列相関ルールを抽出する機能を有する。   For example, in Patent Document 1, a time-series correlation extraction device that performs filtering of time-series data, and can prevent processing from taking a lot of time even when the number of transactions increases. Is disclosed. The time-series correlation extraction device according to this conventional example, when searching for a combination of records from a set of records composed of a plurality of attributes, a plurality of events each defining that a predetermined attribute in the record takes a specific value, Specifying means for specifying a search pattern using an order relationship between the plurality of events defined based on the order of the attribute values, and searching for a combination of records corresponding to the specified search pattern from a set of records A time-series filter unit having a search unit that performs search and an output unit that outputs a search result, and a function of extracting a time-series correlation rule by a time-series correlation engine unit.

特開2004−110327号公報JP-A-2004-110327 国際公開第2004/038620号パンフレットWO 2004/038620 pamphlet 国際公開第2012/057170号パンフレットInternational Publication No. 2012/057170 pamphlet

Eugene Asarin, Oded Maler, Dejan Nickovic, and Dogan Ulus, 2017, Combining the Temporal and Epistemic Dimensions for MTL Monitoring. A. Abate and G. Geeraerts (Eds.), 2017, Proc. FORMATS. LNCS, Vol. 10419. Springer.Eugene Asarin, Oded Maler, Dejan Nickovic, and Dogan Ulus, 2017, Combining the Temporal and Epistemic Dimensions for MTL Monitoring.A. Abate and G. Geeraerts (Eds.), 2017, Proc. FORMATS. LNCS, Vol. 10419.Springer . M. Krichen and S. Tripakis, 2009, Conformance testing for real-time systems, FMSD 34, 3 (2009), 238-304.M. Krichen and S. Tripakis, 2009, Conformance testing for real-time systems, FMSD 34, 3 (2009), 238-304. Leena Salmela, Jorma Tarhio, and Jari Kytojoki, 2006, Multi-pattern string matching with q-grams, ACM Journal of Experimental Algorithmics 11 (2006).Leena Salmela, Jorma Tarhio, and Jari Kytojoki, 2006, Multi-pattern string matching with q-grams, ACM Journal of Experimental Algorithmics 11 (2006). D. Ulus, T. Ferrere, E. Asarin, and O. Maler, 2014, Timed Pattern Matching, In Proc. FORMATS, (LNCS), A. Legay and M. Bozga (Eds.), Vol. 8711, Springer, 222-236.D. Ulus, T. Ferrere, E. Asarin, and O. Maler, 2014, Timed Pattern Matching, In Proc. FORMATS, (LNCS), A. Legay and M. Bozga (Eds.), Vol. 8711, Springer, 222-236. Masaki Waga, Ichiro Hasuo, and Kohei Suenaga, 2017, Efficient Online Timed Pattern Matching by Automata-Based Skipping, 224-243.Masaki Waga, Ichiro Hasuo, and Kohei Suenaga, 2017, Efficient Online Timed Pattern Matching by Automata-Based Skipping, 224-243.

しかしながら、従来例に係る時系列相関抽出装置では、例えばマッチング条件を記述したオートマトンに基づいてムーアマシン等の有限状態機械を生成し、生成された有限状態機械を用いてフィルタリングすることは開示も示唆もなく、効率的に処理を行うことができないという問題点があった。   However, the time-series correlation extraction apparatus according to the conventional example generates a finite state machine such as a Moore machine based on an automaton describing a matching condition and performs filtering using the generated finite state machine. Therefore, there is a problem that the processing cannot be performed efficiently.

本発明の目的は以上の問題点を解決し、パターンマッチングのためのフィルタリングを行う情報処理装置、情報処理システム及び情報処理方法において、従来例に比較して、フィルタリングを用いて効率的にパターンマッチングを行うことができる情報処理装置、情報処理システム及び情報処理方法を提供することにある。   SUMMARY OF THE INVENTION An object of the present invention is to solve the above problems, and in an information processing apparatus, an information processing system, and an information processing method for performing filtering for pattern matching, pattern matching is more efficiently performed by using filtering than in the related art. An information processing apparatus, an information processing system, and an information processing method capable of performing the information processing are provided.

本発明の一実施形態に係る情報処理装置は、入力されるイベントのシーケンスデータに関する所定のマッチング条件に基づいて有限状態機械を生成し、生成された有限状態機械を用いて、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去するように加工されたシーケンスデータを出力する情報処理回路を備えたことを特徴とする。   The information processing apparatus according to one embodiment of the present invention generates a finite state machine based on a predetermined matching condition regarding sequence data of an input event, and uses the generated finite state machine to generate the finite state machine from the sequence data. An information processing circuit for outputting sequence data processed so as to substantially remove data that does not match the matching condition is provided.

従って、本発明に係る情報処理装置、情報処理システム及び情報処理方法によれば、従来例に比較して、フィルタリングを用いて効率的にパターンマッチングを行うことができる。特に、従来の(フィルタリングによる前処理を行わない)実時間制約付きパターンマッチング(例えば、非特許文献4)と比較してフィルタリングを用いることにより、効率的に処理することができ、性能を大幅に向上できる。また、フィルタリングを用いるパターンマッチングに関する従来例(例えば、非特許文献4)と比較して、実時間制約がない場合はパターンとしてより広汎なオートマトンを許すができ、実時間制約がある場合は実時間制約を扱えることができる。   Therefore, according to the information processing apparatus, the information processing system, and the information processing method according to the present invention, pattern matching can be performed more efficiently by using filtering than in the conventional example. In particular, by using filtering in comparison with conventional real-time constrained pattern matching (without performing preprocessing by filtering) (for example, Non-Patent Document 4), efficient processing can be performed, and performance can be significantly improved. Can be improved. Also, as compared with a conventional example of pattern matching using filtering (for example, Non-Patent Document 4), a broader automaton can be allowed as a pattern when there is no real-time constraint, and a real-time Can handle constraints.

実施形態に係る物理情報システム(CPS)の構成例を示すブロック図である。It is a block diagram showing the example of composition of the physical information system (CPS) concerning an embodiment. パターンマッチング処理とフィルタリング処理との関係を表した概念図である。It is a conceptual diagram showing the relationship between the pattern matching process and the filtering process. 実施形態で用いるパターンマッチングにおける前後の移動処理を示すタイミングチャートである。6 is a timing chart showing a moving process before and after in pattern matching used in the embodiment. 従来文献でのパターンマッチングにおける位置プロットの一例を示す平面図である。FIG. 10 is a plan view showing an example of a position plot in pattern matching in a conventional document. 図3Bの位置プロットでの区間の特定を示す平面図である。FIG. 3C is a plan view illustrating the specification of a section in the position plot of FIG. 3B. 実施形態におけるフィルタリングのパディング処理を示す概念図である。It is a key map showing padding processing of filtering in an embodiment. 実施形態におけるムーアマシンによるフィルタリング処理を示す概念図である。FIG. 4 is a conceptual diagram illustrating a filtering process by a Moore machine in the embodiment. 実施形態に係る非決定的有限オートマトン(NFA)であるパターンの一例を示す図である。It is a figure showing an example of a pattern which is a non-deterministic finite automaton (NFA) concerning an embodiment. 実施形態に係るムーアマシンフィルタの非バッファ部分の一例を示す図である。It is a figure showing an example of the non-buffer part of the Moore machine filter concerning an embodiment. 所定の文字列に対するムーアマシンフィルタのランを示す図である。FIG. 8 is a diagram illustrating a run of a Moore machine filter for a predetermined character string. 実施形態に係る前置情報処理回路の処理回路の一例を示すブロックである。3 is a block diagram illustrating an example of a processing circuit of the pre-information processing circuit according to the embodiment. 実施例1に係る自動車のトルクセンサのデータのためのムーアマシンフィルタの一例を示す図である。FIG. 3 is a diagram illustrating an example of a Moore machine filter for data of a vehicle torque sensor according to the first embodiment. 実施例1に係る自動車のギアセンサのデータのためのムーアマシンフィルタの一例を示す図である。FIG. 3 is a diagram illustrating an example of a Moore machine filter for data of a gear sensor of the vehicle according to the first embodiment. 実施例1に係る自動車のアクセルセンサのデータのためのムーアマシンフィルタの一例を示す図である。FIG. 4 is a diagram illustrating an example of a Moore machine filter for data of an accelerator sensor of the vehicle according to the first embodiment. 実施例1に係る自動車のトルクセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するフィルタされた実時間付き文字列長を示すグラフである。6 is a graph showing a simulation result of a Moore machine filter with respect to the data of the torque sensor of the vehicle according to the first embodiment, and showing a filtered character string length with real time with respect to an input character string length with real time. 実施例1に係る自動車のギアセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するフィルタされた実時間付き文字列長を示すグラフである。4 is a graph showing a simulation result of a Moore machine filter with respect to data of a gear sensor of the vehicle according to the first embodiment, and showing a filtered real-time character string length with respect to an input real-time character string length. 実施例1に係る自動車のアクセルセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するフィルタされた実時間付き文字列長を示すグラフである。6 is a graph showing a simulation result of a Moore machine filter with respect to data of an accelerator sensor of the vehicle according to the first embodiment, showing a filtered character string length with a real time with respect to an input character string length with a real time. 実施例1に係る自動車のトルクセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。5 is a graph showing a simulation result of a Moore machine filter with respect to data of a vehicle torque sensor according to the first embodiment, showing execution time with respect to an input character string length with real time. 実施例1に係る自動車のギアセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。4 is a graph showing a simulation result of a Moore machine filter with respect to data of a gear sensor of an automobile according to the first embodiment, and is a graph showing an execution time with respect to an input character string length with real time. 実施例1に係る自動車のアクセルセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。5 is a graph showing a simulation result of a Moore machine filter with respect to data of an accelerator sensor of the vehicle according to the first embodiment, and is a graph showing an execution time with respect to an input character string length with real time. 実施例1に係る自動車のトルクセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するメモリ使用量を示すグラフである。4 is a graph showing a simulation result of a Moore machine filter with respect to data of a vehicle torque sensor according to the first embodiment, showing a memory usage amount with respect to an input character string length with real time. 実施例1に係る自動車のギアセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するメモリ使用量を示すグラフである。4 is a graph showing a simulation result of a Moore machine filter with respect to data of a gear sensor of the vehicle according to the first embodiment, and showing a memory usage amount with respect to an input character string length with real time. 実施例1に係る自動車のアクセルセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するメモリ使用量を示すグラフである。4 is a graph showing a simulation result of a Moore machine filter with respect to data of an accelerator sensor of the vehicle according to the first embodiment, and showing a memory usage amount with respect to an input real-time character string length. 自動車のトルクセンサのデータに対する、比較例に係るツールのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。10 is a graph showing simulation results of a tool according to a comparative example with respect to data of a vehicle torque sensor, and showing execution time with respect to an input character string length with real time. 自動車のギアセンサのデータに対する、比較例に係るツールのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。10 is a graph showing simulation results of a tool according to a comparative example with respect to data of a gear sensor of an automobile, and showing execution time with respect to an input character string length with real time. 自動車のアクセルセンサのデータに対する、比較例に係るツールのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。9 is a graph showing simulation results of a tool according to a comparative example with respect to data of an accelerator sensor of an automobile, and showing execution time with respect to an input character string length with real time. 実施例2に係る前置情報処理回路の構成例を示すブロック図である。FIG. 9 is a block diagram illustrating a configuration example of a pre-information processing circuit according to a second embodiment. バッファ部の構成例を示す図である。FIG. 3 is a diagram illustrating a configuration example of a buffer unit. オートマトンの状態遷移図の例を示す図である。It is a figure showing an example of a state transition diagram of an automaton. カウンタ付き状態を用いて記述されるオートマトンの状態遷移図の例を示す図である。It is a figure showing an example of a state transition diagram of an automaton described using a state with a counter. 実施例2に係るムーアマシンの状態遷移図の例を示す図である。FIG. 14 is a diagram illustrating an example of a state transition diagram of the Moore machine according to the second embodiment. 実施例2に係るムーアマシンの状態遷移表の例を示す図である。FIG. 14 is a diagram illustrating an example of a state transition table of the Moore machine according to the second embodiment. 実施例2に係るムーアマシンの状態管理テーブルの例を示す図である。FIG. 19 is a diagram illustrating an example of a state management table of the moor machine according to the second embodiment. 実施例2に係る前置情報処理回路の有する各機能ブロックを表した図である。FIG. 9 is a diagram illustrating each functional block included in a front information processing circuit according to a second embodiment. 実施例2に係る前置情報処理回路の処理の流れを示すフローチャートである。9 is a flowchart illustrating a flow of a process performed by a front information processing circuit according to a second embodiment. ムーアマシンの状態遷移時の処理の流れを示すフローチャートである。It is a flow chart which shows a flow of processing at the time of a state transition of a Moore machine. 実時間制約付きムーアマシンを用いた時の前置情報処理回路の処理の流れを示すフローチャートである。It is a flowchart which shows the flow of a process of the front information processing circuit when the real-time constrained Moore machine is used. 実時間制約付きムーアマシンの状態遷移時の処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the process at the time of the state transition of the Moore machine with a real time constraint. リアルタイムオートマトンの決定化処理を示すフローチャートである。It is a flowchart which shows the determination process of a real-time automaton. 実時間制約付きオートマトンをリアルタイムオートマトンに近似させる近似処理を示すフローチャートである。It is a flowchart which shows the approximation process which approximates the automaton with real-time restrictions to a real-time automaton. 実施例3に係る異常時の自動停止機構を有する自動車制御システムの構成例を示すブロック図である。FIG. 13 is a block diagram illustrating a configuration example of an automobile control system having an automatic stop mechanism at the time of abnormality according to a third embodiment. 実施例4に係るセミコネクテッドカーの走行経路最適化機構を有する自動車制御システムの構成例を示すブロック図である。FIG. 14 is a block diagram illustrating a configuration example of a vehicle control system having a traveling route optimization mechanism for a semi-connected car according to a fourth embodiment. 実施例5に係るサーバ装置への攻撃のモニタリングとアクセス遮断機構を有する通信システムの構成例を示すブロック図である。FIG. 18 is a block diagram illustrating a configuration example of a communication system having a mechanism for monitoring an attack on a server device and an access blocking mechanism according to a fifth embodiment.

以下、本発明に係る実施形態及び実施例について図面を参照して説明する。なお、以下の各実施形態において、同様の構成要素については同一の符号を付している。   Hereinafter, embodiments and examples according to the present invention will be described with reference to the drawings. In the following embodiments, the same components are denoted by the same reference numerals.

実施形態.
モニタリングは実時間性のある、組み込みの物理情報システムの実行時検証技法の根幹を成している。数学的には、モニタリング問題はパターンオートマトンに対するパターンマッチング問題として定式化される。本発明者らは組み込みアプリケーション(特にセンサとそれを監視するプロセッサとの通信路の容量が限られているもの)を動機として、モニタリングの前処理としてのフィルタリングについて研究しており、具体的には、所与のパターンオートマトンに対して、フィルタとして機能するムーアマシンを構成する手法を提案する。
Embodiment.
Monitoring forms the basis of real-time, runtime verification techniques for embedded physical information systems. Mathematically, the monitoring problem is formulated as a pattern matching problem for a pattern automaton. The present inventors are motivated by embedded applications (especially those having a limited capacity of a communication path between a sensor and a processor monitoring the sensor), and are studying filtering as a pre-processing of monitoring. For a given pattern automaton, we propose a method to configure a Moore machine that functions as a filter.

その構成はオートマトン理論的であり、また、本発明者らはムーアマシンを利用することが特に組み込みアプリケーションに適していることを発見した。これは、ムーアマシンによる順次的な計算が比較的低コストであるというだけでなく、ムーアマシンが専用回路によるハードウェアアクセラレーションと相性が良いことが理由である。本発明者らはまた、健全性(マッチングを見逃さないこと)も証明する。本発明者らは、次の状況設定でこの研究を行う。1つは、実時間制約なしの設定で、パターンは非決定的有限オートマトン(NFA)で記述される。もう1つは実時間制約付きの設定で、パターンは実時間制約付きオートマトンで記述される。時間なしの構成を時間ありの設定に拡張するのは技術的には複雑であるが、以下の実施形態及び実施例によってその実用上の恩恵が明らかになる。なお、実施形態においては、説明の便宜上、章番号及び節番号を付す。   Its construction is automaton-theoretic, and we have found that the use of Moore machines is particularly suitable for embedded applications. This is not only because the sequential calculation by the Moore machine is relatively low cost, but also because the Moore machine is compatible with hardware acceleration by a dedicated circuit. We also demonstrate soundness (don't miss a match). We perform this study in the following situation setting. One is a setting without real-time constraints, and the pattern is described by a non-deterministic finite automaton (NFA). The other is a setting with a real-time constraint. A pattern is described by an automaton with a real-time constraint. Extending a timeless configuration to a timed configuration is technically complex, but the following embodiments and examples will demonstrate its practical benefits. In the embodiment, a chapter number and a section number are assigned for convenience of explanation.

1.序論
1.1 モニタリングと、実時間制約付きパターンマッチング
1. Introduction 1.1 Monitoring and real-time constrained pattern matching

物理情報システム(Cyber Physical Sysytem;CPS)は日増しに複雑になっている。これは、例えば自動車の燃費などの効率化だけでなく自動運転などの新機能を実現する、急発達してきたデジタル制御のためでもある。従って、このようなシステムを正しく理解することは依然重要かつ取り組み甲斐のある課題である。   The physical information system (Cyber Physical System; CPS) is becoming more and more complex. This is also due to the rapidly developing digital control that realizes new functions such as autonomous driving as well as efficiency such as fuel efficiency of automobiles. Therefore, properly understanding such systems remains an important and challenging task.

このような物理情報システム(CPS)の複雑さや、他のサプライヤによって提供されるブラックボックスな部品といった他の理由のために、従来の意味での形式検証を実世界の物理情報システム(CPS)に適用することは困難である。このために、研究者や実務者はいわゆる軽量形式検証に注目することになった。実行時形式検証はその取り組みの1つであり、所与のシステムの実行結果列が、所与の仕様に対して検査される。この目的のためにモニタリング用の様々なアルゴリズムが提案されてきた。   Due to the complexity of physical information systems (CPS) and other reasons, such as black-box parts provided by other suppliers, formal verification in the traditional sense can be applied to real-world physical information systems (CPS). It is difficult to apply. For this reason, researchers and practitioners have turned their attention to so-called lightweight formal verification. Runtime verification is one such approach, in which the execution result sequence of a given system is checked against a given specification. Various algorithms for monitoring have been proposed for this purpose.

数学的に言うと、モニタリング問題の一般的な定式化の1つとしてパターンマッチング問題がある(もう1つの一般的な定式化は、本発明者らが言うところのパターン検索問題である。パターン検索はパターンマッチングよりも簡単だが、より少ない情報しかもたらさない。)。実行結果列が文字列w=a…aによって与えられているとき、期待される出力は、添字(i,j)の組で所与のパターンpatを満足させる文字列wの制限を表す複数のものの集合 Mathematically speaking, there is a pattern matching problem as one of the general formulations of the monitoring problem. (Another general formulation is what we call the pattern search problem. Pattern search Is easier than pattern matching, but gives less information.) When the execution result column is given by the string w = a 1 a 2 ... a n, an output to be expected, the subscript (i, j) of the string w that satisfies the given pattern pat a set of limits A set of things representing

Figure 2020057362

である。パターンpatは文字列、文字列の集合、正規表現、あるいはオートマトンなどによって与えられる。また上の式(1)は、i番目からj番目までの文字列がパターンpatと一致することを意味する。
Figure 2020057362

It is. The pattern pat is given by a character string, a set of character strings, a regular expression, an automaton, or the like. Expression (1) above means that the i-th to j-th character strings match the pattern pat.

(例1.1):文字列w1=abbbbbaabと、A1=a(a*)bで与えられる正規表現を考える。ここには3つのマッチングがあって、Match(w,A)={(1,2),(7,9),(8,9)}となる。 (Example 1.1): Consider a regular expression given by a character string w1 = abbbbbaab and A1 = a (a *) b. Here, there are three matchings, and Match (w 1 , A 1 ) = {(1, 2), (7, 9), (8, 9)}.

物理情報システム(CPS)において、重要な課題はパターンマッチングの実時間制約時間付き版の取り扱いである。一般的な定式化の1つでは、実行結果列はタイムスタンプ付き文字列により与えられる。これは時刻記録のついた文字の列(文字列)であり、例えば文字列w=(a,0.1)(b,2.5)(a,3.5)(b,4.8)のようなものである。パターンpatは実時間制約付きオートマトン(Timed Automaton;TA)で与えられ、この下で、文字列wの制限を表す時間区間(t,t')において、その制限が実時間制約付きオートマトン(TA)Aによって受理されるようなものの集合 In physical information systems (CPS), an important issue is the handling of real-time limited time versions of pattern matching. In one common formulation, the execution result sequence is given by a time-stamped string. This is a character string (character string) with a time record. For example, the character string w 2 = (a, 0.1) (b, 2.5) (a, 3.5) (b, 4.8) ). The pattern pat is given by a real-time-constrained automaton (TA). Under the time-pattern (t, t ′) representing the restriction of the character string w, the restriction is set to the real-time constrained automaton (TA). The set of things as accepted by A

Figure 2020057362

が計算される。時間なしの設定とは異なり、実時間制約付きオートマトン(TA)Aではさまざまな実時間についての制約を表現することができ、物理情報システム(CPS)の実行結果列のよりきめ細かい分析ができるようになる。
Figure 2020057362

Is calculated. Unlike the setting without time, the real-time constrained automaton (TA) A can express various real-time constraints and allow a more detailed analysis of the execution result sequence of the physical information system (CPS). Become.

(例1.2):タイムスタンプ付き文字列w=(a,0.1)(b,2.5)(a,3.5)(b,4.8)とパターン「bはaが現われた後2秒以内に現われる」(このパターンに対応する実時間制約付きオートマトン(TA)は本質的に図9にあるものと同じである)を考える。どんなマッチングも、2番目のaとbの連なりを含んでいる。なお、はじめの連なりは遠く離れすぎていることに注意する。そのようなマッチングは例えば文字列w(3,5)で与えられるが、このようなマッチングは非可算無限個存在する。このマッチングの集合は、記号的には{(t,t')|2.5≦t<3.5,4.8<t'}と表わされる。 (Example 1.2): Character string w 2 with time stamp = (a, 0.1) (b, 2.5) (a, 3.5) (b, 4.8) and pattern “b is a Appears within 2 seconds after appearing "(the real-time constrained automaton (TA) corresponding to this pattern is essentially the same as in FIG. 9). Any matching involves a second run of a and b. Note that the first run is too far away. Such matching is given, for example, by a character string w 2 | (3,5) , but there are uncountable infinite number of such matchings. This set of matchings is symbolically represented as {(t, t ′) | 2.5 ≦ t <3.5, 4.8 <t ′}.

物理情報システム(CPS)の設計や展開の様々な場面への明らかな応用があるにも関わらず、実時間制約付きパターンマッチングの研究が始まったのはごく最近である(例えば、非特許文献1,4,6参照)。そのため、実時間制約付きパターンマッチングの産業界での実応用は極めて限定的である。   Despite obvious applications to various aspects of the design and deployment of physical information systems (CPS), research on real-time constrained pattern matching has only recently begun. , 4, 6). Therefore, the practical application of the real-time constrained pattern matching in the industrial world is extremely limited.

1.2 組み込みアプリケーションの遠隔モニタリング
この実施形態では、実時間制約付きのパターンマッチング、もしくは実時間制約なしのパターンマッチングのためのフィルタリングを提案する。これは、入力文字列に適用される前処理である。
1.2 Remote monitoring of embedded applications This embodiment proposes filtering for pattern matching with real-time constraints or pattern matching without real-time constraints. This is preprocessing applied to the input character string.

この研究の動機は、組み込みアプリケーションに由来する。組み込みシステム(これは物理情報システム(CPS)の重要な一面である)では、センサと(モニタリングの計算を行なう)プロセッサが物理的に別々の場所に置かれることが普通である。さらに、それらの通信路は限られた容量しかないことがしばしばである(図1参照)。   The motivation for this research comes from embedded applications. In an embedded system, which is an important aspect of a physical information system (CPS), it is common for sensors and processors (which perform monitoring calculations) to be in physically separate locations. In addition, these channels often have limited capacity (see FIG. 1).

図1は実施形態に係る物理情報システム(CPS)の構成例を示すブロック図である。   FIG. 1 is a block diagram illustrating a configuration example of a physical information system (CPS) according to the embodiment.

図1において、物理情報システム(CPS)は、センサ装置1と、モニタ装置2とを備えて構成され、これらが例えばCANバス、無線ネットワークなどの制限された通信容量を有する通信回線10を介して接続される。ここで、センサ装置1は、センサ3と、より低速のプロセッサを有する前置情報処理回路4とを備えて構成され、モニタ装置2は、より高速のプロセッサを有する後置情報処理回路5と、表示部6とを備えて構成される。   In FIG. 1, a physical information system (CPS) includes a sensor device 1 and a monitor device 2, which are connected via a communication line 10 having a limited communication capacity such as a CAN bus or a wireless network. Connected. Here, the sensor device 1 includes a sensor 3 and a front information processing circuit 4 having a lower speed processor, and the monitor device 2 includes a rear information processing circuit 5 having a higher speed processor. The display unit 6 is provided.

そのような状況の例を例えば現代的な自動車に見ることができる。そこでは、エンジンの中にあるセンサ装置1はデータを集めて、例えばエンジンの熱と振動を避けるために、遠隔に載置されたプロセッサを有するモニタ装置2に送信している。センサ装置1とモニタ装置2とは例えばコントローラーエリアネットワーク(CAN)等の通信回線10を介して相互に接続されている。この通信回線10は、コスト削減のための厳しい性能制限のもとにある。別の例をネットワーク等の通信回線10に接続された家庭電化製品や自動車のようなIoT(Internet of Things)デバイスに見ることができる。IoTデバイスは自身の状態を絶え間なくサーバ装置に送信し、クラウドに設置されたそのサーバ装置はそのデバイスを監視する。なお、その無線通信回線は、例えばデバイスの電池の容量などにより限られている。   Examples of such situations can be seen, for example, in modern automobiles. There, a sensor device 1 in the engine collects data and transmits it to a monitor device 2 having a remotely mounted processor, for example, to avoid heat and vibration of the engine. The sensor device 1 and the monitor device 2 are connected to each other via a communication line 10 such as a controller area network (CAN). This communication line 10 is subject to severe performance restrictions for cost reduction. Another example can be found in IoT (Internet of Things) devices such as home appliances and automobiles connected to a communication line 10 such as a network. The IoT device constantly transmits its state to the server device, and the server device installed in the cloud monitors the device. The wireless communication line is limited by, for example, the battery capacity of the device.

本実施形態では、前置情報処理回路4は、入力される実時間のタイムスタンプ付きイベントのシーケンスデータに関する所定のマッチング条件を記述したオートマトン(実時間制約付き又は実時間制約なしのオートマトンである)に基づいてムーアマシンを生成し、生成されたムーアマシンを用いて、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去するようにフィルタリングしてフィルタリング結果のシーケンスデータを出力し、出力されるシリアルデジタルデータは通信回線10を介してモニタ装置2の後置情報処理回路5に送信される。これに応答して、後置情報処理回路5は、前記フィルタリング結果のシーケンスデータから前記マッチング条件に一致するシーケンスデータを抽出して表示部6に出力する。   In the present embodiment, the pre-information processing circuit 4 is an automaton describing a predetermined matching condition regarding sequence data of an input real-time time-stamped event (automaton with real-time constraint or without real-time constraint). Generating a Moore machine based on, and using the generated Moore machine, performing filtering to substantially remove data that does not match the matching condition from the sequence data, outputting sequence data of a filtering result, and outputting The serial digital data is transmitted to the downstream information processing circuit 5 via the communication line 10. In response, the post-processing unit 5 extracts sequence data that matches the matching condition from the sequence data of the filtering result and outputs the sequence data to the display unit 6.

1.3 実時間制約付きパターンマッチングのためのフィルタリング
このような遠隔モニタリングの状況で、モニタリングの結果に影響しないようにセンサからプロセッサに送られるデータの量を削減しようというのは自然な考えである。多くのセンサはプロセッサを内蔵しているので、それらを前処理に利用することができる。ここで、(センサ内蔵の、図1)プリプロセッサは実際のモニタリングを行うプロセッサよりもずっと遅いということを仮定する。つまり、前処理は計算量的な意味で安上りでなければいけない。
1.3 Filtering for Real-Time Constrained Pattern Matching In such remote monitoring situations, it is a natural idea to reduce the amount of data sent from the sensor to the processor so as not to affect the monitoring results. . Many sensors have built-in processors, which can be used for preprocessing. Here, it is assumed that the preprocessor (with built-in sensors, FIG. 1) is much slower than the processor that performs the actual monitoring. That is, the preprocessing must be cheap in terms of computational complexity.

図2は、図1に示された物理情報システム(CPS)において行われるパターンマッチング処理と、フィルタリング処理との関係を概念的に表したものである。図2において、フィルタ部(MN,A)7は、センサ装置1が有する機能ブロックで、たとえば前置情報処理回路4によって実現される機能ブロックである。パターンマッチング部8はモニタ装置2に設けられる機能ブロックで、たとえば後置情報処理回路5によって実現される機能ブロックである。つまり、図2に示すように、本発明者らの提案するワークフローにおいては、フィルタ部(MN,A)7を用いて、入力文字列に対して計算量的に安上りなフィルタリングを適用することによって、前置情報処理回路4から後置情報処理回路5のプロセッサへデータを送信するための通信回線10の負荷を軽減し、さらに当該プロセッサへの負荷も軽減する。 FIG. 2 conceptually shows a relationship between a pattern matching process performed in the physical information system (CPS) shown in FIG. 1 and a filtering process. In FIG. 2, a filter unit (M N, A ) 7 is a functional block included in the sensor device 1, for example, a functional block realized by the front information processing circuit 4. The pattern matching unit 8 is a functional block provided in the monitor device 2, for example, a functional block realized by the post-processing unit 5. That is, as shown in FIG. 2, in the workflow proposed by the present inventors, the filtering unit (M N, A ) 7 is used to apply inexpensive filtering to the input character string in terms of computational complexity. This reduces the load on the communication line 10 for transmitting data from the front information processing circuit 4 to the processor of the rear information processing circuit 5, and further reduces the load on the processor.

1.4 フィルタとしてのムーアマシン 1.4 Moore machine as a filter

この実施形態では、モニタリングの次の2つの設定に取り組む:
(1)実時間制約なしの設定:実行結果列は文字列w∈Σ*であり、パターンはΣ上の非決定的有限オートマトン(NFA)Aで与えられる。
(2)実時間制約ありの設定:実行結果列は実時間制約つき文字列であり、パターンは実時間制約付きオートマトン(Timed Automaton;TA)で与えられる。本発明者らの技術的な貢献は、パターンオートマトンAとバッファサイズN(自然数)にもとづいて、ムーアマシンとして実現されるフィルタMA,Nの構成を与えることにある。ムーアマシンは状態つき計算のよく知られたモデルであり、状態に依存した出力関数を追加に持つオートマトンである。これはシーケンシャルかつ同期的に良く動作し、入力1文字を読み、次の状態に移動し、1文字を出力するという風に動作する。この特性は特にデジタル回路の論理合成に適しており、FPGA(Field Programmable Gate Array)やASIC(Application Specific Integrated Circuits)によるハードウェアアクセラレーションを利用することができる。
In this embodiment, two settings for monitoring are addressed:
(1) Setting without real-time constraint: The execution result sequence is a character string w∈Σ *, and the pattern is given by a nondeterministic finite automaton (NFA) A on Σ.
(2) Setting with real-time constraint: The execution result sequence is a character string with a real-time constraint, and the pattern is given by a real-time-constrained automaton (Timed Automaton; TA). The technical contribution of the present inventors is to provide a filter M A, N realized as a Moore machine based on the pattern automaton A and the buffer size N (natural number). A Moore machine is a well-known model of stateful computation, and is an automaton with an additional state-dependent output function. This works well sequentially and synchronously, reading one input character, moving to the next state, and outputting one character. This characteristic is particularly suitable for logic synthesis of a digital circuit, and hardware acceleration by an FPGA (Field Programmable Gate Array) or an ASIC (Application Specific Integrated Circuits) can be used.

このようなムーアマシンのシーケンシャルな動作は、パターンマッチングの動作と極めて対照的である。本発明者らの設定ではパターンはオートマトンAで与えられるので、マッチングの長さ(例えば、w|[i,j]∈L(A)となるような|w|[i,j]|=j−i+1)は固定されていない。従って、入力文字列wについて、マッチングの窓を異なる大きさと異なる位置で前後に動かしながら試してみる必要がある(図3A参照)。図3Aは実施形態で用いるパターンマッチングにおける前後の移動処理を示すタイミングチャートである。 The sequential operation of such a Moore machine is in sharp contrast to the operation of pattern matching. Since the pattern is given by the automaton A in our setting, the matching length (for example, | w | [i, j] | = j such that w | [i, j] iL (A) is satisfied) −i + 1) is not fixed. Therefore, it is necessary to try the input character string w while moving the matching window back and forth at different sizes and different positions (see FIG. 3A). FIG. 3A is a timing chart showing the back and forth movement processing in the pattern matching used in the embodiment.

このことは、比較的低速のプリプロセッサを有する前置情報処理回路4による(シーケンシャルな)フィルタリング作業と、比較的高速のメインプロセッサを有する後置情報処理回路5による、図3Aに示すように、前後に動かしながらのパターンマッチング作業との間には質的な差があることを示している。本発明者らの構成は、実時間制約付きの設定であっても実時間制約なしのムーアマシンをフィルタMA,Nとして生成する。 This is because the (sequential) filtering operation by the front-end information processing circuit 4 having a relatively low-speed preprocessor and the back-end information processing circuit 5 having a relatively high-speed main processor, as shown in FIG. This indicates that there is a qualitative difference between the pattern matching operation and the moving operation. In the configuration of the present inventors, a Moore machine without a real-time constraint is generated as the filters MA and N even if the setting has a real-time constraint.

ムーアマシンフィルタMA,Nの出力は、いくらかの文字が未使用の文字⊥でマスクされることを除けば入力(実時間制約付き)文字列と同じである(なお、本明細書において、文字⊥は、ムーアマシンフィルタMA,Nに入力される文字列(入力文字列)を構成する文字のセットの中に含まれ得ない文字を意味する)。例えば、パターンA=aa*bの下ではw=abbbbbaabはab⊥⊥⊥⊥aabに加工される。連続した⊥の長さをバイナリ表示することにより、データのサイズは指数的に減少する。さらに、もしマッチングした部分文字列w|[i,j]にだけ興味があるなら(つまり添字i,jに興味がないなら)、さらに連続した⊥を1つの⊥に潰すことができる。フィルタリングの段階ですべての⊥を除いてしまうことは、パターンマッチングの段階で偽物のマッチングを起こすかもしれないことに注意する(図2参照)。 The output of the Moore machine filter MA , N is the same as the input (real-time constrained) string except that some characters are masked with the unused character ⊥ ⊥ means a character that cannot be included in a set of characters constituting a character string (input character string) input to the Moore machine filter MA , N ). For example, under the pattern A = aa * b, w = abbbbbbaab is processed to ab⊥⊥⊥⊥aab. The binary representation of the length of successive ⊥ reduces the size of the data exponentially. Furthermore, if only the matched partial character string w | [i, j] is interested (that is, if the subscripts i and j are not interested), the continuous 潰 can be reduced to one ⊥. Note that removing all ⊥ in the filtering stage may cause fake matching in the pattern matching stage (see FIG. 2).

本発明者らのムーアマシンフィルタMA,Nは、パターンオートマトンAとバッファサイズを表わす正整数Nから構成される。パラメータNによって、利用者はフィルタリングのコスト(Nを大きくすると、ムーアマシンフィルタMA,Nの状態数は増える)とフィルタをかけた文字列のサイズ(Nを大きくすると⊥が増え、つまりフィルタをかけた文字列は小さくなる)とのバランスを選ぶことができる。この柔軟性は、このアルゴリズムを様々なハードウェアの設定に適したものにしている。 The Moore machine filter M A, N of the present inventors is composed of a pattern automaton A and a positive integer N representing a buffer size. Depending on the parameter N, the user can increase the cost of filtering (as N is increased, the number of states of the Moore machine filter MA , N is increased) and the size of the filtered character string (as N is increased, 増 え is increased. (The multiplied character string becomes smaller). This flexibility makes the algorithm suitable for various hardware configurations.

本発明者らはこの構成を実装し、実時間制約付きの設定(こちらのほうが難しい)についての実験結果を示す。例は自動車の分野から選んだものである。その結果、実際の問題に即したパターン(実時間制約付きオートマトン(TA))Aと入力のタイムスタンプ付き文字列wについて、フィルタされた文字列は元の文字列wに比べて2〜100倍短くなりうることを見る。さらに、ムーアマシンフィルタMA,Nを実行するのは計算量的に軽いことを実験的に確認する。さらに、図2のフィルタ部7を使うことで、実時間制約付きパターンマッチング自身も1.2〜2倍加速することを見る。 We implement this configuration and show experimental results for settings with real-time constraints (this is more difficult). Examples are from the automotive sector. As a result, for the pattern A (real-time constrained automaton (TA)) A and the input time-stamped character string w according to the actual problem, the filtered character string is 2 to 100 times as large as the original character string w. See what can be shorter. Further, it is experimentally confirmed that the execution of the Moore machine filter MA , N is light in calculation amount. Further, it can be seen that the use of the filter unit 7 in FIG. 2 accelerates the pattern matching with real-time constraints by 1.2 to 2 times.

この構成の理論的な解析について、本発明者らは健全性、すなわち元の入力文字列の全てのマッチングがフィルタによって保たれることを証明する。この健全性は、実時間制約付き、なしの両方について証明される。しかしながら、健全性は自明な恒等のフィルタによって満足されることに注意されたい。よって、健全性そのものからはフィルタリングの恩恵はあまり分からない。実験に加えて、本発明者らは実時間制約なしの設定でのフィルタリングの性能についてのいくらかの理論的な結果について述べる。これは次のようなものである。   With a theoretical analysis of this configuration, we demonstrate soundness, ie, that all matching of the original input string is preserved by the filter. This soundness is proven both with and without real-time constraints. Note, however, that soundness is satisfied by a trivial identity filter. Therefore, the benefits of filtering are not very obvious from the soundness itself. In addition to experiments, we describe some theoretical results on the performance of filtering in a real-time unconstrained setting. This is as follows.

言語L(A)が有限のとき(複数文字列マッチングの設定)の完全性(全ての不要な文字列がマスクされるという意味)と、単調性(Nを大きくするとフィルタリングの結果が良くなる)とは、実時間制約付きの設定は実時間制約なしの設定と基本的な考えは共通しているので、これらの結果もまた実時間制約付きの構成の性能上の優位性を示している。   When the language L (A) is finite (setting of multiple character string matching), the completeness (meaning that all unnecessary character strings are masked) and the monotonicity (the filtering result improves as N increases). Since the setting with the real-time constraint has the same basic idea as the setting without the real-time constraint, these results also show the performance advantage of the configuration with the real-time constraint.

本発明者らのフィルタの構成はオートマトン理論的であり、次の2つの基本的なステップからなる。(1)(サイズNの)バッファを用意し、(2)決定化する。実時間制約付きの設定での2番目のステップのために、所与の実時間制約付きオートマトン(Timed Automaton:TA)を1クロック決定的TAで過大評価する、TAの1クロック決定化(例えば、非特許文献2の5.3節参照)を利用する。   The construction of our filter is automaton theoretical and consists of the following two basic steps. (1) Prepare a buffer (of size N), and (2) Decide. For a second step in a real-time constrained setup, a given real-time constrained automaton (TA) is overestimated by a one-clock deterministic TA; (See Section 5.3 of Non-Patent Document 2).

1.5 貢献
本発明者らの貢献(実施形態の特徴であるSTF(Special Technical Features))は次のようにまとめられる。
(1)オートマトンAに対する実時間制約なしパターンマッチングのためのフィルタMA,Nの構成。フィルタはムーアマシンで与えられ、従って単純かつシーケンシャルで同期的に動作する。さらに、論理回路によるハードウェアアクセラレーションと相性が良い。パラメータNによって、利用者は計算コストとフィルタリングの効果のトレードオフを調整することができる。
(2)実時間制約付きパターンマッチングのためのムーアマシンフィルタMA,Nの構成。パターンとしての実時間制約付きオートマトンAとバッファサイズが与えられたとき、(実時間制約なし)ムーアマシンフィルタMA,Nを構成する。この構成は実時間制約なしのものの拡張なのでより一般的であり、パターン実時間制約付きオートマトンのゾーンにもとづく構成を利用している。実用性も考慮すると、本発明者らはこの実時間制約付きの構成がこの実施形態の主な貢献であると考える。
(3)健全性(全てのマッチングの保存)が実時間制約付き、実時間制約なしの設定で証明される。
(4)実時間制約付きの設定で、さらに本発明者らのフィルタの性能についての理論的な結果を証明する。
(5)実時間制約付きの構成の実装、及び本発明者らのフィルタの構成の利益を示す実験。
1.5 Contribution The contributions of the present inventors (Special Technical Features (STF), which is a feature of the embodiment), are summarized as follows.
(1) Configuration of filters MA and N for pattern matching without any real-time restriction on automaton A. The filters are provided on a Moore machine and thus operate simply, sequentially and synchronously. Further, it is compatible with hardware acceleration by a logic circuit. The parameter N allows the user to adjust the trade-off between the computation cost and the filtering effect.
(2) Configuration of Moore machine filters MA and N for pattern matching with real-time constraints. Given a real-time constrained automaton A as a pattern and a buffer size, (without real-time restrictions) form a Moore machine filter MA , N. This configuration is more general because it is an extension of the one without real-time constraints, and utilizes a zone-based configuration of the automaton with pattern real-time constraints. Considering practicality, we consider this real-time constrained configuration to be a major contribution of this embodiment.
(3) Soundness (preservation of all matches) is proved by setting with real-time constraints and no real-time constraints.
(4) In a setting with real-time constraints, further demonstrate our theoretical results on the performance of our filters.
(5) Experiments showing the implementation of the real-time constrained configuration and the benefits of our filter configuration.

1.6 パターンマッチング対パターン検索
モニタリングのもう1つの数学的な定式化(つまりパターンマッチングのもう1つの選択肢)は、本発明者らの言うところのパターン検索問題である。これは、マッチング集合(1.2節参照)が空かそうでないかを問うものである。パターン検索は簡単に所属判定問題に帰着されるため魅力的である。大雑把に言うと、パターンオートマトンAが与えられたとき、まず初期状態に自己ループを付け足して入力文字列の接頭辞を無視できるようにし、あとは受理状態がアクティブになるかどうかを監視すればよい。パターン検索はモニタリングの文脈ですでに十分に研究されている。
1.6 Pattern Matching vs. Pattern Search Another mathematical formulation of monitoring (ie another option for pattern matching) is what we call the pattern search problem. This asks whether the matching set (see section 1.2) is empty or not. The pattern search is attractive because it can easily be reduced to an assignment determination problem. Roughly speaking, when the pattern automaton A is given, a self-loop may be added to the initial state so that the prefix of the input character string can be ignored, and then it may be monitored whether the accepting state becomes active. . Pattern search is already well studied in the context of monitoring.

パターンマッチングは添字を覚えておく必要があり(図3A)、パターン検索よりも計算量的に高くつく。しかしながら、実世界のモニタリングアプリケーションと強い関係がある(特に下記の例1.3にあるような遠隔モニタリングにおいて)。遠隔モニタリングはしばしば単に準オンラインであることに注意されたい。というのは、ログはかなりの大きさの塊で途切れ途切れにモニタに届くかもしれない。従って、受け取ったログのどの部分が警告を出しているのかを取り出すことができるというのが必須である。   Pattern matching requires memorizing subscripts (FIG. 3A) and is computationally more expensive than pattern search. However, there are strong implications for real-world monitoring applications (especially in remote monitoring as in Example 1.3 below). Note that remote monitoring is often simply quasi-online. The logs may be large chunks and reach the monitor in short bursts. Therefore, it is essential to be able to extract which part of the received log gives the warning.

パターンマッチングのモニタリングアプリケーションへの適用可能性はコミュニティでよく認知されており、近年文献は急増している(例えば、非特許文献4,5参照)。   The applicability of pattern matching to monitoring applications is well recognized by the community, and the literature has been rapidly increasing in recent years (for example, see Non-Patent Documents 4 and 5).

(例1.3)(準オンライン遠隔モニタリング):遠隔モニタリング(図1)の具体例として、準ネットワーク接続自動車を考えよう。これは運転ログをメモリに保持し、既知の無線ネットワークの範囲に停車したらそのログをインターネット経由でセンターに送信する。ログの解析はセンターで行なわれる。運転ログは自動車の位置、速度とアクセルについての情報を含むタイムスタンプ付き文字列である。そのようなタイムスタンプ付き文字列wの1つ(ROSBAGSTORE,rosbag.tier4.jpから取られたもの)は、自動車の位置をプロットすると図3Bのように見える。 Example 1.3 (Semi-Online Remote Monitoring): As a specific example of remote monitoring (FIG. 1), consider a semi-network connected vehicle. This stores an operation log in a memory and transmits the log to the center via the Internet when the vehicle stops in a range of a known wireless network. Log analysis is performed at the center. The driving log is a time-stamped character string containing information on the position, speed, and accelerator of the vehicle. One such time-stamped string w (taken from ROSBAGSTORE, rosbag.tier4.jp) looks like FIG. 3B when plotting the position of the car.

図3Bは従来文献でのパターンマッチングにおける位置プロットの一例を示す平面図であり、図3Cは図3Bの位置プロットでの区間の特定を示す平面図である。   FIG. 3B is a plan view showing an example of a position plot in pattern matching in a conventional document, and FIG. 3C is a plan view showing the specification of a section in the position plot of FIG. 3B.

ここで、「プロットは不連続である。」というのは、例えばGPS信号の喪失などによりデータがなくなるかもしれない。このような道の区間のうち、アクセルが10秒以上ある閾値を超えるものに興味があるとする。適切なパターンオートマトンAで文字列wに実時間制約付きパターンマッチングを実行する。特定した時間区間を位置のプロットにマッピングすると、知りたかった道の区間を特定することができる(図3C参照、ハッチング部分はツールMONAAによって生成)。   Here, "the plot is discontinuous" means that data may be lost due to, for example, loss of the GPS signal. Among such road sections, it is assumed that the user is interested in a section in which the accelerator exceeds a certain threshold for 10 seconds or more. The real-time constrained pattern matching is performed on the character string w using an appropriate pattern automaton A. By mapping the specified time section to the plot of the position, the section of the road that the user wanted to know can be specified (see FIG. 3C, the hatched portion is generated by the tool MONAA).

(実施形態の構成)2章で用語を定義する。3章で実時間制約なしパターンマッチングのためのムーアマシンフィルタを構成する。さらに、健全性といった性質も証明する。4章でも同じ考えが、より複雑な問題である実時間制約つきパターンマッチングのためのフィルタリングに使われる。ここで健全性を証明する。5章では実時間制約つきの場合の実装と実験結果が示される。関連研究については6章で議論する。 (Configuration of the Embodiment) Terms are defined in Chapter 2. Chapter 3 constitutes a Moore machine filter for pattern matching without real-time constraints. In addition, they demonstrate properties such as soundness. The same idea is used in Chapter 4 for filtering for more complex problems, real-time constrained pattern matching. Here we prove its soundness. Chapter 5 shows the implementation and experimental results for the case with real-time constraints. Related studies are discussed in Chapter 6.

2.準備 2. Preparation

集合   set

Figure 2020057362

はΣ上の文字列の集合である。文字列w=a…a(ここで、a∈Σ)の長さnは|w|と書かれる。
Figure 2020057362

Is a set of character strings on Σ. The length n of the character string w = a 1 a 2 ... An (here, a i ∈Σ) is written as | w |.

非決定的有限オートマトン(NFA)A=(Σ,S,s,S,E)と、共通したアルファベットΣ上の文字列w∈Σ*について、文字列w上のオートマトンAのラン(RUN) Non-deterministic finite automata (NFA) A = (Σ, S, s 0, S F, E) and, for the string w∈Σ * on common alphabet Σ, of the automaton A on the string w run (RUN)

Figure 2020057362

は列
Figure 2020057362

Is a column

Figure 2020057362

であって、任意のi∈[1,|w|]について(si−1,w,s)∈Eが成り立つもののことである。ラン
Figure 2020057362

And (s i−1 , w i , s i ) ∈E holds for any i∈ [1, | w |]. run

Figure 2020057362

はs|w|∈Sが成り立つとき受理する(受理状態となる)という。
Figure 2020057362

The s | w | ∈S F is accepted when satisfied that (the accepting state).

Xの冪集合はP(X)と書かれる。XとYの非交和はX凵Yである。アルファベットΣについて、未使用の記号⊥で拡張された集合Σ凵{⊥}はΣと書かれる。 The power set of X is written P (X). The union of X and Y is XUY. For the alphabet Σ, the set Σ which is expanded with unused symbols is written as Σ {⊥}.

集合{1,2,…,N}をカウンタの値域として用いる。その代数的構造(例えばモジュロNでの足し算)を利用するので、これはZ/NZと書かれる。   The set {1, 2,..., N} is used as the value range of the counter. This is written as Z / NZ because it uses its algebraic structure (eg addition with modulo N).

ムーアマシンはM=(Σin,Σout,Q,q,Δ,Λ)である。ただし、ΣinとΣoutは入力と出力のアルファベットであり、Qは状態の有限集合、q∈Qは初期状態、Δ:Q×Σin→Qは遷移関数、Λ:Q→Σoutは出力関数である。ムーアマシンMと入力文字列w=a…a∈Σ*in(ただしa∈Σin)について、文字列w上のムーアマシンMのラン Moore machine M = (Σ in, Σ out , Q, q 0, Δ, Λ) is. Here, in in and Σ out are alphabets of input and output, Q is a finite set of states, q 0 ∈Q is an initial state, Δ: Q × Σ in → Q is a transition function, and Λ: Q → Σ out is Output function. For the Moore machine M and the input character string w = a 1 a 2 ... An ∈Σ * in (where a i in ), the run of the Moore machine M on the character string w

Figure 2020057362

は列
Figure 2020057362

Is a column

Figure 2020057362

であって、任意のi∈[1,|w|]についてq=Δ(qi−1,a)を満足するものである。このとき、文字列w上のムーアマシンMの出力文字列w'∈Σ*outは、w'=Λ(q)Λ(q)…Λ(qn−1)∈Σ*outである。
Figure 2020057362

And satisfies q i = Δ (q i−1 , a i ) for an arbitrary i∈ [1, | w |]. At this time, the output character string w′∈Σ * out of the Moore machine M on the character string w is w ′ = Λ (q 0 ) Λ (q 1 )... Λ (q n−1 ) ∈Σ * out . .

3.パターンマッチングのためのムーアマシンフィルタリング1:実時間制約なし 3. Moore machine filtering for pattern matching 1: no real-time constraints

3.1 問題の定式化
(定義3.1)(実時間制約なしパターンマッチング):アルファベットΣ上の非決定的有限オートマトン(NFA)Aと文字列a…a∈Σ*について、パターンマッチング問題はマッチング集合
3.1 Formulation of the problem (definition 3.1) (no real-time constraints pattern matching): For non-deterministic finite automaton on the alphabet Σ (NFA) A and a string a 1 a 2 ... a n ∈Σ *, pattern Matching problem is a matching set

Figure 2020057362

を問うものである。ただし、w|[i,j]=ai+1…aである。
Figure 2020057362

Is to ask. However, w | a [i, j] = a i a i + 1 ... a j.

本発明者らの目標は図2に示されたワークフローである。フィルタ部7の入出力の型を次のような一般的な定義で定めよう。   Our goal is the workflow shown in FIG. The input / output type of the filter unit 7 will be defined by the following general definition.

(定義3.2)(実時間制約なしパターンマッチングのためのムーアマシン):オートマトンAをアルファベットΣ上の非決定的有限オートマトン(NFA)とし、Nを正整数とする。オートマトンAのバッファサイズNのフィルタとは、ムーアマシンフィルタM=(Σin,Σout,Q,q,Δ,Λ)であって、次を満足するものである。 (Definition 3.2) (Moore machine for pattern matching without real-time constraints): Let automaton A be a non-deterministic finite automaton (NFA) on alphabet Σ and N be a positive integer. The filter buffer size N of the automaton A, Moore machine filter M = (Σ in, Σ out , Q, q 0, Δ, Λ) a, and satisfies the following.

(1)Σin=Σout=Σ
(2)w=a…a∈Σ*を任意の文字列とし、終端に⊥を付け足した文字列w⊥を考える。この文字列w⊥についてのムーアマシンMの出力文字列は⊥w'の形でなければいけない。ただし、文字列w'=b…bであり、文字bは任意のiについてマスク⊥か文字aかのどちらかである。位置iにある文字aはb=aが成立するとき通過したという。そうでなければ(つまりb=⊥なら)、文字aはマスクされたという。
(1) in in = Σ out = Σ
(2) Consider a character string w N where w = a 1 ... An n * is an arbitrary character string and 終端 is added at the end. The output string of Moore machine M for this string w⊥ N should not to be in the form of a ⊥ N w '. However, the character string w ′ = b 1 ... B n , and the character b i is either the mask ⊥ or the character a i for an arbitrary i. Character a i at position i is that has passed when b i = a i is established. Otherwise (ie, if b i = b), the character a i is said to be masked.

ムーアマシンフィルタMは全てのマッチング区間を保つときに健全であるという。これは、   The Moore machine filter M is said to be sound when all the matching sections are kept. this is,

Figure 2020057362

となる任意のk∈[1,n]についてb=aが成立するという意味である。
Figure 2020057362

This means that b k = ak holds for any k∈ [1, n] such that

図4は実施形態におけるフィルタリングのパディング処理を示す概念図である。   FIG. 4 is a conceptual diagram illustrating padding processing of filtering in the embodiment.

バッファサイズNと、入出力文字列の⊥での付け足しについて説明しよう。付け足しは、図4に図示される方法で、Nステップ遅れてフィルタリングがされていることを意味する。この遅れは本発明者らのムーアマシンの動作の仕方のためである。というのは、このムーアマシンは入力文字列を左から右に読み、状態空間Qにエンコードされる形式で、N文字をFIFOバッファに蓄え、FIFOバッファから文字を取り出すときにそれを出力文字列として出力する。そういうわけで、Nステップ分の遅れが生じるのである。 And the buffer size N, tried to explain about the afterthought in ⊥ N of input and output string. The addition means that filtering is performed with a delay of N steps in the method illustrated in FIG. This delay is due to the way our Moore machine operates. This is because the Moore machine reads the input string from left to right, stores N characters in a FIFO buffer in a format encoded in the state space Q, and uses it as an output string when extracting characters from the FIFO buffer. Output. That is why a delay of N steps occurs.

図5は実施形態におけるムーアマシンによるフィルタリング処理を示す概念図である。   FIG. 5 is a conceptual diagram showing a filtering process by the Moore machine in the embodiment.

図5において、まず最初に、バッファは⊥で埋め尽されており(図5のステップS0)、これが出力文字列⊥w'に接頭辞⊥が現れる理由である。入力文字列w⊥の末尾の付け足し⊥はバッファの内容を取り出すのに必要である(ステップS(n+1)からステップS(n+N))。図5の処理の途中で、文字列w=a…aの文字のいくらかがマスクされる(b=⊥)が、この図5の中ではそれは明示されていない。 5, first, the buffer are exhausted filled with ⊥ (step S0 in FIG. 5), which is why the prefix ⊥ N appears at the output string ⊥ N w '. Trailing afterthought ⊥ N of the input string W⊥ N is required to retrieve the contents of the buffer (step S (n + 1) from the step S (n + N)). During the process of FIG. 5, some of the characters of the character string w = a 1 ... A N are masked (b i = ⊥), but are not explicitly shown in FIG.

3.2 ムーアマシンフィルタMA,Nの構成 3.2 Configuration of Moore Machine Filter MA , N

(定義3.3)((実時間制約なし)パターンマッチングのためのムーアマシンフィルタMA,N):Σをアルファベットとし、Nを正整数とし、A=(Σ,S,s,S,E)を非決定的有限オートマトン(NFA)とする。ムーアマシンフィルタMA,N=(Σ,Σ,Q,q,Δ,Λ)を次のように定義する。 (Definition 3.3) ((No real time constraint) Moore machine filter M A, N for pattern matching): Let Σ be an alphabet, N be a positive integer, and A = (Σ, S, s 0 , S F) , E) is a nondeterministic finite automaton (NFA). The Moore machine filter M A, N = (Σ , Σ ,, Q, q 0 , Δ, Λ) is defined as follows.

ここで、状態空間Qは   Here, the state space Q is

Figure 2020057362

とする。ここで、Z/NZはモジュロNでの足し算を備えたN元集合である。
Figure 2020057362

And Here, Z / NZ is an N-ary set with addition by modulo N.

初期状態は   The initial state is

Figure 2020057362

である。
Figure 2020057362

It is.

遷移Δ:Q×Σ→Qは次のように定める。任意のa∈Σについて、 Transition Δ: Q × Σ → Q is determined as follows. For any a∈Σ ,

Figure 2020057362
Figure 2020057362

ただし、   However,

Figure 2020057362

であり、
Figure 2020057362

And

Figure 2020057362

である。
Figure 2020057362

It is.

ここで、   here,

Figure 2020057362

である。
Figure 2020057362

It is.

最後に、出力関数Λ:Q→Σを次のように定める。 Finally, the output function Λ: determine Q → Σ the in the following manner.

Figure 2020057362
Figure 2020057362

直観について述べる。ムーアマシンフィルタMA,Nの構成は次の3つのブロックを組合せたものである:それは、決定化の処理部(詳細後述する図15のCPU20)、カウンタ(図15の22bに含まれる)、サイズNのバッファ(図15の22a)である。 Describe intuition. The configuration of the Moore machine filter MA , N is a combination of the following three blocks: a determinization processing unit (CPU 20 in FIG. 15 described later in detail), a counter (included in 22b in FIG. 15), This is a buffer of size N (22a in FIG. 15).

(決定化)パターンAは非決定的有限オートマトン(NFA)であるが、本発明者らが欲
しいのは決定的ムーアマシンである。この決定化は状態空間Qの部品
(Determinized) Pattern A is a non-deterministic finite automaton (NFA), but what we want is a deterministic Moore machine. This determinization is a part of the state space Q

Figure 2020057362

に冪集合による構成Pが現れる理由を説明している。例えば、この部品の元{(s,n),…,(s,n)}は「非決定的有限オートマトン(NFA)Aにおいて、状態s,…,sはアクティブである」ということを意味している。式(4)を見ると、これは普通の決定化をしていることがわかる。例外は式(4)で(s,0)を追加していることである。これは、入力文字列のどこからでもマッチングを始められるようにするためである。
Figure 2020057362

Explains the reason why the composition P by the power set appears in FIG. For example, the element {(s 1 , n 1 ),..., (S k , n k )} of this part is “states s 1 ,..., Sk are active in nondeterministic finite automaton (NFA) A”. It means that. Looking at equation (4), it can be seen that this is a normal determinization. The exception is that (s 0 , 0) is added in equation (4). This is so that matching can be started from anywhere in the input character string.

(カウンタ)さらに、オートマトンAを動き回るアクティブな状態は、初期状態から何ステップ移動したかを表わすカウンタを(図15の22b内に)持っている。これは状態空間Qの部品Z/NZである。これらのカウンタの最大値はバッファサイズNと同じである。最大値に達すると、カウンタは1から始まる。式(4)を見ると、アクティブな状態のカウンタがモジュロNで1つ増加することが分かる。なお、例えばカウンタの最大値を2×Nとして,増加値を1でなく2に設定してもよく、増加値は1に限定されず、2又は3等の自然数の所定値であってもよい。 (Counter) Further, the active state of moving the automaton A has a counter (in 22b in FIG. 15) indicating how many steps have been moved from the initial state. This is the part Z / NZ of the state space Q. The maximum values of these counters are the same as the buffer size N. When the maximum value is reached, the counter starts at one. It can be seen from equation (4) that the active counter increases by one with modulo N. For example, the maximum value of the counter may be set to 2 × N, and the increment value may be set to 2 instead of 1. The increment value is not limited to 1, and may be a predetermined value such as 2 or 3 which is a natural number. .

(バッファ)サイズNのFIFOバッファ(図15の22a)は状態空間Qに2番目の部品 (Buffer) A FIFO buffer of size N (22a in FIG. 15) is a second component in the state space Q.

Figure 2020057362

が現れる理由を説明している。N個のセルそれぞれがΣの文字とラベル(pass又はmask)を保持している。式(3)と式(5)を見ると、バッファの基本的な動作は一番左の要素を取り出し、読んだ文字を右に追加することだと分かる。
Figure 2020057362

Explains why appears. Each of the N cells holds a character {} and a label (pass or mask). Equations (3) and (5) show that the basic operation of the buffer is to extract the leftmost element and add the character read to the right.

ある文字をマスクするかどうかを決めるのは、バッファのラベル(pass又はmask)である。規定のラベルはmask(式(5)の3番目の場合)であり、Nステップの間そのまま変わらないなら出力の対応する文字は⊥でマスクされる(式(6)の2番目の場合)。ラベルはmaskからpassに2つの異なる理由で変わりうる(式(5)のはじめの2つの場合)。   It is the buffer label (pass or mask) that determines whether a character is masked. The prescribed label is mask (third case in equation (5)), and if it does not change for N steps, the corresponding character in the output is masked with ⊥ (second case in equation (6)). The label can change from mask to pass for two different reasons (the first two cases in equation (5)).

1.式(5)の2番目の場合は、バッファの終端までの複数の文字がパターンAに対してマッチングを成し、パターンAの受理状態s∈Sに導くときである。このとき、これらの複数の文字を「pass」でマークし、パターンマッチングに渡さなくてはいけないことを明示する(図2)。渡される文字数ψ(S')はアクティブな状態s∈Sに関連付けられたカウンタnを用いて計算される。
2.式(5)のはじめの場合の条件
1. For the second expression (5) is when the plurality of characters up to the end of the buffer forms a matched against pattern A, leads to the receiving state S∈S F pattern A. At this time, these characters are marked with "pass" to clearly indicate that they must be passed to pattern matching (FIG. 2). Number of characters to be passed ψ (S ') is calculated using the counter n that is associated with the active s∈S F.
2. Condition for the first case of equation (5)

Figure 2020057362

は、あるアクティブな状態sのカウンタが最大値Nに達したという意味である。この場合、Aのこのアクティブ状態sが最終的に受理状態に到達するのかどうかがはっきりしない。安全側に倒すために、N個の文字全てをマスクせずにパターンマッチングに引き渡す。実時間制約なしの設定では、フィルタリングの完全性が失われるかもしれない箇所はここだけである。
Figure 2020057362

Means that the counter in a certain active state s has reached the maximum value N. In this case, it is not clear whether this active state s of A will eventually reach the accepting state. In order to fall to the safe side, all N characters are passed on to the pattern matching without masking. This is the only place where the integrity of the filtering may be lost in a setting without real-time constraints.

まとめると、定義3.3では図5に図示された方法で動作するムーアマシンを構成している。ムーアマシンの状態空間は次のものを組合せたものである:パターンNFA Aの決定化、初期状態からのステップ数を数えるカウンタ、そして、パス(pass)かマスク(mark)でラベル付けされたN文字を蓄えるFIFO(First−In First−Out)バッファである。   In summary, definition 3.3 constitutes a Moore machine that operates in the manner illustrated in FIG. The Moore machine state space is a combination of the following: the determinant of the pattern NFA A, a counter that counts the number of steps since the initial state, and N labeled with a pass or mask. This is a FIFO (First-In First-Out) buffer for storing characters.

(命題3.4):ムーアマシンMA,Nは定義3.2の意味で、AのバッファサイズNのフィルタである。 (Proposition 3.4): The Moore machine M A, N is a filter with a buffer size N of A in the sense of definition 3.2.

本発明者らの実装ではフィルタを定義3.2で述べたような、状態空間   In our implementation, we define the filter as a state space, as described in 3.2.

Figure 2020057362

を持つようなムーアマシンそのままとしては実現していない。代わりに、状態空間Qを「バッファ部分」
Figure 2020057362

It is not realized as a Moore machine as it is. Instead, state space Q is "buffer part"

Figure 2020057362

と「非バッファ部分」
Figure 2020057362

And the "unbuffered part"

Figure 2020057362

に分割して、前半のバッファ部分を必要になり次第生成している。より正確に述べると、非バッファ部分ははじめに、決定的有限オートマトン(DFA)として一度に構成され、このDFAはサイズNの配列として実現されたバッファ部分をどのように制御するかを支配している。実例を例3.6に示す。
Figure 2020057362

And the buffer part of the first half is generated as needed. More precisely, the non-buffer part is initially configured at one time as a deterministic finite automaton (DFA), which governs how to control the buffer part implemented as an array of size N. . An example is shown in Example 3.6.

(命題3.5):A=(Σ,S,s,S,E)を非決定的有限オートマトン(NFA)とする。誘導されたムーアマシンフィルタMA,Nについて、その状態空間の非バッファ部分P(S×(Z/NZ))のサイズはO(2N・|S|)で押さえられる。 (Proposition 3.5): Let A = (Σ, S, s 0 , S F , E) be a nondeterministic finite automaton (NFA). For the induced Moore machine filter MA , N , the size of the non-buffered part P (S × (Z / NZ)) of its state space is suppressed by O (2N · | S |).

従って、遷移を含めた非バッファ部分のメモリ使用量はO(2N・|S|・|Σ|)である。バッファ部分のメモリ使用量はO(N・log|Σ|)である。まとめると、本発明者らのムーアマシンフィルタMA,Nを実行するときの空間計算量はO(2N・|S|・|Σ|)である。 Therefore, the memory usage of the non-buffer portion including the transition is O ( 2N · | S | · | Σ |). The memory usage of the buffer portion is O (N · log | Σ |). In summary, the amount of space calculation when the Moore machine filter M A, N of the present inventors is executed is O ( 2N · | S | · | Σ |).

空間計算量はNについて指数的であるが、これは非バッファ部分P(S×(Z/NZ))のための冪集合構成に由来する。しかしながら、実験的にはメモリ消費量は必ずしもNについて指数的には増大しない。これは、P(S×(Z/NZ))の全ての状態に到達可能というわけではないからである(5章のRQ2を参照)。   The spatial complexity is exponential for N, but this comes from the power set construction for the unbuffered part P (S × (Z / NZ)). However, experimentally, the memory consumption does not necessarily increase exponentially for N. This is because not all states of P (S × (Z / NZ)) can be reached (see RQ2 in Chapter 5).

図6Aは実施形態に係る非決定的有限オートマトン(NFA)であるパターンの一例を示す図であり、図6Bは実施形態に係るムーアマシンフィルタの非バッファ部分の一例を示す図である。また、図7Aは所定の文字列に対するムーアマシンフィルタのランを示す図である。   FIG. 6A is a diagram illustrating an example of a pattern that is a non-deterministic finite automaton (NFA) according to the embodiment, and FIG. 6B is a diagram illustrating an example of a non-buffer portion of the Moore machine filter according to the embodiment. FIG. 7A is a diagram showing a Moore machine filter run for a predetermined character string.

(例3.6):パターンaa*bを考える。これは図6Aの非決定的有限オートマトン(NFA)Aに示されている。定義3.3のムーアマシンフィルタMA0,2は図6Bに示されており、ここでは、バッファ状態は省かれている。文字列w=abbbaabでのランは図7Aに示されている。その出力文字列は⊥⊥ab⊥⊥aabであり、これはフィルタリング結果がab⊥⊥aabであることを示している。 (Example 3.6): Consider a pattern aa * b. This is illustrated in the non-deterministic finite automaton (NFA) A 0 of FIG. 6A. The Moore machine filter MA0,2 of definition 3.3 is shown in FIG. 6B, where the buffer state has been omitted. The run with the character string w = abbbaab is shown in FIG. 7A. The output character string is "ab @ aab", which indicates that the filtering result is ab @ aab.

図7Aは、文字列w=abbbaabに対するMA0,2のランを示す。図7Aにおける表はバッファの状態を表し、バッファは右から文字のデータが追加される。「上からa、矢印、bの記号」は入力文字がaであり、bが出力であることを表わす。 7A shows a run of M A0,2 for string w = abbbaab. The table in FIG. 7A shows the state of the buffer, and character data is added to the buffer from the right. "The symbol of a, arrow and b from the top" indicates that the input character is a and b is an output.

3.3 ムーアマシンフィルタMA,Nの性質
この節の残りでは、AをパターンNFA(非決定的有限オートマトン)A=(Σ,S,S,E,S)、Nを正整数、MA,N=(Σ,Σ,Q,q,Δ,Λ)を定義3.3のムーアマシンフィルタとする。w=a…aをΣ上の文字列とし、⊥w'を入力文字列w⊥に対するムーアマシンフィルタMA,Nの出力文字列とする。文字列w'=b…bとする。ただし、b∈Σである。
3.3 Properties of Moore Machine Filter M A, N In the remainder of this section, A is a pattern NFA (non-deterministic finite automaton) A = (Σ, S, S 0 , E, S F ), N is a positive integer, M A , N = (Σ , Σ , Q, q 0 , Δ, Λ) as the Moore machine filter of definition 3.3. The w = a 1 a 2 ... a n a string on sigma, ⊥ N w Moore machine filter M A for the input string W⊥ N a ', and outputs a string of N. It is assumed that a character string w ′ = b 1 b 2 ... B n . However, a b i ∈Σ ⊥.

(定理3.7)(健全性):ムーアマシンフィルタMA,Nは定義3.2の意味で健全である。マッチングの長さに上界があり、バッファサイズNがその上界以上ならば完全性が成立する。これは本質的には複数文字列マッチングと同じである。 (Theorem 3.7) (Soundness): The Moore machine filter MA , N is sound in the meaning of the definition 3.2. There is an upper bound on the length of matching, and completeness is established if the buffer size N is greater than or equal to the upper bound. This is essentially the same as multiple string matching.

(定理3.8)(完全性):max{|w|||w∈L(A)}≦N<∞を仮定する。このとき、L(A)=L(A')となる非決定的有限オートマトン(NFA)A'であって、ムーアマシンフィルタMA',Nが完全であるものを構成することができる。後半は次のことを意味する:もし添字kがa=bを満たすなら、k∈[i,j]とw|[i,j]∈L(A)となる区間[i,j]が存在する。 (Theorem 3.8) (Completeness): It is assumed that max {| w ||| w {L (A)} ≦ N <∞. In this case, a nondeterministic finite automaton (NFA) A ′ in which L (A) = L (A ′) and in which the Moore machine filter M A ′, N is complete can be configured. The second half means the following: If the subscript k satisfies a k = b k , the interval [i, j] where ki [i, j] and w | [i, j] (L (A) Exists.

単調性の直観は、バッファサイズN'を大きくすればムーアマシンフィルタMA,N'はより多くの文字をマスクするけれども、状態空間も増大するということである。正確な主張はもっと込み入っていて、より大きなバッファサイズN"というのはより小さなものの倍数でなくてはいけない。 The intuition of monotonicity is that as the buffer size N 'increases, the Moore machine filter MA , N' masks more characters, but also increases the state space. The exact claim is more complicated, and the larger buffer size N "must be a multiple of the smaller one.

(定理3.9)(単調性):任意の正実数N'について、MA,N'を定義3.3のムーアマシンフィルタとし、⊥N'w'(N')を入力文字列w⊥N'に対するムーアマシンフィルタMAN'の出力文字列とする。w'(N')=b (N') (N')…b (N')とする。ただし、b (N')∈Σである。任意の正実数n、N'とwの任意の添字kについて、b (N')=⊥ならばb (nN')=⊥である。 (Theorem 3.9) (monotonicity): For any positive real number N ′, MA , N ′ is defined as a Moore machine filter of definition 3.3, and { N ′ w ′ (N ′) is an input character string w}. the output string of 'Moore machine filter M aN for' N. It is assumed that w ′ (N ′) = b 1 (N ′) b 2 (N ′) ... b n (N ′) . Here, b i (N ′) ∈Σ . For any positive real number n, any subscript k of N ′ and w, if b k (N ′) = ⊥, then b k (nN ′) = ⊥.

命題3.5で述べたように、ムーアマシンフィルタの状態空間はAの状態空間よりも指数的に大きい。これは決定的な分岐のために必要な冪集合構成のためである。実行時間を犠牲にすることにより、非決定的有限オートマトン(NFA)を必要になり次第決定化することもでき、こうすれば普通はより少ないメモリ領域しか必要としない。   As stated in Proposition 3.5, the state space of the Moore machine filter is exponentially larger than the state space of A. This is due to the power set construction required for deterministic branching. By sacrificing execution time, nondeterministic finite automata (NFAs) can also be determined as needed, which usually requires less memory space.

4.パターンマッチングのためのムーアマシンフィルタリング2:実時間制約付き
本発明者らの主な貢献である、実時間制約付きパターンマッチングのためのムーアマシンフィルタの構成を提案する。基本的な考えは実時間制約なしの設定(3章)と同じだが、実時間制約付きオートマトン(Timed Automata;TA)は一般には決定化ができないので、決定化が技術的な課題になる。ここで、本発明者らは1クロック決定化(例えば、非特許文献2の5.3節参照)を用いる。その構成は到達可能性を過大評価するので、フィルタリングの健全性を保つことができる。しかも、結果のTAの局所的な性質(そのTAは遷移毎にリセットされる1つのクロック変数しか持たない)によって、実時間制約なしの有限状態ムーアマシンであるフィルタを作ることができる。
4. Moore Machine Filtering for Pattern Matching 2: With Real-Time Constraints We propose a configuration of a Moore machine filter for real-time constrained pattern matching, which is the main contribution of the present inventors. Although the basic idea is the same as the setting without a real-time constraint (Chapter 3), since a real-time-constrained automaton (Timed Automata; TA) cannot generally be determined, it is a technical problem. Here, the present inventors use one clock decision (for example, see section 5.3 of Non-Patent Document 2). The configuration overestimates reachability, so that filtering integrity can be maintained. Moreover, the local nature of the resulting TA, which has only one clock variable that resets at each transition, allows the creation of filters that are finite state Moore machines without real-time constraints.

4.1 問題の定式化
(定義4.1)(タイムスタンプ付き文字列):Σをアルファベットとする。アルファベットΣ上のタイムスタンプ付き文字列とは、対(a,τ)∈Σ×R>0の文字列wで、任意のi∈[1,|w|−1]についてτ<τi+1を満足するものである。
4.1 Formulation of problem (Definition 4.1) (character string with time stamp): Let Σ be an alphabet. The character string with a time stamp on the alphabet Σ is a character string w of a pair (a i , τ i ) ∈Σ × R > 0 , and τ i <τ for an arbitrary i∈ [1, | w | −1]. i + 1 is satisfied.

Figure 2020057362

をタイムスタンプ付き文字列とする。アルファベットΣ上のタイムスタンプ付き文字列の集合をT(Σ)と書く。
Figure 2020057362

Is a character string with a time stamp. A set of character strings with a time stamp on the alphabet Σ is written as T (Σ).

部分文字列(a,τ),(ai+1,τi+1),…,(a,τ)をw(i,j)と書く。t∈R≧0について、文字列wのtシフト(時間tだけをシフトする)を The partial character strings (a i , τ i ), (a i + 1 , τ i + 1 ),..., ( Aj , τ j ) are written as w (i, j). For t∈R ≧ 0 , shift t of character string w (shift only time t)

Figure 2020057362

と定める。ただし、
Figure 2020057362

Is determined. However,

Figure 2020057362

である。タイムスタンプ付き文字列
Figure 2020057362

It is. String with time stamp

Figure 2020057362

Figure 2020057362

When

Figure 2020057362

について、これらの吸収連結とは、
Figure 2020057362

With regard to these absorption consolidation,

Figure 2020057362

であり(ただし
Figure 2020057362

And (but

Figure 2020057362

Figure 2020057362

When

Figure 2020057362

はどちらも普通の連結)、これらの非吸収連結とは
Figure 2020057362

Are both ordinary consolidations), and what are these non-absorbing consolidations?

Figure 2020057362

である。吸収連結w○w'はτ|w|<τ'のときにのみ定義されることに注意する。
Figure 2020057362

It is. Absorption consolidated w ○ w 'is τ | <τ | w' note to be defined only at the time of the 1.

アルファベットΣ上のタイムスタンプ付き文字列   Character string with time stamp on alphabet Σ

Figure 2020057362

と、時刻t,t'∈R>0で、時刻t<t'を満足するものについて、タイムスタンプ付き文字列区間w|(t,t')は、拡張アルファベットΣ凵{$}上のタイムスタンプ付き文字列(w(i,j)−t)○($,t'−t)で定義される。ここで、パラメータi,jはτi−1≦t<τとτ<t'≦τj+1となるように選ばれている。ここで、タイムスタンプ付き文字列w(i,j)−tはw(i,j)の(−t)シフトであり、未使用の記号$は終端文字とよばれる。
Figure 2020057362

And at time t, t ′ {R > 0 , satisfying time t <t ′, the time-stamped character string section w | (t, t ′) is the time on the extended alphabet {u} The character string with a stamp (w (i, j) -t) is defined by (○, t'-t). Here, the parameters i and j are selected so that τ i−1 ≦ t <τ i and τ j <t ′ ≦ τ j + 1 . Here, the character string w (i, j) -t with a time stamp is a (-t) shift of w (i, j), and the unused symbol $ is called a terminal character.

(定義4.2)(実時間制約付きオートマトン):Cはクロック変数の有限集合を表し、Φ(C)は不等式 (Definition 4.2) (Real-time constrained automaton): C represents a finite set of clock variables, and Φ (C) is an inequality

Figure 2020057362

の複数の連言の集合を表わしている。
Figure 2020057362

Represents a set of a plurality of conjunctions.

ここで、x∈C,c∈Z≧0であり、 Here, x∈C, c∈Z ≧ 0 , and

Figure 2020057362

である。実時間制約付きオートマトンA=(Σ,S,s,S,C,E)は組であって、Σはアルファベット、Sは状態の有限集合、s∈Sは初期状態、S⊂Sは受理状態の集合、E⊂S×S×Σ×P(C)×Φ(C)は遷移の集合である。遷移の複数の構成要素(s,s',a,λ,δ)∈Eは、ソース、ターゲット、アクション、リセット変数、遷移のガードをそれぞれ表わしている。
Figure 2020057362

It is. A real-time constrained automaton A = (Σ, S, s 0 , S F , C, E) is a set, Σ is an alphabet, S is a finite set of states, s 0 ∈S is an initial state, S F ⊂ S is a set of acceptance states, and E⊂S × S × Σ × P (C) × Φ (C) is a set of transitions. A plurality of transition components (s, s ′, a, λ, δ) ∈E represent a source, a target, an action, a reset variable, and a transition guard, respectively.

クロック付値νを関数ν:C→R≧0として定義する。クロック付値νのtシフトν+tを(ν+t)(x)=ν(x)+tで定義する。ここで、t∈R≧0である。実時間制約付きオートマトンA=(Σ,S,s,S,C,E)とタイムスタンプ付き文字列 The value with clock ν is defined as a function ν: C → R ≧ 0 . The t shift ν + t of the clocked value ν is defined as (ν + t) (x) = ν (x) + t. Here, t∈R ≧ 0 . Real-time constrained automaton A = (Σ, S, s 0 , SF , C, E) and time-stamped character string

Figure 2020057362

について、w上のAのランとは組(s,v)∈S×(R≧0の列rであって、次の条件を満足するものである。
Figure 2020057362

, The run of A on w is a row r of the set (s i , v i ) ∈S × (R ≧ 0 ) C , which satisfies the following condition.

(初期条件)sは初期状態であり、任意のx∈Cについてν(x)=0である。 (Initial Condition) s 0 is an initial state, and ν 0 (x) = 0 for any x∈C.

(連続条件)任意のi∈[1,|w|]についてνi−1+τ−τi−1|=δとν(x)=0(x∈λは任意)となるような遷移(si−1,s,a,λ,δ)∈Eが存在し、かつν(x)=νi−1(x)+τ−τi−1(x∈λでない)。 (Continuous condition) For any i∈ [1, | w |], transitions such that ν i−1 + τ i −τ i−1 | = δ and ν i (x) = 0 (x∈λ is arbitrary) (S i−1 , s i , a i , λ, δ) εE exists, and v i (x) = v i−1 (x) + τ i −τ i−1 (where x∈λ).

ランであって連続条件のみを満たすものをパスとよぶ。ラン   A run that satisfies only the continuous condition is called a pass. run

Figure 2020057362

はsの最後の要素s|s|−1がSに属するとき受理するという。言語L(A)はタイムスタンプ付き文字列の集合{w|w上のAの受理するランが存在する}と定義される。
Figure 2020057362

Of -1 is to accept when belonging to the S F | is the last element s of s | s. The language L (A) is defined as a set of time-stamped character strings {there is a run accepted by A on w | w}.

ここで、本発明者らの目標の問題を述べる。これを解くためのアルゴリズムは活発に研究されてきており(例えば、非特許文献4,5参照)、これらのアルゴリズムのためのプリプロセッサとしてのフィルタリングムーアマシンがこの実施形態の貢献である。   Here, the problem of our goal is described. Algorithms for solving this have been actively studied (for example, see Non-Patent Documents 4 and 5), and a filtering Moore machine as a preprocessor for these algorithms is a contribution of this embodiment.

(定義4.3)(実時間制約付きパターンマッチング):Aを実時間制約付きオートマトン、wをタイムスタンプ付き文字列とし、両方とも共通のアルファベットΣ上のものであるとする。実時間制約付きパターンマッチング問題は、区間w|(t,t')が実時間制約付きオートマトン(TA)Aに受理されるような区間(t,t')を全て求めるものである。つまり、マッチング集合 (Definition 4.3) (Pattern matching with real-time constraint): Let A be an automaton with real-time constraint, w be a character string with a time stamp, and both be on the common alphabet Σ. The real-time constrained pattern matching problem is to find all the sections (t, t ') where the section w | (t, t') is accepted by the real-time constrained automaton (TA) A. That is, the matching set

Figure 2020057362

を求めるものである。
Figure 2020057362

Is what you want.

4.2 TAの1クロック決定化
フィルタの実時間制約なしでの構成(定義3.3)で材料となった3つの主なブロックのうち、カウンタとバッファはこの実時間制約付きの設定にそのまま持ってくることができる。決定化については、定義4.5の過大評価の考えを用いる。これは(例えば、非特許文献2の5.3節参照)を参考にしたものである。
4.2 Determining one clock of TA The counter and buffer of the three main blocks used in the configuration without the real-time constraint of the filter (Definition 3.3) are used for the setting with the real-time constraint. You can bring it. For overdetermination, the idea of overestimation in Definition 4.5 is used. This is based on (for example, see Section 5.3 of Non-Patent Document 2).

まずは補助的な記号から始める。   Start with auxiliary symbols.

(定義4.4)(制限ν|,結びν凵ν'):ν:C'→R≧0をクロック付値とする。νのC⊂C'への制限はν|:C→R≧0と書かれる。これは、任意のx∈Cについて(ν|)(x)=ν(x)である。 (Definition 4.4) (Limit ν | C , ν ν ′ ′): Let ν: C ′ → R ≧ 0 be the value with the clock. The restriction of ν to C⊂C ′ is written as ν | C : C → R ≧ 0 . This is (ν | C ) (x) = ν (x) for any xεC.

ν:C→R≧0とν':C'→R≧0をクロック付値とする。これらの結びν凵ν':C凵C'→R≧0を非交和C凵C'上のクロック付値として次のように定義する。 ν: C → R ≧ 0 and ν ′: C ′ → R ≧ 0 are clocked values. These knots ν′ν ′: C′C ′ → R ≧ 0 are defined as clocked values on the non-exchange C′C ′ as follows.

Figure 2020057362
Figure 2020057362

関数でxをrに写す(任意のi∈{1,…,n}について)ものは A function that maps x i to r i (for any i {1,..., N})

Figure 2020057362

と書かれる。
Figure 2020057362

Is written.

(定義4.5)(1クロック決定化):A=(Σ,S,s,S,C,E)を実時間制約付きオートマトン(Timed Automaton;TA)とし、yを未使用のクロック変数とする(言い換えると、y∈Cでない)。実時間制約付きオートマトン(TA)A'=(Σ,S',s',S',{y},E')は、以下の条件が成立するときにオートマトンAの1クロック決定化という。 (Definition 4.5) (Determining one clock): A = (Σ, S, s 0 , SF , C, E) is a real-time constrained automaton (Timed Automaton; TA), and y is an unused clock. Variable (in other words, y∈C). The real-time constrained automaton (TA) A ′ = (Σ, S ′, s 0 ′, S F ′, {y}, E ′) is called one-clock decision of the automaton A when the following conditions are satisfied. .

(1)新しい、有限の状態空間S'の任意の元 (1) Arbitrary element of new, finite state space S '

Figure 2020057362

は対(s,Z)の有限集合
Figure 2020057362

Is a finite set of pairs (s i , Z i )

Figure 2020057362

である。ここで、s∈SはAの状態であり、Z
Figure 2020057362

It is. Here, s i ∈S is the state of A, and Z i is

Figure 2020057362

の部分集合でゾーンとよばれる特殊な多角形により与えられるものである。
Figure 2020057362

And is given by a special polygon called a zone.

(2)オートマトンA'の任意の遷移 (2) Arbitrary transition of automaton A '

Figure 2020057362

について、ガードδはクロック変数yについての複数の区間の有限和集合である。さらに、それは遷移EがオートマトンAで有効かどうかを反映している。正確には、任意のu,u'∈R≧0でδを満たすものについて、
Figure 2020057362

Is a finite union of a plurality of intervals for the clock variable y. Furthermore, it reflects whether transition E is valid in automaton A. To be more precise, for any u, u ′ R ≧ 0 and satisfying δ,

Figure 2020057362

が成立している。ただし、集合
Figure 2020057362

Holds. However, the set

Figure 2020057362

Figure 2020057362

Is

Figure 2020057362

で定義される。
Figure 2020057362

Is defined by

(3)オートマトンA'の任意の遷移は唯一のクロック変数yをリセットする。つまり、全ての遷移 (3) Any transition of automaton A 'resets only one clock variable y. In other words, all transitions

Figure 2020057362

について、λ={y}である。
Figure 2020057362

Λ = {y}.

(4)オートマトンA'の任意の遷移 (4) Arbitrary transition of automaton A '

Figure 2020057362

はAの遷移を模倣する。より正確には、
Figure 2020057362

Mimics the transition of A. More precisely,

Figure 2020057362

Figure 2020057362

When

Figure 2020057362

とする。s'∈Sとν':C→R≧0(ここで、τは経過時間)が存在して、
Figure 2020057362

And s′∈S and ν ′: C → R ≧ 0 (where τ is elapsed time)

Figure 2020057362

がオートマトンAの(長さ1の)パスであると仮定する。このとき、ゾーン
Figure 2020057362

Is the path of automaton A (of length 1). At this time, the zone

Figure 2020057362

であって、
1)
Figure 2020057362

And
1)

Figure 2020057362

2)付値
Figure 2020057362

2) Price

Figure 2020057362

(これはクロック集合C凵{y}上のものである)はゾーンZ'に属する。
Figure 2020057362

(This is on the clock set C u {y}) belongs to zone Z ′.

(5)オートマトンA'は決定的である:任意の状態 (5) Automaton A 'is deterministic: arbitrary state

Figure 2020057362

、任意のクロック付値
Figure 2020057362

, Any value with clock

Figure 2020057362

、a∈Σ、経過時間を表わすτ∈R≧0について、
Figure 2020057362

, A}, and τ∈R ≧ 0 representing the elapsed time,

Figure 2020057362

からの長さ1のa,τでラベル付けされたパスは一意である。つまり、もし
Figure 2020057362

The path labeled with a, τ of length 1 from is unique. That is, if

Figure 2020057362

Figure 2020057362

When

Figure 2020057362

が両方ともオートマトンA'のパスならば、
Figure 2020057362

Are both paths of automaton A ',

Figure 2020057362

かつν'=ν"となる。(条件3のために
Figure 2020057362

And ν ′ = ν ″ (for condition 3

Figure 2020057362

となっていることに注意する。)
Figure 2020057362

Note that )

(6)オートマトンA'の初期状態s'は (6) The initial state s 0 ′ of the automaton A ′ is

Figure 2020057362

で与えられる。ここで0は全てのクロック変数を0に写す付値である。
Figure 2020057362

Given by Here, “0” is a value that maps all clock variables to “0”.

(7)状態SがS'に属するのは、s∈Sとなる (7) The state S belongs to S ′ F when s∈S F

Figure 2020057362

が存在するとき、かつそのときに限る。
Figure 2020057362

If and only if exists.

(命題4.6):A=(Σ,S,s,S,C,E)を実時間制約付きオートマトン(TA)とする。オートマトンA'=(Σ,S',s',S',{y},E')をオートマトンAの1クロック決定化とする。このとき、オートマトンA'は次の性質を満足する。 (Proposition 4.6): Let A = (Σ, S, s 0 , S F , C, E) be a real-time constrained automaton (TA). The automaton A ′ = (Σ, S ′, s 0 ′, S F ′, {y}, E ′) is defined as one clock of the automaton A. At this time, the automaton A ′ satisfies the following properties.

(シミュレーション)w∈T(Σ)をタイムスタンプ付き文字列とし、オートマトンAで状態s∈Sに到達するような文字列w上のランが存在するとする。このとき、次を満足する (Simulation) It is assumed that w∈T (Σ) is a character string with a time stamp, and a run on the character string w that reaches the state s∈S in the automaton A exists. At this time, the following is satisfied

Figure 2020057362

が存在する:(1)あるゾーンZについて
Figure 2020057362

Exists: (1) For a certain zone Z

Figure 2020057362

となる、(2)オートマトンA'で状態Sへの文字列w上のランが存在する。
Figure 2020057362

(2) There is a run on the character string w to the state S in the automaton A ′.

(言語包含)特に、L(A)⊂L(A')である。 (Language inclusion) In particular, L (A) ⊂L (A ′).

定義4.5が与えているのは性質であって構成ではないことに注意する。同じ実時間制約付きオートマトン(TA)Aについて、サイズや精度の異なる1クロック決定化は複数存在する。本発明者らの実装では例えば、非特許文献2の5.3.4項で提案されている特定の構成を用いている。   Note that definition 4.5 gives properties, not compositions. For the same real-time constrained automaton (TA) A, there are a plurality of one-clock determinants having different sizes and different precisions. In the implementation of the present inventors, for example, a specific configuration proposed in section 5.3.4 of Non-Patent Document 2 is used.

4.3 本発明者らのムーアマシンフィルタMA,Nの構成
(定義4.7)(実時間制約付きパターンマッチングのためのムーアマシンフィルタMA,N):A=(Σ,S,s,S,C,E)を実時間制約付きオートマトン(TA)とし、N∈Z>0とする。ムーアマシンフィルタMA,Nの構成は以下のステップに従って行なわれる。
4.3 Configuration of our Moore machine filter MA , N (Definition 4.7) (Moore machine filter MA , N for real-time constrained pattern matching): A = (Σ, S, s) 0 , S F , C, E) are automata (TA) with real-time constraints, and N∈Z > 0 . The configuration of the Moore machine filter MA , N is performed according to the following steps.

まずはじめのステップでは、もとの実時間制約付きオートマトン(TA)Aをカウンタで拡張する。具体的には、   In the first step, the original real-time constrained automaton (TA) A is extended by a counter. In particular,

Figure 2020057362

を次のように定義する。
Figure 2020057362

Is defined as follows.

Figure 2020057362

、そして
Figure 2020057362

And

Figure 2020057362
Figure 2020057362

2つ目のステップでは、オートマトンAN−ctrの1クロック決定化(定義4.5)を取る。 In the second step, one clock of the automaton AN-ctr is determined (definition 4.5).

Figure 2020057362

がその結果であるとする。
Figure 2020057362

Is the result.

最後に3つ目のステップでムーアマシンフィルタMA,Nを次式のように定義する。 Finally, in the third step, the Moore machine filter MA , N is defined as in the following equation.

Figure 2020057362
Figure 2020057362

ただし、ΔとΛは次のように定義される。   Here, Δ and Λ are defined as follows.

Figure 2020057362

、ただし、状態S'はオートマトンAN−ctr−dでの状態Sの、文字aと経過時間τのもとでの一意な後続であり(定義4.5)、
Figure 2020057362

Where state S ′ is a unique succession of state S in automaton AN-ctr-d under letter a and elapsed time τ (definition 4.5),

Figure 2020057362

は次式のように定義される。
Figure 2020057362

Is defined as:

Figure 2020057362
Figure 2020057362

ここで、   here,

Figure 2020057362

である。
Figure 2020057362

It is.

Figure 2020057362

と定義する。
Figure 2020057362

Is defined.

図7Bは実施形態に係る前置情報処理回路の処理回路の一例を示すブロックである。図7Bにおいて、当該処理回路は、フィルタ部11と、マスキング適用部12とを備えて構成される。   FIG. 7B is a block diagram illustrating an example of a processing circuit of the prefix information processing circuit according to the embodiment. 7B, the processing circuit includes a filter unit 11 and a masking application unit 12.

得られるムーアマシンは入力としてタイムスタンプ付き文字列を取ることに注意する。これによって、入力アルファベットは無限になってしまう(つまり、Σ×R≧0)。これは実装上大きな問題にはならない。というのは、状態空間は有限のままだからである。しかも、ムーアマシンフィルタMA,N(図7Bのフィルタ部11)の出力アルファベットは2元集合{pass,mask}であり、ムーアマシンフィルタのオートマトンはマスクの情報しか出力しない。有限状態ムーアマシンでは確かに実時間制約付き複数の文字をバッファしておくことはできないが、もとのタイムスタンプ付き文字列をコピーしておいて、あとで適当なマスキングをマスキング適用部12により適用することはできる(図7B参照)。 Note that the resulting Moore machine takes a time-stamped string as input. As a result, the input alphabet becomes infinite (that is, Σ × R ≧ 0 ). This is not a major implementation problem. Because the state space remains finite. In addition, the output alphabet of the Moore machine filter M A, N (the filter unit 11 in FIG. 7B) is a binary set {pass, mask}, and the automaton of the Moore machine filter outputs only the mask information. Although the finite state Moore machine cannot certainly buffer a plurality of characters with real time constraints, the original time stamped character string is copied, and appropriate masking is performed by the masking application unit 12 later. Applicable (see FIG. 7B).

(定理4.8)(健全性):オートマトンAをパターンTA A=(Σ,S,s,S,C,E)とし、Nを正整数とし、MA,Nを定義4.7のムーアマシンフィルタとする。w=(a,τ)(a,τ)…(a,τ)をΣ上のタイムスタンプ付き文字列とし、maskw'を入力文字列w(⊥,τに対するムーアマシンフィルタMA,Nの出力文字列とする(ここで、入出力文字列はmaskと(⊥,τが図4のように付け足されているとする)。文字列w'=b…bとする。ここで、b∈{pass,mask}である。 (Theorem 4.8) (Soundness): Let automaton A be a pattern TA A = (Σ, S, s 0 , S F , C, E), define N as a positive integer, and define MA , N 4.7. Moore machine filter. w = (a 1 , τ 1 ) (a 2 , τ 2 )... (a n , τ n ) is a character string with a time stamp on Σ, and mask N w ′ is an input character string w (⊥, τ n ). It is assumed that the output character string of the Moore machine filter M A, N for N (here, the input / output character strings are mask N and (⊥, τ n ) N added as shown in FIG. 4). It is assumed that a character string w ′ = b 1 b 2 ... B n . Here, b k {pass, mask}.

任意の文字列wの添字の対(i,j)でw(i,j)−τi−1∈L(A)を満足するものと、文字列wの添字k∈[i,j]について、b=passとなる。 A pair of subscripts (i, j) of an arbitrary character string w that satisfies w (i, j) −τ i−1 ∈L (A) and a subscript k∈ [i, j] of a character string w , B k = pass.

5.実施例1(実装と実験)
本発明者らは実時間制約付きパターンマッチングのためのムーアマシンフィルタの構成を実装した(実施例1)。本発明者らの実装は連続する⊥を2つの⊥でつぶし、はじめと最後の⊥のタイムスタンプを保つようになっている。状態空間Qのバッファ部分は必要になり次第生成するようになっており(定義4.7の{pass,mask})、これは命題3.5で述べた通りである。本発明者らは次の研究の疑問(RQ)に答えるための実験を行なった。
5. Example 1 (implementation and experiment)
The present inventors have implemented a configuration of a Moore machine filter for pattern matching with real-time constraints (Example 1). Our implementation collapses successive ⊥ with two ⊥ and keeps the timestamp of the first and last ⊥. The buffer portion of the state space Q is generated as needed ({pass, mask} N in definition 4.7), which is as described in Proposition 3.5. The present inventors conducted experiments to answer the following research questions (RQ).

RQ1:本発明者らのムーアマシンフィルタは沢山のイベントをマスクするか?
RQ2:本発明者らのムーアマシンフィルタはオンラインで動作するか?
つまり、入力のタイムスタンプ付き文字列の長さに対して線形時間と定数空間で動作するか?
RQ3:本発明者らのムーアマシンは実時間制約付きパターンマッチングのタスク全体を加速するか?
RQ4:本発明者らのフィルタは高精度か?
つまり、マスクされなかったイベントの多くが実際のマッチングに寄与するか?
RQ5:本発明者らのフィルタの反応は早いか?
つまり、大きな遅れが生じはしないか?
RQ1: Do Our Moore Machine Filters Mask Many Events?
RQ2: Do Our Moore Machine Filters Work Online?
That is, does it work in linear time and constant space for the length of the input time-stamped string?
RQ3: Can our Moore Machines Accelerate the Real-Time Constrained Pattern Matching Task?
RQ4: Are our filters highly accurate?
In other words, do many of the unmasked events contribute to the actual matching?
RQ5: Is the response of our filter fast?
In other words, will there be a big delay?

フィルタ構成の実装はC++言語で行い、clang−900.0.39.2でコンパイルした。ツールの入力はパターンTA AとバッファサイズN、そしてタイムスタンプ付き文字列wからなり、フィルタされた文字列を出力する。実験はパーソナルコンピュータ(MacBook Pro Early 2013 with 2.6 GHz Intel Core i5 processor and 8GB 1600MHz DDR)のRAM上のMac OS 10.13.4で行なった。用いたベンチマーク問題は図8〜図10にある。これらは全て自動車のシナリオから取られたものである。   The implementation of the filter configuration was performed in C ++ language and compiled with clag-900.0.39.2. The input of the tool includes a pattern TA A, a buffer size N, and a character string w with a time stamp, and outputs a filtered character string. The experiment was performed with Mac OS 10.13.4 on RAM of a personal computer (MacBook Pro Early 2013 with 2.6 GHz Intel Core i5 processor and 8GB 1600 MHz DDR). The benchmark problems used are in FIGS. These are all taken from the car scenario.

図8は実施例1に係る自動車のトルクセンサのデータのためのムーアマシンフィルタの一例を示す図である。   FIG. 8 is a diagram illustrating an example of a Moore machine filter for data of a vehicle torque sensor according to the first embodiment.

図8において、入力文字列の集合W(長さは242,808から4,873,207)はランダムな入力により自動車エンジンのモデルであるsldemo_enginewc.slxから生成された。このパターンは1秒以内にhighの発生が4回以上あることを記述している。バッファサイズN=10については、ムーアマシンフィルタMA,10のサイズ(SN−ctr−dの非バッファ部分の到達可能状態の数ではかった)は16であった。 In FIG. 8, a set W of input character strings (having a length of 242,808 to 4,873,207) is a sledmo_enginenewc. Generated from slx. This pattern describes that high occurs four or more times within one second. With respect to the buffer size N = 10, the size of the Moore machine filter MA , 10 (measured by the number of reachable states of the non-buffer part of SN-ctr-d) was 16.

図9は実施例1に係る自動車のギアセンサのデータのためのムーアマシンフィルタの一例を示す図である。   FIG. 9 is a diagram illustrating an example of the Moore machine filter for the data of the gear sensor of the vehicle according to the first embodiment.

図9において、入力文字列の集合W(長さは306から1,011,426)は自動変速装置のモデルから生成された。当該モデルのφAT5から取ったこのパターンは、ギアシフトを(1速から2速に)過度に頻繁に行なうというイベントを表している。バッファサイズN=10のとき、図8と同じ方法でムーアマシンフィルタMA,10のサイズを測定すると、3であった。 In FIG. 9, a set W of input character strings (having a length of 306 to 1,011,426) was generated from a model of the automatic transmission. This pattern taken from the model φAT5 represents an event that gearshifts occur too frequently (from first gear to second gear). When the buffer size N = 10, the size of the Moore machine filter MA , 10 was measured by the same method as in FIG.

図10は実施例1に係る自動車のアクセルセンサのデータのためのムーアマシンフィルタの一例を示す図である。   FIG. 10 is a diagram illustrating an example of the Moore machine filter for the data of the accelerator sensor of the vehicle according to the first embodiment.

図10において、入力文字列の集合W(長さは708から1,739,535)はギアと同じモデルで生成された。パターンはφAT8と同じである:ギアは1速から4速までシフトし、RPMも高くなるが、速度は低い(言い換えると、v≧100というイベントがおこらない)。バッファサイズN=10について、ムーアマシンフィルタMA,10のサイズを図8と同じ方法で測定すると、71であった。 In FIG. 10, a set W of input character strings (having a length of 708 to 1,739,535) was generated using the same model as the gear. The pattern is the same as φAT8: the gear shifts from 1st to 4th and the RPM is higher but the speed is lower (in other words, the event v ≧ 100 does not occur). For the buffer size N = 10, the size of the Moore machine filter MA , 10 was measured by the same method as in FIG.

実行時間とメモリ使用量の計測のために、本発明者らはGNUのtimeを用い、20回の実行の平均を取った。それぞれの実験で、本発明者らはワークフロー全体を計測した。RQ2では、フィルタの構成を含めた時間とメモリ使用を、RQ3ではフィルタの構成、フィルタリング、プロセス間通信とパターンマッチングの時間とメモリ使用量を計測している。RQ3の実験では、実時間制約付きパターンマッチングのための最新のツールであるMONAAを使用した。   For the measurement of execution time and memory usage, we averaged 20 runs using GNU time. In each experiment we measured the entire workflow. RQ2 measures the time and memory usage including the configuration of the filter, and RQ3 measures the time and memory usage of the filter configuration, filtering, inter-process communication and pattern matching. The RQ3 experiment used MONAA, the latest tool for real-time constrained pattern matching.

RQ1:フィルタリング率 RQ1: Filtering rate

図11Aは実施例1に係る自動車のトルクセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するフィルタされた実時間付き文字列長を示すグラフである。図11Bは実施例1に係る自動車のギアセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するフィルタされた実時間付き文字列長を示すグラフである。図11Cは実施例1に係る自動車のアクセルセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するフィルタされた実時間付き文字列長を示すグラフである。すなわち、図11A〜図11Cはそれぞれの実時間制約付きオートマトンA、バッファサイズN、タイムスタンプ付き文字列w∈Wについてのフィルタされたタイムスタンプ付き文字列長を示している。   FIG. 11A is a graph showing a simulation result of a Moore machine filter with respect to the data of the torque sensor of the vehicle according to the first embodiment, showing a filtered character string length with a real time with respect to an input character string length with a real time. FIG. 11B is a graph showing a simulation result of the Moore machine filter with respect to the data of the gear sensor of the vehicle according to the first embodiment, and showing the filtered real-time character string length with respect to the input real-time character string length. FIG. 11C is a graph showing a simulation result of a Moore machine filter with respect to the data of the accelerator sensor of the vehicle according to the first embodiment, showing a filtered real-time character string length with respect to an input real-time character string length. 11A to 11C show the filtered time-stamped character string lengths of the real-time-constrained automaton A, the buffer size N, and the time-stamped character string w∈W, respectively.

図11A〜図11Cから明らかなように、バッファサイズNが大きくなるほどフィルタされた文字列は短くなることがわかる。このことは、(その結果は実時間制約なしの設定だったものの)定理3.9での理論的な考察と符合する。ピーク性能は、バッファサイズN=10といった割合小さいNで実現されているように見える。バッファサイズN=10のときには、トルク、ギア、アクセルでのもとのタイムスタンプ付き文字列の長さはそれぞれ1/3,1/2,1/100程度になっている。アクセルについては、本発明者らのフィルタは多くの文字をフィルタしている。これは、アルファベットのサイズとパターン実時間制約付きオートマトンのサイズが比較的大きいためである。この劇的なデータの削減は本発明者らのフィルタリング手法が組み込みのシナリオで実用できることを示している(図1参照)。   As is clear from FIGS. 11A to 11C, it can be seen that the larger the buffer size N, the shorter the filtered character string. This is consistent with the theoretical considerations in Theorem 3.9 (although the result was a setting without real-time constraints). Peak performance appears to be realized at a relatively small N, such as buffer size N = 10. When the buffer size N = 10, the lengths of the original character strings with time stamps in torque, gear, and accelerator are about 1/3, 1/2, and 1/100, respectively. For the accelerator, our filter filters many characters. This is because the size of the alphabet and the size of the automaton with pattern real-time constraints are relatively large. This dramatic data reduction indicates that our filtering approach can be used in embedded scenarios (see FIG. 1).

RQ2:速度とメモリ使用量 RQ2: Speed and memory usage

図12Aは実施例1に係る自動車のトルクセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。図12Bは実施例1に係る自動車のギアセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。図12Cは実施例1に係る自動車のアクセルセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。   FIG. 12A is a graph showing a simulation result of a Moore machine filter with respect to data of the vehicle torque sensor according to the first embodiment, and showing execution time with respect to an input character string length with real time. FIG. 12B is a graph showing a simulation result of the Moore machine filter with respect to the data of the gear sensor of the vehicle according to the first embodiment, and showing the execution time with respect to the input character string length with real time. FIG. 12C is a graph showing a simulation result of the Moore machine filter with respect to the data of the accelerator sensor of the vehicle according to the first embodiment, and showing the execution time with respect to the input character string length with real time.

図13Aは実施例1に係る自動車のトルクセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するメモリ使用量を示すグラフである。図13Bは実施例1に係る自動車のギアセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するメモリ使用量を示すグラフである。図13Cは実施例1に係る自動車のアクセルセンサのデータに対するムーアマシンフィルタのシミュレーション結果であって、入力された実時間付き文字列長に対するメモリ使用量を示すグラフである。   FIG. 13A is a graph showing a simulation result of the Moore machine filter with respect to the data of the torque sensor of the vehicle according to the first embodiment, and showing the memory usage with respect to the input character string length with real time. FIG. 13B is a graph showing a simulation result of the Moore machine filter with respect to the data of the gear sensor of the vehicle according to the first embodiment, and showing the memory usage with respect to the input character string length with real time. FIG. 13C is a graph showing a simulation result of a Moore machine filter with respect to the data of the accelerator sensor of the vehicle according to the first embodiment, showing a memory usage amount with respect to an input real-time character string length.

すなわち、図12と図13はそれぞれのパターン実時間制約付きオートマトンA、バッファサイズN、タイムスタンプ付き文字列w∈Wについての、本発明者らのムーアマシンフィルタの実行時間とメモリ使用量を示している。   That is, FIGS. 12 and 13 show the execution time and the memory usage of the Moore machine filter of the present inventors for the automaton A with the pattern real time constraint, the buffer size N, and the character string w∈W with the time stamp. ing.

図12では、実行時間は入力文字列に対して線形であることがわかる。図13では、メモリ使用量は入力文字列の長さに対して大体定数であることがわかる。これら2つの結果は、本発明者らのフィルタリング手法がオンラインで利用できることを示唆している。   In FIG. 12, it can be seen that the execution time is linear with respect to the input character string. In FIG. 13, it can be seen that the memory usage is approximately a constant with respect to the length of the input character string. These two results suggest that our filtering approach is available online.

ムーアマシンフィルタの構成にかかる時間は無視できると考えられる。ここで図12の短い入力文字列に対する実行時間を参照せよ。   The time required to configure the Moore machine filter is considered negligible. Here, refer to the execution time for a short input character string in FIG.

バッファサイズNを様々に変化させることの影響については、小さなバッファサイズNについて実行時間は比較的大きくなっていることがわかる。これはより少ない文字がマスクされ、より多くの文字が出力され、そのことが入出力装置(I/O)のコストを悪化させたためだと考えられる。メモリ使用量については、命題3.5での最悪の場合の結果(Nについて指数的)に反して、大きなバッファサイズNに対する増大は穏やかであった。これは冪集合構成の全ての状態に到達可能なわけではないためである。   Regarding the effect of changing the buffer size N variously, it can be seen that the execution time is relatively long for the small buffer size N. This is probably because fewer characters were masked and more characters were output, which worsened the cost of the input / output device (I / O). For memory usage, contrary to the worst case result in Proposition 3.5 (exponential for N), the increase for large buffer sizes N was modest. This is because not all states of the power set configuration can be reached.

RQ3:実時間制約付きパターンマッチングの加速 RQ3: Acceleration of real-time constrained pattern matching

図14Aは自動車のトルクセンサのデータに対する、比較例に係るツールのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。図14Bは自動車のギアセンサのデータに対する、比較例に係るツールのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。図14Cは自動車のアクセルセンサのデータに対する、比較例に係るツールのシミュレーション結果であって、入力された実時間付き文字列長に対する実行時間を示すグラフである。   FIG. 14A is a graph showing a simulation result of a tool according to a comparative example with respect to data of a vehicle torque sensor, and showing execution time with respect to an input character string length with real time. FIG. 14B is a graph showing simulation results of a tool according to a comparative example with respect to data of a gear sensor of an automobile, and showing execution time with respect to an input character string length with real time. FIG. 14C is a graph showing simulation results of a tool according to a comparative example with respect to data of an accelerator sensor of a vehicle, and showing execution time with respect to an input character string length with real time.

すなわち、図14は図2のワークフローの実行時間を示している。ここで、フィルタは本発明者らのアルゴリズムで与えられ、パターンマッチングは最新のツールMONAAで行なわれている。より具体的には、ムーアマシンフィルタの標準出力をMONAAの標準入力にUnixのパイプラインで接続している。このようにすることで、フィルタとMONAAは異なるコアで並列に実行される。   That is, FIG. 14 shows the execution time of the workflow of FIG. Here, the filter is given by the algorithm of the present inventors, and the pattern matching is performed by the latest tool MONAA. More specifically, the standard output of the Moore machine filter is connected to the standard input of the MONAA via a Unix pipeline. In this way, the filter and the MONAA are executed in parallel on different cores.

バッファサイズNが十分大きければ(例えばN=10)、フィルタリングによって実時間制約付きパターンマッチングの全体の性能は向上することがわかった。トルクとギアについては1.2倍高速化され、アクセルについてはおおよそ2倍高速化された。この加速は本発明者らのフィルタリング手法が図1に示された構成の仮定とは独立に有益かもしれないということを示唆している。ログが膨大でモニタリングが何時間、あるいは何日もかかってしまうときに、フィルタと並列に実行することによって時間が削減できるかもしれない。   It has been found that if the buffer size N is sufficiently large (for example, N = 10), the overall performance of real-time constrained pattern matching is improved by filtering. The torque and gear are up 1.2 times faster, and the accelerator about 2 times faster. This acceleration suggests that our filtering approach may be useful independently of the configuration assumptions shown in FIG. If the log is huge and monitoring can take hours or even days, running it in parallel with a filter might save time.

RQ4:精度 RQ4: Accuracy

3つの例トルク、ギア、アクセルと、バッファサイズN=10について、マスクされなかったイベントで実際のマッチングに貢献したものの比はそれぞれ、0.34%、99%、92%であった。従って、正確性はパターンによって劇的に異なることがわかる。精度の低い例(トルク)であっても、本発明者らのフィルタは確かにログのサイズをおおよそ3倍削減していることには注意されたい(図11A〜図11C)。   For the three example torques, gears, accelerators, and buffer size N = 10, the ratios of those that contributed to the actual matching in the unmasked event were 0.34%, 99%, and 92%, respectively. Therefore, it can be seen that the accuracy varies dramatically depending on the pattern. Note that even in the less accurate example (torque), our filter does reduce the log size by a factor of approximately three (FIGS. 11A-11C).

この実時間制約付きの設定での正確性のなさのほとんどは1クロック決定化(定義4.5)のゆるさに起因する。例えば、トルクの実時間制約付きオートマトン(TA)(図8)は同じクロックxを使った1秒以内の4回連続のhighの発生を要求している。この1クロック決定化による最良の過大評価(遷移毎にすべての時計をリセットしなくてはいけない)は、長さ1以下の連続した4つの区間のそれぞれにhighが表われるという要求である。これは元の要求よりもかなり緩くなっており、トルクの例で比較的低精度になったことを説明している。   Most of the inaccuracy in this real-time constrained setting is due to the looseness of one clock determinism (definition 4.5). For example, an automaton (TA) with real-time constraints on torque (FIG. 8) requires the generation of four consecutive highs within one second using the same clock x. The best overestimation by this one-clock decision (all clocks must be reset at each transition) is a requirement that high appear in each of four consecutive sections of length 1 or less. This is much less strict than the original requirement, explaining the relatively low accuracy in the torque example.

RQ5:反応性 RQ5: Reactivity

3つの例トルク、ギア、アクセルとバッファサイズN=10について、本発明者らのフィルタによる平均の遅延(実行時間)/|w|×Nを計算した。結果はそれぞれ2.2マイクロ秒、3.1マイクロ秒、0.91マイクロ秒であった。これらの遅延はプロセッサの計算能力に大きく依存するとはいえ、これらの遅延は小さいフィルタは十分高速に動作すると結論する。   The average delay (execution time) / | w | * N by our filter was calculated for three examples of torque, gear, accelerator and buffer size N = 10. The results were 2.2 microseconds, 3.1 microseconds, and 0.91 microsecond, respectively. Although these delays are highly dependent on the computational power of the processor, we conclude that filters with small delays operate fast enough.

6.関連研究
パターンマッチングの効率性はデータベースやネットワークの分野で活発に研究されてきた。これらの分野での、ハードウェア構成の問題(L1/L2キャッシュとメインメモリの間の速度の差)は本発明者らがこれまで議論してきた組み込みモニタ問題と類似している。
6. Related research The efficiency of pattern matching has been actively studied in the fields of databases and networks. In these areas, hardware configuration issues (speed differences between L1 / L2 cache and main memory) are similar to the embedded monitor problem we have discussed so far.

これらの適用領域での研究は(複数かもしれない)文字列をパターンとして扱ってきた。ここで主な発想の源となってきたのは、Boyer−Moore、Commentz−Walter、Aho−Corasickといった古典的なアルゴリズムである。文字列の代わりに正規表現やオートマトンで与えられるパターンに対するアルゴリズムの多くはこれらの文字列マッチングの技法に依っている。   Research in these areas of application has treated strings (or strings) as patterns. Here, the main source of the idea is a classic algorithm such as Boyer-Moore, Commentz-Walter, or Aho-Corasick. Many algorithms for patterns given by regular expressions or automata instead of strings rely on these string matching techniques.

データベースとネットワークにおいて、正規表現に対するパターンマッチングは主にマシン構成を考慮に入れた応用特化のヒューリスティクスにより行なわれてきた。   In databases and networks, pattern matching for regular expressions has been performed mainly by application-specific heuristics that take machine configuration into account.

実際のパターンマッチングの前の前置フィルタリングは上記の研究で考えられてきた(例えば、非特許文献3参照)。これらの研究と本発明者らの研究との主な違いは、彼らのフィルタはマッチング候補、すなわちマッチングするかもしれないものの添字を明示的に含んでいる点にある。このために、ワークフロー(本発明者らのよぶところのパターンマッチング)の2ステップ目は彼らの実施形態では検査とよばれている。これに対して、本発明者らのフィルタは入力文字列をマスクするだけである。これは本発明者らの(組み込みアプリケーションを見据えた)目的がマッチングの高速化だけでなく、センサからパターンマッチングの装置に送られるデータの量を削減することにもあるからである。この選択によってムーアマシンが使えるようになり、さらに、FPGA(Field Programmable Gate Array)又はASIC(Application Specific Integrated Circuits)によって容易に実装できるようになった。   Pre-filtering before actual pattern matching has been considered in the above study (see, for example, Non-Patent Document 3). The main difference between these studies and ours is that their filters explicitly include matching candidates, ie, the subscripts of what may be matched. For this reason, the second step in the workflow (pattern matching, as we call it) is called inspection in their embodiment. In contrast, our filter only masks input strings. This is because the purpose of the present inventors (in view of an embedded application) is not only to speed up the matching but also to reduce the amount of data sent from the sensor to the pattern matching apparatus. This choice allows the use of a Moore machine, and further facilitates implementation by a Field Programmable Gate Array (FPGA) or Application Specific Integrated Circuits (ASIC).

実時間時相論理や実時間制約付きパターンマッチング(例えば、非特許文献4参照)に対するモニタリングは比較的新しい話題である。このような研究は主に物理情報システムの文脈で研究されてきたが、データベースやネットワークへの応用の見込みも十分にある。実時間制約付きパターンマッチングでは、仕様は(この研究で用いた)実時間制約付きオートマトン、実時間制約付き正規表現や距離つき時相論理式で記述することができる。これらの定式化での仕様の実時間制約付きパターンマッチングのアルゴリズムは例えば、非特許文献1等で活発に研究されてきた。加えて、Boyer−MooreやFranek−Jennings−Smythのようなシフト表の技法と実時間制約付きオートマトン(例えば、非特許文献5参照)を組み合わせることにより実時間制約付きパターンマッチングを加速するものである。   Monitoring of real-time temporal logic and pattern matching with real-time constraints (for example, see Non-Patent Document 4) is a relatively new topic. Although such research has mainly been studied in the context of physical information systems, it has good prospects for application to databases and networks. In real-time constrained pattern matching, specifications can be described in real-time constrained automata (used in this study), real-time constrained regular expressions, and temporal Boolean expressions with distance. Algorithms for real-time constrained pattern matching of specifications in these formulations have been actively studied, for example, in Non-Patent Document 1. In addition, real-time constrained pattern matching is accelerated by combining a shift table technique such as Boyer-Moore or Frank-Jennings-Smyth with a real-time constrained automaton (for example, see Non-Patent Document 5). .

7.結論
近年の組み込みアプリケーションでのモニタリングの需要の高まりを受けて、本発明者らは(実時間制約なし、実時間制約付き)パターンマッチングのためのフィルタリングムーアマシンの構成を提案した。その構成はオートマトン理論的であり、ムーアマシンとしてフィルタを実現するものである。
7. Conclusion In response to the growing demand for monitoring in embedded applications in recent years, the present inventors have proposed a configuration of a filtering Moore machine for pattern matching (without real-time constraints and with real-time constraints). Its configuration is automaton theoretical, and realizes a filter as a Moore machine.

図15は実施例2に係る前置情報処理回路4の構成例を示すブロック図である。図15において、前置情報処理回路4はムーアマシンフィルタの機能を有するプロセッサ回路であって、CPU20と、ROM21と、RAM22と、操作部23と、表示部24と、入力インターフェース25と、出力インターフェース26とがバス27を介して接続され構成される。   FIG. 15 is a block diagram illustrating a configuration example of the prefix information processing circuit 4 according to the second embodiment. In FIG. 15, a pre-information processing circuit 4 is a processor circuit having a function of a Moore machine filter, and includes a CPU 20, a ROM 21, a RAM 22, an operation unit 23, a display unit 24, an input interface 25, and an output interface. 26 are connected via a bus 27.

図15において、CPU20はムーアマシンフィルタの処理を制御しながら実行するプロセッサである。ROM21は前置情報処理回路4を動作させるために必要なプログラム及びデータを格納する。RAM22はムーアマシンフィルタの処理(フィルタリング処理)を実行するときに用いるメモリ領域であって、例えばFIFOメモリであるバッファ部22a、及び非バッファ部22bが設けられている。なお、バッファ部22aは「バッファ22a」と呼ばれることもあり、非バッファ部22bは「非バッファ22b」と呼ばれることもある。またRAM22には、CPU20が実行する各種プログラム(生成プログラム22p1、メインプログラム22p2、サブプログラム22p3)がROM21からロードされる。これらのプログラムの詳細は後述する。入力インターフェース25は、入力されるシーケンスデータを受信して所定のデータ形式に変換した後、CPU20等に出力する。出力インターフェース26はCPU20によるムーアマシンフィルタの処理結果のシーケンスデータを所定のデータ形式に変換した後、外部回路又は外部回線に出力する。操作部23は例えばキーボード、マウスなどを含み、実行、停止、必要なデータの入力のために用いる。   In FIG. 15, a CPU 20 is a processor that executes while controlling the processing of the Moore machine filter. The ROM 21 stores programs and data necessary for operating the front information processing circuit 4. The RAM 22 is a memory area used when executing the processing of the Moore machine filter (filtering processing), and is provided with a buffer unit 22a and a non-buffer unit 22b which are, for example, FIFO memories. Note that the buffer unit 22a may be referred to as a “buffer 22a”, and the non-buffer unit 22b may be referred to as a “non-buffer 22b”. Various programs (the generation program 22p1, the main program 22p2, and the subprogram 22p3) executed by the CPU 20 are loaded from the ROM 21 into the RAM 22. Details of these programs will be described later. The input interface 25 receives the input sequence data, converts the data into a predetermined data format, and outputs the data to the CPU 20 or the like. The output interface 26 converts the sequence data resulting from the processing of the Moore machine filter by the CPU 20 into a predetermined data format, and outputs the data to an external circuit or an external line. The operation unit 23 includes, for example, a keyboard and a mouse, and is used for executing, stopping, and inputting necessary data.

操作部23はまた、入力されるシーケンスデータの中から検索したいパターンの条件(マッチング条件と呼ぶ)を前置情報処理回路4に入力するために用いられる。マッチング条件は、文字列や正規表現の形式で入力されるとよい。あるいは、オートマトンとして前置情報処理回路4に与えられてもよい。また別の実施形態として、マッチング条件は、シーケンスデータとともに、入力インターフェース25を介して(たとえば外部の装置から)入力されてもよい。表示部24は例えば液晶ディスプレイであって、入力されるシーケンスデータ、出力されるシーケンスデータ等を表示する。   The operation unit 23 is also used to input a condition (referred to as a matching condition) of a pattern to be searched from the input sequence data to the pre-information processing circuit 4. The matching condition may be input in the form of a character string or a regular expression. Alternatively, it may be provided to the pre-information processing circuit 4 as an automaton. In another embodiment, the matching condition may be input via the input interface 25 (for example, from an external device) together with the sequence data. The display unit 24 is, for example, a liquid crystal display, and displays input sequence data, output sequence data, and the like.

図16に、バッファ部22aの構成例を示す。バッファ部22aは、前置情報処理回路4で動作する有限状態機械(具体的にはムーアマシン)の構成要素の一つである。詳細は後述するが、前置情報処理回路4で動作するムーアマシンは、本明細書の3.2節で説明したムーアマシンのように、状態空間をバッファ部分と非バッファ部分に分けて定義する。バッファ部22aは、状態空間のバッファ部分に相当する。   FIG. 16 shows a configuration example of the buffer unit 22a. The buffer unit 22a is one of the components of a finite state machine (specifically, a Moore machine) operated by the pre-information processing circuit 4. Although the details will be described later, the Moore machine operating on the pre-information processing circuit 4 defines the state space by dividing the state space into a buffer portion and a non-buffer portion, like the Moore machine described in section 3.2 of this specification. . The buffer unit 22a corresponds to a buffer part of the state space.

バッファ部22aはN個のメモリブロック(22a−1,22a−2,...22a−N)を有するFIFOバッファである。各メモリブロック(22a−1,22a−2,...22a−N)はそれぞれ、入力されるシーケンスデータの一単位分のデータを格納するデータ領域と、フラグ領域を有する。図16において、行221aがデータ領域を表し、行221bがフラグ領域を表す。各データ領域は、シーケンスデータの一単位分のデータと同じサイズ(あるいはそれより大きいサイズ)の記憶領域である。たとえばシーケンスデータが文字列で、文字列を構成する各文字は1バイトキャラクターで、シーケンスデータが1文字ずつ(1バイトずつ)前置情報処理回路4に入力される場合、データ領域の大きさは1バイトでよい。   The buffer unit 22a is a FIFO buffer having N memory blocks (22a-1, 22a-2,..., 22a-N). Each of the memory blocks (22a-1, 22a-2,..., 22a-N) has a data area for storing one unit of input sequence data and a flag area. In FIG. 16, a row 221a represents a data area, and a row 221b represents a flag area. Each data area is a storage area of the same size (or larger size) as one unit of sequence data. For example, when the sequence data is a character string, each character constituting the character string is a one-byte character, and when the sequence data is input one character at a time (one byte at a time) to the front information processing circuit 4, the size of the data area is One byte is sufficient.

各フラグ領域は一例として、1ビットの記憶領域で、0(mask)または1(pass)が格納される。以下では、フラグ領域に格納されるデータ(0または1)のことを「フラグ」と呼ぶ。またフラグ領域に格納される値0のことを"mask"と表記し、フラグ領域に格納される値1は"pass"と表記する。   For example, each flag area is a 1-bit storage area in which 0 (mask) or 1 (pass) is stored. Hereinafter, data (0 or 1) stored in the flag area is referred to as “flag”. The value 0 stored in the flag area is described as “mask”, and the value 1 stored in the flag area is described as “pass”.

なお、実施例2に係る前置情報処理回路4では、バッファ部22aにシーケンスデータを入力する際、データは一番右のメモリブロック(22a−1)に格納される。メモリブロック(22a−1)にデータが格納される前に、一番左のメモリブロック(22a−N)のデータ(及びフラグ)はバッファ部22aから出力され、残りのメモリブロック(22a−1,22a−2,...22a−(N−1))のデータ及びフラグはそれぞれ、左隣のメモリブロック(22a−2,22a−3,...22a−N)に移される。以下の説明では、一番右のメモリブロック(22a−1)を「バッファ部22aの先頭」と呼び、一番左のメモリブロック(22a−N)を「バッファ部22aの末尾」と呼ぶ。   In the pre-information processing circuit 4 according to the second embodiment, when the sequence data is input to the buffer unit 22a, the data is stored in the rightmost memory block (22a-1). Before the data is stored in the memory block (22a-1), the data (and the flag) of the leftmost memory block (22a-N) is output from the buffer unit 22a, and the remaining memory blocks (22a-1, .. 22a- (N-1)) are respectively moved to the memory blocks (22a-2, 22a-3,... 22a-N) on the left. In the following description, the rightmost memory block (22a-1) is referred to as "the head of the buffer unit 22a", and the leftmost memory block (22a-N) is referred to as "the end of the buffer unit 22a".

なお、ここでは、各メモリブロック(22a−1,22a−2,...22a−N)がデータ領域とフラグ領域を有する例を説明したが、データ領域は無くてもよい。たとえば本明細書の4.3節で説明した定義に従うムーアマシンでは、4.3節に記載されているように、状態空間のバッファ部分には、データ(入力されるシーケンスデータ)は格納されずフラグのみが格納される。そのため、たとえば前置情報処理回路4で動作するムーアマシンが、本明細書の4.3節で説明した定義に従うムーアマシンである場合、バッファ部22aにデータ領域は不要である。   Here, an example in which each memory block (22a-1, 22a-2,... 22a-N) has a data area and a flag area has been described, but the data area may not be provided. For example, in the Moore machine according to the definition described in section 4.3 of this specification, as described in section 4.3, data (input sequence data) is not stored in the buffer portion of the state space. Only flags are stored. Therefore, for example, if the Moore machine that operates on the pre-information processing circuit 4 is a Moore machine that conforms to the definition described in section 4.3 of this specification, the buffer area 22a does not need a data area.

続いて、実施例2に係る前置情報処理回路4で動作するムーアマシンの例を説明する。ここでは主に、前置情報処理回路4は入力されるシーケンスデータとしてタイムスタンプの付与されていない文字列を受け取り、受け取った文字列のフィルタリングを行うムーアマシンを生成するケースを説明する。この場合、前置情報処理回路4で動作するムーアマシンは、本明細書の3.2節で説明したものと同様のものになる。   Next, an example of a Moore machine that operates on the pre-information processing circuit 4 according to the second embodiment will be described. Here, a case will be mainly described in which the front-end information processing circuit 4 receives a character string without a time stamp as input sequence data and generates a Moore machine that filters the received character string. In this case, the Moore machine operated by the prefix information processing circuit 4 is the same as that described in section 3.2 of this specification.

前置情報処理回路4で動作するムーアマシンは、入力されるシーケンスデータのマッチング条件に基づいて生成される。そのため、ムーアマシンの説明の前に、マッチング条件の例を説明する。以下の説明では、マッチング条件が(正規表現で表記した場合に)"a(a*)b"と表記される場合の例を説明する。   The Moore machine operated by the prefix information processing circuit 4 is generated based on the matching condition of the input sequence data. Therefore, before explaining the Moore machine, an example of the matching condition will be described. In the following description, an example in which the matching condition is expressed as “a (a *) b” (when expressed in a regular expression) will be described.

正規表現"a(a*)b"は、図17に示す状態遷移図に従った動作をするオートマトンA=(Σ,S,s,S,E)と等価である。なお、オートマトンA=(Σ,S,s,S,E)の各記号の意味は以下の通りである。Σは入力文字セットを表し、Sは状態の集合を表し、s,は初期状態(Sの要素でもある)を表し、Sは最終状態(受理状態とも呼ばれる)を表し(Sの部分集合でもある)、Eは遷移の集合である。 The regular expression “a (a *) b” is equivalent to the automaton A = (Σ, S, s 0 , S F , E) that operates according to the state transition diagram shown in FIG. The meaning of each symbol of the automaton A = (Σ, S, s 0 , S F , E) is as follows. Σ represents the input character set, S is represents the set of states, s 0, is the initial state (which is also the element of S), S F represents the final state (also called accepting state) (the subset of S E) is a set of transitions.

ここで説明する例では、オートマトンAは3つの状態{s,s,s}を有し、sが初期状態で、sが最終状態(受理状態)である。またΣは文字a,bから構成される。図17において、各状態{s,s,s}は円で表現され、また二重円は受理状態を表す。さらに、各状態を結ぶ矢印(エッジ)の上に付されている文字(a,b)はオートマトンAへの入力を意味する。たとえば図17では、状態sと状態sを結ぶ矢印の上に文字"a"が記されているが、これは「オートマトンAが状態sの時に文字"a"が入力されると、オートマトンAはが状態sに遷移する」ことを表す。 In the example described here, the automaton A has three states {s 0 , s 1 , s 2 }, where s 0 is the initial state and s 2 is the final state (acceptance state). Σ is composed of characters a and b. In FIG. 17, each state {s 0 , s 1 , s 2 } is represented by a circle, and a double circle represents an acceptance state. Further, characters (a, b) given above arrows (edges) connecting the states mean input to the automaton A. For example, in FIG. 17, the character “a” is written on the arrow connecting the state s 0 and the state s 1. This is because “the character“ a ”is input when the automaton A is in the state s 0 . represents a transition to "be in the automaton a Haga state s 1.

前置情報処理回路4は、本明細書の3.2節で説明した定義に従ってムーアマシンを生成する。ここで生成されるムーアマシンをMA,N=(Σ,Σ,Q,q,Δ,Λ)と表記する。なお、MA,N=(Σ,Σ,Q,q,Δ,Λ)の各記号の意味は以下の通りである。一番目のΣは入力文字セットを表し、二番目のΣは出力文字セットを表す。Σは先に述べた通り、オートマトンAの入力文字セットであり、ΣはオートマトンAの入力文字セットに対して、文字⊥を追加した文字セットである(ただし文字⊥は、オートマトンAの入力文字セットΣには含まれていない文字である。本明細書では⊥を「ブロック文字」と呼ぶ)。Qはムーアマシンの状態空間を表し、qは初期状態を表し、Δは遷移関数を表し、Λは出力関数を表す。また、MA,Nの添え字Aは、ムーアマシンの元となるオートマトン(つまり前置情報処理回路4が受け付けたオートマトンA)を意味し、Nはバッファサイズ(図16を用いて説明したバッファ22aの有するメモリブロックの数)を意味する。 The prefix information processing circuit 4 generates a Moore machine according to the definition described in section 3.2 of this specification. Here the Moore machine M A which is generated, N = (Σ ⊥, Σ ⊥, Q, q 0, Δ, Λ) and denoted. In addition, the meaning of each symbol of M A, N = (Σ , Σ ,, Q, q 0 , Δ, Λ) is as follows. The first {} represents the input character set, and the second {} represents the output character set. As is mentioned above sigma, an input character set of the automaton A, sigma for the input character set of the automaton A, a character set to add a character ⊥ (although characters ⊥ is the input character of the automaton A These characters are not included in the set Σ. In this specification, ⊥ is referred to as a “block character.” Q represents the state space of the Moore machine, q 0 represents the initial state, Δ represents a transition function, and Λ represents an output function. The suffix A of M A, N means the automaton that is the basis of the Moore machine (that is, the automaton A received by the front information processing circuit 4), and N is the buffer size (the buffer described with reference to FIG. 16). 22a).

ムーアマシンを生成する際、前置情報処理回路4はまずオートマトンAがとり得る各状態をもとに、拡張された状態を定義する。実施例2では、オートマトンAがとり得る状態(仮にこれをsと表記する)と、オートマトンAが初期状態(s)から状態sに遷移するまでに要する遷移回数の組を、新たな(拡張された)状態として定義する。初期状態(s)から状態sに遷移するまでに要する遷移回数がc回の場合、この新たな状態は(s,c)と表記される。実施例2では、この新たな状態のことを「カウンタ付き状態」と呼ぶこともあり、また初期状態(s)から状態sに遷移するまでに要する遷移回数のことを「カウンタ」と呼ぶこともある。ただし実施例2において、カウンタは、0以上の整数だが、上限値がバッファサイズNの整数であり、カウンタは正確には、以下の式(7)を計算することで求められる値である(つまりカウンタは法Nに関する剰余類に属する)。 When generating the Moore machine, the pre-information processing circuit 4 first defines an extended state based on each state that the automaton A can take. In Example 2, the automaton A can take state (provisionally denoted to as s k), a set number of transitions required for the automaton A is shifted from the initial state (s 0) to the state s k, new Defined as (extended) state. If the number of transitions required until the transition from the initial state (s 0) to the state s k of c times, the new state is denoted as (s k, c). In Example 2, sometimes that of the new state is referred to as the "counter with the state", also referred to a number of transitions required until the transition from the initial state (s 0) to the state s k a "counter" Sometimes. However, in the second embodiment, the counter is an integer equal to or greater than 0, but the upper limit is an integer equal to the buffer size N, and the counter is exactly a value obtained by calculating the following equation (7) (that is, The counter belongs to the coset related to modulus N).

((遷移回数−1) mod N)+1 ...(7)
そのため正確には遷移回数とカウンタの値は一致しないこともあるが、実施例2においては(s,c)のcを、状態sのカウンタと呼ぶ場合もあるし、遷移回数と呼ぶこともある。
((Number of transitions -1) mod N) +1 ... (7)
So although the exact value of the number of transitions and the counter does not have to be equal, the c of the embodiment 2 (s k, c), to also be called counter state s k, be referred to as the number of transitions There is also.

カウンタと、カウンタ付き状態について、カウンタ付き状態を用いて記述されるオートマトンの状態遷移図(図18)を用いて説明する。なお、以下の説明では特に断りのない限り、バッファサイズ(N)は2のケースを説明する。   The counter and the state with the counter will be described with reference to a state transition diagram (FIG. 18) of the automaton described using the state with the counter. In the following description, a case where the buffer size (N) is 2 will be described unless otherwise specified.

図17のオートマトンAにおいて、初期状態sから状態sに遷移するまでに要する遷移回数は1回なので、状態sのカウンタは上の式(7)に基づくと1である。そのため前置情報処理回路4はカウンタ付状態として(s,1)を定義する。 In the automaton A of FIG. 17, the number of transitions required until the transition from the initial state s 0 to the state s 1 is so once counter state s 1 is 1 Based on Equation (7) above. Therefore, the front information processing circuit 4 defines (s 1 , 1) as the state with the counter.

加えて、図17から分かる通り、オートマトンAにおいて、状態がsの時にシーケンスデータとして文字"a"が入力されると、状態は再びsに遷移する(これはたとえば、状態がsの時に文字"a"が2回連続して入力されたケースである)。この場合、2回の遷移の結果、状態sに遷移することを意味するので、遷移回数は2で、カウンタの値も2である。そのため前置情報処理回路4は、カウンタ付状態として(s,2)を定義する。 In addition, as seen from FIG. 17, in the automaton A, the state letter "a" as the sequence data when s 1 is input, the state transitions to s 1 again (which, for example, the state is s 0 Sometimes the character "a" is entered twice consecutively). In this case, two transitions result, it means that a transition to the state s 1, in the number of transitions is 2, the value of the counter is also 2. Therefore, the prefix information processing circuit 4 defines (s 1 , 2) as the state with the counter.

さらに、オートマトンAにおいて、状態がsの時に文字"a"が3回連続して入力された場合、状態は再びsに遷移する。この場合遷移回数は3回だが、バッファサイズが2であるため、カウンタの値は上の式(7)に基づくと1[((3−1) mod 2)+1=1]である。そのため、オートマトンAがとり得る状態sにカウンタを付して生成される新たな状態(カウンタ付き状態)としては、(s,1)と(s,2)の2つがある。 Further, in the automaton A, when a state letter "a" when s 0 is entered three consecutive times, the state transitions to s 1 again. In this case, the number of transitions is three, but since the buffer size is two, the value of the counter is 1 [((3-1) mod 2) + 1 = 1] based on the above equation (7). Therefore, the new state produced by subjected the counter state s 1 automaton A can take (counter with state), There are two of (s 1, 1) and (s 1, 2).

同様に、オートマトンAがとり得る状態sにカウンタを付して生成される新たな状態としては、(s,1)と(s,2)の2つがある。そのため、バッファサイズNが2の時、前置情報処理回路4は図17に示されたオートマトンAに基づいて、5つのカウンタ付き状態(s0,0)、(s,1)、(s,2)、(s,1)、(s,2)を定義する。カウンタ付き状態を定義した後、前置情報処理回路4は図18に示すように、カウンタ付き状態を用いたオートマトンを定義する(ここで定義されるカウンタ付き状態を用いたオートマトンをA'と表記する)。 Similarly, there are two new states (s 2 , 1) and (s 2 , 2) generated by adding a counter to the state s 2 that can be taken by the automaton A. Therefore, when the buffer size N is 2, the pre-information processing circuit 4 performs five states with counters (s 0 , 0), (s 1 , 1), (s) based on the automaton A shown in FIG. 1 , 2), (s 2 , 1) and (s 2 , 2) are defined. After defining the state with the counter, the pre-information processing circuit 4 defines an automaton using the state with the counter as shown in FIG. 18 (the automaton using the state with the counter defined here is denoted as A ′). Do).

図18に示されたオートマトンA'は、各状態がカウンタ付状態である点が、図17に示すオートマトンAと異なるが、図18に示されたオートマトンA'の状態遷移のルールは原則として、図17に示すオートマトンAと同じである。つまり前置情報処理回路4は図17に示すオートマトンAに基づいてオートマトンA'を定義する。たとえば図17に示すオートマトンAでは、状態s((s,1)または(s,2))の時に文字"b"が入力されると、状態はs((s,2)または(s,1))に遷移する。そのため前置情報処理回路4はオートマトンA'を定義する際、状態(s,1)または(s,2)の時に文字"b"が入力されると、状態は(s,2)または(s,1)に遷移するように、オートマトンA'を定義する。 The automaton A ′ shown in FIG. 18 is different from the automaton A shown in FIG. 17 in that each state is a state with a counter, but the rule of the state transition of the automaton A ′ shown in FIG. This is the same as the automaton A shown in FIG. That is, the prefix information processing circuit 4 defines the automaton A ′ based on the automaton A shown in FIG. For example, in the automaton A shown in FIG. 17, when the character “b” is input in the state s 1 ((s 1 , 1) or (s 1 , 2)), the state becomes s 2 ((s 2 , 2) Or (s 2 , 1)). Therefore, when the prefix information processing circuit 4 defines the automaton A ′, if the character “b” is input in the state (s 1 , 1) or (s 1 , 2), the state becomes (s 2 , 2) Alternatively, the automaton A ′ is defined so as to transition to (s 2 , 1).

次に前置情報処理回路4は図18のオートマトンA'をもとにして、ムーアマシンを定義(生成)する。まず、ムーアマシンの取りうる状態(状態空間)の定義、遷移関数の定義方法について説明する。前置情報処理回路4によるムーアマシンの生成処理では、公知のサブセット構成法(パワーセット構成法とも呼ばれる)と類似した処理が行われる。サブセット構成法はたとえば特開2009−58989号公報などに示されているように公知の手法であるため、詳細な説明は略す。ここでは前置情報処理回路4が実行するムーアマシンの生成に関連する処理のみを説明する。   Next, the prefix information processing circuit 4 defines (generates) a Moore machine based on the automaton A ′ in FIG. First, a definition of a state (state space) that the Moore machine can take and a method of defining a transition function will be described. In the process of generating a Moore machine by the prefix information processing circuit 4, a process similar to a known subset configuration method (also referred to as a power set configuration method) is performed. Since the subset configuration method is a known method as disclosed in, for example, Japanese Patent Application Laid-Open No. 2009-58989, a detailed description is omitted. Here, only the processing related to the generation of the Moore machine executed by the front information processing circuit 4 will be described.

サブセット構成法は、非決定的有限オートマトン(NFA)を決定的有限オートマトン(DFA)に変換(決定化と呼ばれる)する際に用いられる処理である。そのため前置情報処理回路4の生成するムーアマシンはDFAである。よく知られているように、決定化では、非決定的有限オートマトン(NFA)のある状態(またはある状態の集合)に対して入力文字xが与えられたときの遷移先の状態をすべて特定し、特定された状態の集合を決定的有限オートマトンの状態にする。前置情報処理回路4もこの決定化と同様の処理を行う。   The subset construction method is a process used when converting a nondeterministic finite automaton (NFA) into a deterministic finite automaton (DFA) (called determinization). Therefore, the Moore machine generated by the prefix information processing circuit 4 is a DFA. As is well known, determinization specifies all states to which a transition is made when an input character x is given to a state (or a set of states) of a nondeterministic finite state automaton (NFA). The set of specified states is made into a state of a deterministic finite state automaton. The pre-information processing circuit 4 also performs the same processing as this determination.

ただし前置情報処理回路4が行う決定化では、さきに述べた「特定された状態の集合」に、初期状態(s,0)を追加したものを、前置情報処理回路4の生成するムーアマシンMA,Nの状態と定義する。また、入力文字セットはオートマトンA'の入力文字セットΣではなくΣを用いる。以下では、図18と図19を参照しながら、前置情報処理回路4によるムーアマシンMA,Nの生成処理を説明する。 However, in the determinization performed by the prefix information processing circuit 4, the initial information (s 0 , 0) added to the “set of specified states” described above is generated by the prefix information processing circuit 4. It is defined as the state of the Moore machine M A, N. The input character set uses {} instead of the input character set {} of the automaton A '. Hereinafter, the generation processing of the moor machines M A and N by the front information processing circuit 4 will be described with reference to FIG. 18 and FIG.

図18のオートマトンA'が初期状態(s,0)にあるときに入力文字aが与えられると、カウンタ付き状態(s,1)に遷移し、それ以外の状態には遷移しない。そのため前置情報処理回路4は、初期状態(s,0)から(入力文字aが与えられたときの)遷移先の状態の集合を{(s,1),(s,0)}と決定する(つまり、特定された遷移先状態(s,1)に(s,0)を加えたものが、遷移先の状態の集合になる)。以下ではこの状態の集合をq'と表記する。また初期状態(s,0)はq'と表記する(つまりq'はムーアマシンMA,Nの初期状態である)。また前置情報処理回路4は同様に、初期状態(s,0)にあるオートマトンA'に入力文字bが与えられた場合の遷移先の状態の集合、及び初期状態(s,0)にあるオートマトンA'に入力文字⊥が与えられた場合の遷移先の状態の集合、を特定する。図18を参照すると、これらの場合に対応した遷移先の状態は存在しない。遷移先の状態が存在しない場合、先に述べた「特定された状態の集合」が空集合であることと等価である。この場合前置情報処理回路4は、空集合に初期状態(s,0)を追加して形成される状態の集合{(s,0)}(つまりq')を遷移先と決定する。そのため前置情報処理回路4は、初期状態(s,0)から(入力文字bが与えられたとき、及び入力文字⊥が与えられたときの)遷移先の状態の集合を{(s,0)}(=q')と決定する。 If the input character a is given when the automaton A ′ in FIG. 18 is in the initial state (s 0 , 0), the state transits to the state with counter (s 1 , 1) and does not transit to any other state. For this reason, the prefix information processing circuit 4 sets the set of transition destination states (when the input character a is given) from the initial state (s 0 , 0) to {(s 1 , 1), (s 0 , 0)つ ま り (that is, the sum of the specified transition destination state (s 1 , 1) and (s 0 , 0) becomes a set of transition destination states). Hereinafter, this set of states will be referred to as q 1 ′. The initial state (s 0, 0) is 'expressed as (i.e. q 0' q 0 is the initial state of the Moore machine M A, N). Also likewise pre processing circuit 4, a set of transition destination state when the initial state (s 0, 0) input character b automaton A 'in is given, and the initial state (s 0, 0) Specifies the set of transition destination states when the input character ⊥ is given to the automaton A ′ in. Referring to FIG. 18, there is no transition destination state corresponding to these cases. If the state of the transition destination does not exist, it is equivalent to the above-mentioned “set of specified states” being an empty set. In this case, the prefix information processing circuit 4 determines the set {(s 0 , 0)} (that is, q 0 ′) of the state formed by adding the initial state (s 0 , 0) to the empty set as the transition destination. I do. For this reason, the prefix information processing circuit 4 sets the set of transition destination states from the initial state (s 0 , 0) (when the input character b is given and when the input character ⊥ is given) to {(s 0 , 0)} (= q 0 ′).

続いて前置情報処理回路4は、状態の集合q'(={(s,1),(s,0)})からの遷移先状態の集合を特定する。図18の状態遷移図から分かるとおり、状態(s,1)にあるオートマトンA'に入力文字aが与えられたときの遷移先状態は(s,2)で、状態(s,0)にあるオートマトンA'に入力文字aが与えられたときの遷移先状態は(s,1)である。そのため前置情報処理回路4は、状態(s,1),(s,2)に状態(s,0)を加えてなる集合{(s,1),(s,2),(s,0)}を、状態の集合q'に入力文字aが与えられたときの遷移先状態の集合と決定する。以下ではこの状態の集合{(s,1),(s,2),(s,0)}をq'と表記する。同様に前置情報処理回路4は。状態の集合q'に入力文字bが与えられたときの遷移先状態の集合(これは図19に示されたq3'である。なおq3'の要素は{(s,2),(s,0)}である)、入力文字⊥が与えられたときの遷移先状態の集合(これはq'になる)を決定する。 Subsequently, the prefix information processing circuit 4 specifies a set of transition destination states from the set of states q 1 ′ (= {(s 1 , 1), (s 0 , 0)}). As can be seen from the state transition diagram of FIG. 18, when the input character a is given to the automaton A ′ in the state (s 1 , 1), the transition destination state is (s 1 , 2) and the state (s 0 , 0) The transition destination state when the input character a is given to the automaton A ′ in ()) is (s 1 , 1). Therefore pre-processing circuit 4, the state (s 1, 1), ( s 1, 2) made by the addition of state (s 0, 0) in the set {(s 1, 1), (s 1, 2) , (S 0 , 0)} is determined as a set of transition destination states when the input character a is given to the state set q 1 ′. Hereinafter, this set of states {(s 1 , 1), (s 1 , 2), (s 0 , 0)} is denoted as q 2 ′. Similarly, the front information processing circuit 4. The set of transition destination states when the input character b is given to the set of states q 1 ′ (this is q 3 ′ shown in FIG. 19. The element of q 3 ′ is {(s 2 , 2) , (S 0 , 0)}) and a set of transition destination states when the input character ⊥ is given (this becomes q 0 ′).

前置情報処理回路4はこれらの処理を繰り返すことで、ムーアマシンMA,Nの各状態及び状態遷移を決定する。決定されたムーアマシンMA,Nの各状態及び状態遷移を図に表したものが図19である。そして前置情報処理回路4は、決定された各状態及び状態遷移をRAM22に記憶する。RAM22に記憶された、ムーアマシンMA,Nの各状態及び状態遷移の例を図20、図21に示す。図20は図18のオートマトンA'に基づいて前置情報処理回路4が生成したムーアマシンMA,Nの状態遷移表(図19の状態遷移図と等価なものである)を示し、図21はムーアマシンMA,Nの状態管理テーブルである。 The pre-information processing circuit 4 determines these states and state transitions of the Moore machines MA and N by repeating these processes. FIG. 19 illustrates the states and state transitions of the determined Moore machines MA and N. Then, the prefix information processing circuit 4 stores the determined states and state transitions in the RAM 22. FIGS. 20 and 21 show examples of the states and state transitions of the Moore machines MA and N stored in the RAM 22. FIG. FIG. 20 shows a state transition table (equivalent to the state transition diagram of FIG. 19) of the Moore machines M A and N generated by the prefix information processing circuit 4 based on the automaton A ′ of FIG. Is a state management table of the Moore machine MA , N.

図21に示すように、状態管理テーブルは、「状態」、「部分集合」、「Current」のカラムを有する。カラム「状態」には、ムーアマシンMA,Nの取り得る状態の一覧が格納される。カラム「部分集合」の各行には、ムーアマシンMA,Nの状態に含まれる要素(具体的には、オートマトンA'の1または複数の状態(カウンタ付き状態)である)が格納される。カラム「Current」は、ムーアマシンの現時点の状態を記憶するための領域であり、詳細は後述するが、カラム「Current」に"1"が格納されている行に対応する状態が、ムーアマシンの現時点の状態である。 As shown in FIG. 21, the state management table has columns of “state”, “subset”, and “Current”. The column “state” stores a list of possible states of the Moore machine MA , N. Each row of the column “subset” stores an element (specifically, one or more states (a state with a counter) of the automaton A ′) included in the state of the Moore machine MA , N. The column “Current” is an area for storing the current state of the Moore machine. As will be described later in detail, the state corresponding to the row in which “1” is stored in the column “Current” is the state of the Moore machine. It is the current state.

図20の状態遷移表は、ムーアマシンMA,Nの状態遷移のルール(遷移関数)を表す。状態遷移表は複数の行を有し、各行(δ〜δ11と表記する)はムーアマシンMA,Nの遷移の仕様を表す。図20に示されるように、状態遷移表の各行は、「遷移前状態」、「遷移後状態」、「入力」の欄を有する。たとえば状態遷移表の一番上の行(遷移δの仕様を記述した行)について、「遷移前状態」、「遷移後状態」、「入力」にはそれぞれ、"q'"、"q'"、"a"が格納されている。これは遷移前の状態がq'の場合、入力文字列"a"が与えられると遷移後の状態がq'になることを表す。 The state transition table of FIG. 20 represents the state transition rule (transition function) of the Moore machine MA , N. The state transition table has a plurality of rows, and each row (denoted as δ 0 to δ 11 ) represents a transition specification of the Moore machine MA , N. As shown in FIG. 20, each row of the state transition table has columns of “state before transition”, “state after transition”, and “input”. For example, regarding the top row of the state transition table (the row describing the specification of the transition δ 0 ), “q 0 ′” and “q” are respectively set in “pre-transition state”, “post-transition state”, and “input”. 1 '"and" a "are stored. This means that if the state before the transition is q 0 ′ and the input character string “a” is given, the state after the transition will be q 1 ′.

ムーアマシンMA,Nの状態遷移表と状態管理テーブルは、RAM22の非バッファ22bに格納される。なお、前置情報処理回路4が生成する状態遷移表と状態管理テーブルは、ここで説明した情報以外の情報を含んでいてもよい。また、図20、図21に示された状態遷移表と状態管理テーブルは一例であり、前置情報処理回路4は必ずしも図20、図21に示されたフォーマットで情報を作成しなければならないわけではない。前置情報処理回路4はムーアマシンMA,Nの動作(状態遷移)に必要な情報を、図20、図21に示されたフォーマットとは異なるフォーマットで記憶領域(RAM22など)に記憶してもよい。 The state transition table and the state management table of the Moore machine MA , N are stored in the non-buffer 22b of the RAM 22. The state transition table and the state management table generated by the prefix information processing circuit 4 may include information other than the information described here. Also, the state transition tables and the state management tables shown in FIGS. 20 and 21 are examples, and the pre-information processing circuit 4 must necessarily create information in the format shown in FIGS. is not. The pre-information processing circuit 4 stores information necessary for the operation (state transition) of the Moore machines MA and N in a storage area (such as the RAM 22) in a format different from the format shown in FIGS. Is also good.

ムーアマシンMA,Nの動作には、状態の定義、遷移関数の定義の他、出力関数の定義が必要だが、出力関数の詳細は後述する。また、実施例2に係るムーアマシンMA,Nが動作する際、バッファ22aの内容の操作も行われるが、これについても後述する。 The operation of the Moore machine MA , N requires the definition of the output function in addition to the definition of the state and the definition of the transition function. The details of the output function will be described later. When the mooring machines M A and N according to the second embodiment operate, the contents of the buffer 22a are also operated, which will also be described later.

続いて、前置情報処理回路4の有する各機能ブロックの説明を行う。図22は、前置情報処理回路4の有する各機能ブロックを表した図である。図22に示されているように、前置情報処理回路4は、生成モジュール22m1、フィルタモジュール22m2、ムーアマシンモジュール22m3の処理モジュール(機能ブロック)を有する。これらの機能ブロックは、CPU20が前置情報処理回路4の有する各プログラムを実行することによって実現される。具体的には、生成モジュール22m1は、CPU20が生成プログラム22p1を実行することによって実現される機能ブロックである。フィルタモジュール22m2は、CPU20がメインプログラム22p2を実行することによって実現される機能ブロックである。ムーアマシンモジュール22m3は、CPU20がサブプログラム22p3を実行することによって実現される機能ブロックである。   Subsequently, each functional block of the front information processing circuit 4 will be described. FIG. 22 is a diagram illustrating each functional block of the prefix information processing circuit 4. As shown in FIG. 22, the pre-information processing circuit 4 has processing modules (functional blocks) of a generation module 22m1, a filter module 22m2, and a Moore machine module 22m3. These functional blocks are realized by the CPU 20 executing each program of the front information processing circuit 4. Specifically, the generation module 22m1 is a functional block realized by the CPU 20 executing the generation program 22p1. The filter module 22m2 is a functional block realized by the CPU 20 executing the main program 22p2. The Moore machine module 22m3 is a functional block realized by the CPU 20 executing the subprogram 22p3.

フィルタモジュール22m2とムーアマシンモジュール22m3が、データ加工処理(フィルタリング処理)を実行する機能ブロックで、生成モジュール22m1はムーアマシンモジュール22m3(サブプログラム22p3)を生成するための機能ブロックである。生成モジュール22m1は、フィルタモジュール22m2からの指示を受け付けることによって、ムーアマシンモジュール22m3を生成する。ムーアマシンモジュール22m3は、フィルタモジュール22m2からの指示に基づいて、上で説明した有限状態機械(ムーアマシン)としての動作を行う。具体的には、フィルタモジュール22m2からシーケンスデータ(文字列)を一単位ずつ(1文字ずつ)受信し、それに応じて状態の遷移と情報の出力を行う。生成モジュール22m1、フィルタモジュール22m2、ムーアマシンモジュール22m3の処理の詳細は、以下で説明する。   The filter module 22m2 and the Moore machine module 22m3 are function blocks for executing data processing (filtering), and the generation module 22m1 is a function block for generating the Moore machine module 22m3 (subprogram 22p3). The generation module 22m1 generates the Moore machine module 22m3 by receiving an instruction from the filter module 22m2. The Moore machine module 22m3 performs an operation as the above-described finite state machine (Moore machine) based on an instruction from the filter module 22m2. Specifically, it receives sequence data (character string) from the filter module 22m2 one unit at a time (one character at a time), and performs state transition and information output accordingly. Details of the processing of the generation module 22m1, the filter module 22m2, and the Moore machine module 22m3 will be described below.

続いて、前置情報処理回路4によって行われるフィルタリング処理の流れを説明する。以下では、前置情報処理回路4はシーケンスデータとして、タイムスタンプの付与されていない1バイト文字のシーケンス(文字列)を1バイトずつ受信する受け取る例を説明する。   Subsequently, a flow of the filtering process performed by the prefix information processing circuit 4 will be described. Hereinafter, an example will be described in which the prefix information processing circuit 4 receives, as sequence data, a one-byte character sequence (character string) to which a time stamp is not added, one byte at a time.

図23、図24は、前置情報処理回路4が実行するデータ加工処理(フィルタリング処理)のフローチャートである。図23のフローチャートは、フィルタリング処理の全体の流れを示している。図24は、図23のフローチャートの一部(ステップS103)の処理を詳述したフローチャートである。   FIG. 23 and FIG. 24 are flowcharts of the data processing (filtering) performed by the front information processing circuit 4. The flowchart in FIG. 23 illustrates the entire flow of the filtering process. FIG. 24 is a flowchart detailing the processing of a part (step S103) of the flowchart of FIG.

まず図23を参照しながら、フィルタリング処理の全体の流れを説明する。フィルタリング処理はたとえば、前置情報処理回路4が操作部23を介してユーザからの処理開始指示を受け付けた場合、または前置情報処理回路4が入力インターフェース25を介して外部の装置からの処理開始指示を受け付けた場合に実行される。フィルタリング処理が開始されると、フィルタモジュール22m2は、マッチング条件を操作部23または入力インターフェース25を介して受け取り、受け取ったマッチング条件からムーアマシンを生成する(図23 ステップS101)。なお、ステップS101において、フィルタモジュール22m2は生成モジュール22m1に、ムーアマシンモジュール22m3の生成を行わせる。生成モジュール22m1は、上で述べたようなムーアマシンの状態の定義、遷移関数の定義を行う(つまり生成モジュール22m1は、CPU20が実行するプログラムコードだけでなく、上で説明した状態管理テーブルなどの情報(ムーアマシンの動作に必要な情報)も生成する)。   First, the overall flow of the filtering process will be described with reference to FIG. The filtering process is performed, for example, when the front information processing circuit 4 receives a process start instruction from the user via the operation unit 23, or when the front information processing circuit 4 starts processing from an external device via the input interface 25. Executed when an instruction is received. When the filtering process is started, the filter module 22m2 receives a matching condition via the operation unit 23 or the input interface 25, and generates a Moore machine from the received matching condition (Step S101 in FIG. 23). In step S101, the filter module 22m2 causes the generation module 22m1 to generate the Moore machine module 22m3. The generation module 22m1 defines the state of the Moore machine and the transition function as described above (that is, the generation module 22m1 includes not only the program code executed by the CPU 20 but also the state management table and the like described above). Information (information necessary for the operation of the Moore machine) is also generated).

ムーアマシンの状態の定義、遷移関数の定義は、上で図17〜図21を用いて説明したとおりである。生成モジュール22m1は状態の定義結果として図21に示されるような状態管理テーブルを生成し、非バッファ22bに格納する(状態管理テーブルの生成直後は、ムーアマシン(ムーアマシンモジュール22m3)は初期状態にあるので、生成モジュール22m1はカラム「Current」の要素のうち、初期状態(q')に対応する行(図21の一番上の行)の「Current」の値が1で、それ以外の行については「Current」の値を0に設定した状態管理テーブルを生成する)。生成モジュール22m1は遷移関数の定義の結果として、図20に示されるような状態遷移表を生成し、非バッファ22bに格納する。また、生成モジュール22m1はバッファ22aを作成する。具体的には生成モジュール22m1は、RAM22上に、図16に示すようなN個のメモリブロックを有する領域を確保し、そしてこのN個のメモリブロックのデータ領域とフラグ領域を初期化する(すべてのメモリブロックのフラグ領域にフラグ"mask"、つまり0が格納され、また全てのメモリブロックのデータ領域にはブロック文字⊥が格納される)。また、出力関数の定義については後述する。 The definition of the state of the Moore machine and the definition of the transition function are as described above with reference to FIGS. The generation module 22m1 generates a state management table as shown in FIG. 21 as a state definition result and stores it in the non-buffer 22b (immediately after generation of the state management table, the Moore machine (Moore machine module 22m3) returns to the initial state. Therefore, the generation module 22m1 determines that among the elements of the column “Current”, the value of “Current” in the row (the top row in FIG. 21) corresponding to the initial state (q 0 ′) is 1, and the other For the row, a state management table in which the value of “Current” is set to 0 is generated). The generation module 22m1 generates a state transition table as shown in FIG. 20 as a result of the definition of the transition function, and stores the state transition table in the non-buffer 22b. The generation module 22m1 creates the buffer 22a. Specifically, the generation module 22m1 secures an area having N memory blocks as shown in FIG. 16 in the RAM 22, and initializes the data area and the flag area of the N memory blocks (all The flag "mask", that is, 0, is stored in the flag area of the memory block, and the block character $ is stored in the data area of all the memory blocks.) The definition of the output function will be described later.

なお、フィルタモジュール22m2は、必ずしもステップS101でマッチング条件を受け取らなくてもよい。たとえば、前置情報処理回路4に、所定のマッチング条件に基づいて生成されたムーアマシン(ムーアマシンモジュール22m3)があらかじめ実装されていてもよい。その場合、フィルタモジュール22m2はフィルタリング処理を実行するときには、この予め実装されているムーアマシンを実行するとよい。ムーアマシンがあらかじめ実装されている場合、前置情報処理回路4はステップS101を実行する必要はなく、また前置情報処理回路4は生成モジュール22m1を有していなくてよい。   Note that the filter module 22m2 does not necessarily need to receive the matching condition in step S101. For example, a Moore machine (Moore machine module 22m3) generated based on a predetermined matching condition may be mounted in the front information processing circuit 4 in advance. In that case, when performing the filtering process, the filter module 22m2 may execute the pre-mounted Moore machine. When the Moore machine is mounted in advance, the front information processing circuit 4 does not need to execute step S101, and the front information processing circuit 4 may not have the generation module 22m1.

続いて、ステップS102において、フィルタモジュール22m2は入力インターフェース25を介してシーケンスデータを受信する。ステップS102が1回実行されるたびに、前置情報処理回路4はシーケンスデータの一単位分のデータ(ここでは1バイトの文字)を受領する。   Subsequently, in step S102, the filter module 22m2 receives the sequence data via the input interface 25. Each time step S102 is performed once, the prefix information processing circuit 4 receives data of one unit of sequence data (here, 1-byte character).

続いてフィルタモジュール22m2はムーアマシンモジュール22m3を呼び出し、ステップS102で受領したデータ(1バイトの文字)をムーアマシンモジュール22m3に渡すことで、ムーアマシンMA,Nを用いた処理を行わせる(ステップS103)。ステップS103の処理の詳細は後述するが、ステップS103が一回実行されるとムーアマシンモジュール22m3はバッファ22aの末尾のメモリブロックに格納されているデータを出力する。フィルタモジュール22m2はムーアマシンモジュール22m3から出力されたデータを、出力インターフェース26を介して外部の装置に出力する。 Subsequently, the filter module 22m2 calls the Moore machine module 22m3, and passes the data (1 byte character) received in step S102 to the Moore machine module 22m3, thereby performing the process using the Moore machine MA , N (step S103). Although details of the processing of step S103 will be described later, once step S103 is executed, the Moore machine module 22m3 outputs data stored in the last memory block of the buffer 22a. The filter module 22m2 outputs the data output from the Moore machine module 22m3 to an external device via the output interface 26.

続いてフィルタモジュール22m2は、シーケンスデータの入力が終了したか(文字列の終端文字まで受け付けが完了したか)判定する(ステップS104)。シーケンスデータの入力が終了したか否かは、たとえば入力インターフェース25から通知される。ただしフィルタモジュール22m2はこれ以外の方法で、シーケンスデータの入力が終了したか否かを検出してもよい。シーケンスデータの入力が終了していないと判断された場合(ステップS104:NO)、フィルタリング処理はステップS102に戻る。シーケンスデータの入力が終了したと判断された場合(ステップS104:YES)、フィルタモジュール22m2はブロック文字⊥をムーアマシンモジュール22m3に渡す処理をN回行う(ステップS105)。先に述べた通り、Nはバッファサイズである。そのため、バッファサイズ(N)が2の場合、ステップS105では実質的にステップS103が2回行われる。ステップS105の後、フィルタリング処理は終了する。   Subsequently, the filter module 22m2 determines whether the input of the sequence data has been completed (whether the reception up to the last character of the character string has been completed) (Step S104). Whether the input of the sequence data is completed is notified from the input interface 25, for example. However, the filter module 22m2 may detect whether or not the input of the sequence data has been completed by another method. If it is determined that the input of the sequence data has not been completed (step S104: NO), the filtering process returns to step S102. If it is determined that the input of the sequence data has been completed (step S104: YES), the filter module 22m2 performs a process of passing the block character に to the Moore machine module 22m3 N times (step S105). As mentioned above, N is the buffer size. Therefore, when the buffer size (N) is 2, step S103 is substantially performed twice in step S105. After step S105, the filtering process ends.

先にも述べたが、ステップS103が実行されると、ムーアマシンモジュール22m3に渡されたデータ(1バイトの文字)がバッファ22aのメモリブロック(のデータ領域)に入力されるとともに、バッファ22aの末尾のメモリブロックに格納されていたデータが出力される。そのため、ステップS105が実行されると、バッファ22aのN個のメモリブロックに格納されていたデータがすべて出力される。つまりステップS105は、ステップS105の実行前にバッファ22aのメモリブロックに格納されていた(残留している)データをすべて出力させるために行われる。   As described above, when step S103 is executed, the data (one-byte character) passed to the Moore machine module 22m3 is input to (the data area of) the memory block of the buffer 22a, and The data stored in the last memory block is output. Therefore, when step S105 is executed, all data stored in the N memory blocks of the buffer 22a is output. That is, step S105 is performed in order to output all data (remaining) stored in the memory block of the buffer 22a before execution of step S105.

続いてステップS103で行われる処理の詳細を、図24を用いて説明する。図24の処理は、ムーアマシンモジュール22m3によって実行される。ムーアマシンモジュール22m3は、フィルタモジュール22m2からデータを受け取るたびにムーアマシン(ムーアマシンモジュール22m3)の状態の遷移、バッファ22aの内容の更新を行う。なお、以下の説明では、バッファサイズNは2(バッファ22aが有するメモリブロックの数は2)とする。   Next, details of the processing performed in step S103 will be described with reference to FIG. The processing in FIG. 24 is executed by the Moore machine module 22m3. The Moore machine module 22m3 changes the state of the Moore machine (Moore machine module 22m3) and updates the contents of the buffer 22a every time data is received from the filter module 22m2. In the following description, it is assumed that the buffer size N is 2 (the number of memory blocks included in the buffer 22a is 2).

ムーアマシンモジュール22m3はフィルタモジュール22m2からデータ(1バイトの文字)を受け取ると、バッファ22aの末尾のメモリブロック(22a−N)のデータ領域に格納されていたデータを取り出すとともに、バッファ22aの末尾のメモリブロック(22a−N)のフラグ領域に格納されているフラグがmaskか否か判定する(ステップS201)。メモリブロック(22a−N)のフラグがmaskでない場合、つまりフラグがpassの場合には(ステップS201:NO)、ムーアマシンモジュール22m3はメモリブロック(22a−N)のデータ領域に格納されているデータを、(変更することなしに)フィルタモジュール22m2に出力する(ステップS202)。ムーアマシンモジュール22m3からデータを受領したフィルタモジュール22m2は、出力インターフェース26を介してそのデータを外部に出力する。逆にメモリブロック(22a−N)のフラグがmaskであった場合(ステップS201:YES)、ムーアマシンモジュール22m3は取り出されたデータをブロック文字⊥に変更し、変更されたデータ(ブロック文字⊥)をフィルタモジュール22m2に出力する(ステップS203)。フィルタモジュール22m2はムーアマシンモジュール22m3から受領したブロック文字⊥を、出力インターフェース26を介して外部に出力する。   Upon receiving the data (one-byte character) from the filter module 22m2, the Moore machine module 22m3 extracts the data stored in the data area of the memory block (22a-N) at the end of the buffer 22a and extracts the data stored at the end of the buffer 22a. It is determined whether or not the flag stored in the flag area of the memory block (22a-N) is mask (step S201). If the flag of the memory block (22a-N) is not mask, that is, if the flag is pass (step S201: NO), the Moore machine module 22m3 stores the data stored in the data area of the memory block (22a-N). Is output to the filter module 22m2 (without change) (step S202). The filter module 22m2 that has received the data from the Moore machine module 22m3 outputs the data to the outside via the output interface 26. Conversely, if the flag of the memory block (22a-N) is mask (step S201: YES), the Moore machine module 22m3 changes the extracted data to the block character 、, and the changed data (block character ⊥) Is output to the filter module 22m2 (step S203). The filter module 22m2 outputs the block character ⊥ received from the Moore machine module 22m3 to the outside via the output interface 26.

ステップS204ではムーアマシンモジュール22m3は、フィルタモジュール22m2から受け取ったデータをバッファ22aの先頭のデータ領域に格納する。なお、先に述べた通り、バッファ22aの先頭にデータが格納される前に、バッファ22aの各メモリブロック(22a−1,22a−2,...22a−(N−1))内のデータ及びフラグはそれぞれ、左隣のメモリブロック(22a−2,22a−3,...22a−N)に移される。つまりバッファ22aはFIFOとして動作する。   In step S204, the Moore machine module 22m3 stores the data received from the filter module 22m2 in the first data area of the buffer 22a. As described above, before the data is stored at the head of the buffer 22a, the data in each memory block (22a-1, 22a-2,... 22a- (N-1)) of the buffer 22a is stored. And the flag are moved to the memory blocks (22a-2, 22a-3,... 22a-N) on the left side, respectively. That is, the buffer 22a operates as a FIFO.

続いてムーアマシンモジュール22m3は、非バッファ22bに格納されている状態遷移表や状態管理テーブルを用いて、ムーアマシン(ムーアマシンモジュール22m3)の状態遷移を実行する(ステップS205)。以下では、図20に示した状態遷移表と図21に示した状態管理テーブルが、非バッファ22bに格納されている場合の例を説明する。   Subsequently, the Moore machine module 22m3 executes the state transition of the Moore machine (Moore machine module 22m3) using the state transition table and the state management table stored in the non-buffer 22b (Step S205). Hereinafter, an example in which the state transition table illustrated in FIG. 20 and the state management table illustrated in FIG. 21 are stored in the non-buffer 22b will be described.

図21の状態管理テーブルにおいて、カラム「Current」には、現在のムーアマシンモジュール22m3の状態が記録される。カラム「Current」の各要素には、0または1のいずれかの値が格納される。カラム「Current」の値が"1"の行に対応する状態が現在の状態である。図21ではカラム「状態」がq'の行について、カラム「Current」の値が"1"であるので、図21の状態管理テーブルは現在の状態がq'であることを表している。 In the state management table of FIG. 21, the current state of the Moore machine module 22m3 is recorded in the column “Current”. Each element of the column “Current” stores a value of either 0 or 1. The state corresponding to the row where the value of the column “Current” is “1” is the current state. In FIG. 21, the value of the column “Current” is “1” for the row where the column “status” is q 1 ′, so the status management table of FIG. 21 indicates that the current status is q 1 ′. .

ムーアマシンモジュール22m3は、上に述べたような要領で現在のムーアマシンモジュール22m3の状態を特定すると、次に図20の状態遷移表と、フィルタモジュール22m2から受け取ったデータ(以下ではこれを「入力文字」と呼ぶ)とに基づいて、遷移先の状態を決定する。現在の状態が図21の状態管理テーブルに示されるようにq'で、入力文字が"b"であった場合、図20の状態遷移表を参照することで、遷移後の状態はq'になることが分かる。そこで、ムーアマシンモジュール22m3は、図21の状態管理テーブルのカラム「Current」を書き換えることで、現在の状態をq'に変更する。具体的にはムーアマシンモジュール22m3は、「状態」がq'の行のカラム「Current」の値を"0"に変更し、「状態」がq'の行のカラム「Current」の値を"1"に変更する。 The Moore machine module 22m3 specifies the current state of the Moore machine module 22m3 in the manner described above, and then determines the state transition table of FIG. 20 and the data received from the filter module 22m2 (hereinafter, this is referred to as “input The state of the transition destination is determined based on the “character”. When the current state is q 1 ′ as shown in the state management table of FIG. 21 and the input character is “b”, the state after the transition is q 3 by referring to the state transition table of FIG. ' Therefore, the Moore machine module 22m3 changes the current state to q 3 ′ by rewriting the column “Current” in the state management table in FIG. Specifically, the Moore machine module 22m3 changes the value of the column “Current” of the row whose “state” is q 1 ′ to “0”, and changes the value of the column “Current” of the row whose “state” is q 3 ′. To "1".

ステップS206ではムーアマシンモジュール22m3は、バッファ22aの先頭のメモリブロック(図16の22a−1)のフラグ領域を"mask"に変更する。   In step S206, the Moore machine module 22m3 changes the flag area of the first memory block (22a-1 in FIG. 16) of the buffer 22a to “mask”.

ステップS207ではムーアマシンモジュール22m3は、ムーアマシンモジュール22m3の現在の状態に含まれるオートマトンA(またはオートマトンA')の1または複数の状態(以下ではこれを「状態部分集合」と呼ぶ)の中に、カウンタの値がN(バッファサイズ)と等しい状態があるか判定する。「状態部分集合」とは、図21の状態管理テーブルのカラム「部分集合」に格納されている要素(オートマトンA'の1または複数のカウンタ付き状態)のことである。たとえば、現在のムーアマシンモジュール22m3の状態(ステップS205実行後の状態)がq'である場合について説明する。図21の状態管理テーブルのカラム「状態」がq'の行について、カラム「部分集合」の内容は{(s,0),(s,2)}であるから、現在のムーアマシンモジュール22m3の状態q'の状態部分集合は{(s,0),(s,2)}である。この状態部分集合に含まれる状態(カウンタ付き状態)のうち、状態(s,2)のカウンタの値は2である(つまりバッファサイズNと等しい)。このような場合(ステップS207:YES)には、ムーアマシンモジュール22m3はバッファ22aの全メモリブロックのフラグ領域を"pass"に変更する(ステップS208)。逆に、状態部分集合の中に、カウンタの値がNである状態が無い場合(ステップS207:NO)、ステップS208は実行されない。たとえば現在のムーアマシンモジュール22m3の状態がq'の場合、状態q'の状態部分集合は{(s,0),(s,1)}であるから、カウンタの値がNである状態は存在しない。このような場合にはステップS208は実行されない。 In step S207, the Moore machine module 22m3 stores one or more states of the automaton A (or the automaton A ') included in the current state of the Moore machine module 22m3 (hereinafter, this is referred to as a "state subset"). , It is determined whether there is a state where the value of the counter is equal to N (buffer size). The “state subset” is an element (state with one or more counters of the automaton A ′) stored in the column “subset” of the state management table in FIG. For example, a case where the current state of the Moore machine module 22m3 (the state after execution of step S205) is q 3 ′ will be described. Since the contents of the column “subset” are {(s 0 , 0), (s 2 , 2)} in the row where the column “status” of the state management table in FIG. 21 is q 3 ′, the current Moore machine The state subset of state q 3 ′ of module 22m3 is {(s 0 , 0), (s 2 , 2)}. Among the states (states with counters) included in this state subset, the value of the counter in state (s 2 , 2) is 2 (that is, equal to the buffer size N). In such a case (step S207: YES), the Moore machine module 22m3 changes the flag area of all the memory blocks of the buffer 22a to "pass" (step S208). Conversely, when there is no state in which the counter value is N in the state subset (step S207: NO), step S208 is not executed. For example, if the current state of the Moore machine module 22m3 is q 1 ′, the state subset of the state q 1 ′ is {(s 0 , 0), (s 1 , 1)}. Certain states do not exist. In such a case, step S208 is not performed.

ステップS209ではムーアマシンモジュール22m3は、ムーアマシンモジュール22m3の現在の状態の状態部分集合が、ムーアマシンモジュール22m3の元となるオートマトン(本実施例の場合にはオートマトンA)の受理状態を要素として有しているか判定する(つまり状態部分集合の中に、受理状態(図20、図21の例ではs((s,1)または(s,2))が受理状態である)が含まれているか判定する)。ムーアマシンモジュール22m3の現在の状態の状態部分集合が、(ムーアマシンモジュール22m3の元となるオートマトンの)受理状態を要素として有する場合には(ステップS209:YES)、処理はステップS210に進む。受理状態が状態部分集合に含まれていない場合には(ステップS209:NO)、ムーアマシンモジュール22m3はステップS210を実行せずに、ムーアマシンモジュール22m3の処理を終了する。 In step S209, the Moore machine module 22m3 determines that the state subset of the current state of the Moore machine module 22m3 has the reception state of the automaton (automaton A in this embodiment) as the element of the Moore machine module 22m3 as an element. (That is, s 2 ((s 2 , 1) or (s 2 , 2) in the example of FIGS. 20 and 21 is the accepted state) is included in the state subset) Is determined). If the state subset of the current state of the Moore machine module 22m3 has the acceptance state (of the automaton that is the source of the Moore machine module 22m3) as an element (step S209: YES), the process proceeds to step S210. If the accepted state is not included in the state subset (step S209: NO), the Moore machine module 22m3 terminates the processing of the Moore machine module 22m3 without executing step S210.

ステップS210でムーアマシンモジュール22m3は、状態部分集合の中に含まれる受理状態に対応するカウンタの値をすべて特定し、それらのカウンタ値の最大値(以下ではこの最大値をMと表記する)を求める。そしてムーアマシンモジュール22m3は、バッファ22aの全メモリブロックのうち、先頭からM個のメモリブロックのフラグ領域を"pass"に変更する。たとえば、現在のムーアマシンモジュール22m3の状態(ステップS205実行後の状態)がq'である場合、q'の状態部分集合の中には、状態(s,1)、(s,2)が含まれている。そのため、受理状態に対応するカウンタ値の最大値Mは2と決定される。この場合ムーアマシンモジュール22m3は、バッファ22aの全メモリブロックのうち、先頭から2個のメモリブロックのフラグ領域を"pass"に変更する。 In step S210, the Moore machine module 22m3 specifies all the counter values corresponding to the accepted states included in the state subset, and determines the maximum value of those counter values (hereinafter, this maximum value is expressed as M). Ask. Then, the Moore machine module 22m3 changes the flag area of the M memory blocks from the top of all the memory blocks of the buffer 22a to “pass”. For example, if the current state of the Moore machine module 22m3 (the state after execution of step S205) is q 4 ′, the state subsets of q 4 ′ include the states (s 2 , 1), (s 2 , 2) is included. Therefore, the maximum value M of the counter value corresponding to the reception state is determined to be 2. In this case, the Moore machine module 22m3 changes the flag area of the first two memory blocks of all the memory blocks of the buffer 22a to "pass".

ステップS210の後、ムーアマシンモジュール22m3は処理を終了し、フィルタモジュール22m2はステップS103の直後から処理を再開する。   After step S210, the Moore machine module 22m3 ends the process, and the filter module 22m2 restarts the process immediately after step S103.

図24のフローチャートにおいて、ステップS201〜ステップS203が、ムーアマシンMA,Nの出力関数の動作である。ステップS201〜ステップS203は、先に述べた3.2節の式(6)に示された動作が行われている。式(6)においてaとlはそれぞれ、バッファ部22aの末尾のメモリブロック22a−Nが有するデータ領域の内容とフラグ領域の内容を表している。式(6)によれば、lが"pass"であれば(図24のステップS201の判定がNOの場合)、aが出力される(図24のステップS202)。逆にlが"mask"であれば(図24のステップS201の判定がYESの場合)、ブロック文字が出力される(図24のステップS203)。 In the flowchart of FIG. 24, steps S201 to S203 are operations of the output function of the mooring machines MA and N. In steps S201 to S203, the operation shown in the equation (6) in section 3.2 is performed. In equation (6), a 1 and l 1 represent the contents of the data area and the contents of the flag area of the last memory block 22a-N of the buffer unit 22a, respectively. According to equation (6), if l 1 is "pass" (if the determination in step S201 of FIG. 24 is NO), a 1 is output (step S202 in FIG. 24). If l 1 is "mask" the contrary (if the determination in step S201 in FIG. 24 of YES), the block character is outputted (step S203 in FIG. 24).

また、図24のフローチャートにおいて、ステップS206〜ステップS210が実行されることで、先に述べた3.2節の式(5)に相当する処理が行われる。   In addition, in the flowchart of FIG. 24, by executing steps S206 to S210, the processing corresponding to the expression (5) in section 3.2 described above is performed.

以上説明したように、図24のサブプログラム22p3(または図22のムーアマシンモジュール22m3と言ってもよい)が実行されることによって、ムーアマシンの動作(状態遷移)が実現されるとともに、バッファ部22aの内容のデータを書き換えが行われる。また同時に、入力されるシーケンスデータの中で、マッチング条件に適合しないことが明らかなデータをマスクした(ブロック文字に置き換えた)データを出力することができる。   As described above, by executing the subprogram 22p3 of FIG. 24 (or the Moore machine module 22m3 of FIG. 22), the operation (state transition) of the Moore machine is realized, and the buffer unit is executed. The data of the content of 22a is rewritten. At the same time, it is possible to output data obtained by masking data (replaced by block characters) in the input sequence data that is apparently not compatible with the matching condition.

なお、上では前置情報処理回路4が、タイムスタンプの付与されていない文字列(シーケンスデータ)を受け取り、受け取った文字列のフィルタリングを行う例を説明した。つまり、前置情報処理回路4で動作するムーアマシン(ムーアマシンモジュール22m3)は、本明細書の3.2節で説明したものと同様のものであった。しかし、前置情報処理回路4で動作するムーアマシンはこれに限られない。たとえば本明細書の4.3節で説明した定義に従うムーアマシンも前置情報処理回路4で動作可能である。具体的には、タイムスタンプの付与された文字列(シーケンスデータ)についてパターンマッチングを行う場合には、前置情報処理回路4は本明細書の4.3節で説明した定義に従うムーアマシン(以下ではこれを「実時間制約付きムーアマシン」と呼ぶ)を動作させることで、パターンマッチングを行う。   In the above, an example has been described in which the prefix information processing circuit 4 receives a character string (sequence data) to which a time stamp is not added and performs filtering of the received character string. That is, the Moore machine (Moore machine module 22m3) operated by the prefix information processing circuit 4 was the same as that described in section 3.2 of this specification. However, the Moore machine operated by the front information processing circuit 4 is not limited to this. For example, a Moore machine according to the definition described in section 4.3 of this specification can also operate with the front information processing circuit 4. Specifically, when performing pattern matching on a character string (sequence data) to which a time stamp has been added, the prefix information processing circuit 4 uses a Moore machine (hereinafter, referred to as a definition) described in section 4.3 of this specification. Then, this is called a “moore machine with real-time restriction”) to perform pattern matching.

実時間制約付きムーアマシンによるフィルタリング処理は、上で説明したフィルタリング処理と概ね同様である。以下では実時間制約付きムーアマシンによるフィルタリング処理と、上で説明したフィルタリング処理の違いを主に説明し、両者に共通する説明は略す。   The filtering processing by the real-time constrained Moore machine is substantially the same as the filtering processing described above. In the following, the difference between the filtering processing by the real-time constrained Moore machine and the filtering processing described above will be mainly described, and the description common to both will be omitted.

本明細書の4.3節で説明したように、実時間制約付きムーアマシンでは状態空間のバッファ部分にフラグのみが格納される。そのため、前置情報処理回路4が実時間制約付きムーアマシンを動作させる場合には、前置情報処理回路はデータ領域を持たないバッファ22aを定義する(図16に示すバッファ22aから行221aが除去されたバッファが定義される)。   As described in section 4.3 of this specification, in the Moore machine with the real-time constraint, only the flag is stored in the buffer portion of the state space. Therefore, when the front information processing circuit 4 operates the Moore machine with the real-time constraint, the front information processing circuit defines the buffer 22a having no data area (the row 221a is removed from the buffer 22a shown in FIG. 16). Buffer is defined).

また実時間制約付きムーアマシンが動作する場合には、バッファ22aにデータが格納されないため、上で説明したムーアマシンモジュール22m3の処理と若干異なる処理が実行される。図25、図26に示すフローチャートを用いて、前置情報処理回路4が実時間制約付きムーアマシンを動作させる場合の処理の流れを説明する。   When the real-time-constrained Moore machine operates, since data is not stored in the buffer 22a, a process slightly different from the process of the Moore machine module 22m3 described above is executed. With reference to the flowcharts shown in FIGS. 25 and 26, the flow of processing when the pre-information processing circuit 4 operates the real-time-constrained Moore machine will be described.

まず、実時間制約付きムーアマシン(以下では単に「ムーアマシン」と呼ぶこともある)の処理の流れを図26を用いて説明する。図26の処理の多くは図24と共通しているので、以下では図26の各ステップのうち図24と異なる点を主に説明する。   First, the flow of processing of a real-time-constrained Moore machine (hereinafter sometimes simply referred to as "Moore machine") will be described with reference to FIG. Most of the processing in FIG. 26 is common to FIG. 24, and therefore, the following description will focus on the differences between the steps in FIG. 26 and FIG.

図26に示されているとおり、実時間制約付きムーアマシンは図24のステップS201〜S203に代えて、ステップS2020を実行する。つまり、ムーアマシンはフィルタモジュール22m2からデータ(1バイトの文字)を受け取ると、図24に示されているような処理(たとえばS201のフラグの内容の判定処理)は行わず、バッファ22aの末尾のメモリブロック(22a−N)のフラグ領域に格納されているフラグを出力する(ステップS2020)。ステップS205以降の処理は、図24の処理と同じであるので、説明を略す。   As shown in FIG. 26, the real-time constrained Moore machine executes step S2020 instead of steps S201 to S203 in FIG. That is, when the Moore machine receives the data (one-byte character) from the filter module 22m2, it does not perform the processing shown in FIG. 24 (for example, the processing of determining the content of the flag in S201), and The flag stored in the flag area of the memory block (22a-N) is output (step S2020). Since the processing after step S205 is the same as the processing in FIG. 24, the description is omitted.

実時間制約付きムーアマシンはバッファ22aにデータ領域を持たないため、図24に示した処理とは異なり、データ領域に含まれているデータの変換、データの出力は行わない。データの変換や出力は、前置情報処理回路4のフィルタモジュール22m2が行う。   Since the Moore machine with the real time constraint does not have a data area in the buffer 22a, unlike the processing shown in FIG. 24, it does not convert the data contained in the data area and output the data. Data conversion and output are performed by the filter module 22m2 of the pre-information processing circuit 4.

図25を用いて、実時間制約付きムーアマシンによるフィルタリング処理が実行されるときのフィルタモジュール22m2の処理を説明する。まず最初に、フィルタモジュール22m2は生成モジュール22m1に、ムーアマシンを生成させる(ステップS1010)。この処理は図23のステップS101と同様であるが、生成されるムーアマシンが実時間制約付きムーアマシンである点が、図23のステップS101と異なる。またステップS1010でフィルタモジュール22m2は、入力インターフェース25を介して受信するデータを一時的に保存するための記憶領域を、RAM22上に確保する。フィルタモジュール22m2が確保する記憶領域はFIFOバッファであり、またこのFIFOバッファは(N+1)個のメモリブロックを有し、各メモリブロックは1文字分のデータ(入力インターフェース25を介して受信されるデータ)を格納可能なサイズである。   The processing of the filter module 22m2 when the filtering processing is performed by the real-time constrained Moore machine will be described with reference to FIG. First, the filter module 22m2 causes the generation module 22m1 to generate a Moore machine (step S1010). This process is the same as step S101 in FIG. 23, but differs from step S101 in FIG. 23 in that the generated Moore machine is a real-time-constrained Moore machine. In step S1010, the filter module 22m2 secures a storage area on the RAM 22 for temporarily storing data received via the input interface 25. The storage area secured by the filter module 22m2 is a FIFO buffer, and this FIFO buffer has (N + 1) memory blocks, and each memory block has one character data (data received via the input interface 25). ) Can be stored.

続いてフィルタモジュール22m2は入力インターフェース25を介してシーケンスデータを受信する(ステップS1020)。ステップS1020は図23のステップS102と同様の処理である。ただしステップS1020では、フィルタモジュール22m2は受信したシーケンスデータをステップS1010で確保したFIFOバッファに格納する処理も行う。   Subsequently, the filter module 22m2 receives the sequence data via the input interface 25 (Step S1020). Step S1020 is a process similar to step S102 in FIG. However, in step S1020, the filter module 22m2 also performs processing for storing the received sequence data in the FIFO buffer secured in step S1010.

次に、フィルタモジュール22m2はステップS1020で受領したデータ(1バイトの文字)をムーアマシン(実時間制約付きムーアマシン)に渡す。実時間制約付きムーアマシンはこれに応じて図26に示す処理を実行する(ステップS1030)。先に述べたとおり、実時間制約付きムーアマシンが図26に示す処理を実行すると、バッファ22aの末尾のメモリブロック(22a−N)のフラグ領域に格納されているフラグ(passまたはmask)を出力する。   Next, the filter module 22m2 passes the data (1 byte character) received in step S1020 to the Moore machine (Moore machine with real-time constraint). The real-time constrained Moore machine executes the processing shown in FIG. 26 accordingly (step S1030). As described above, when the real-time-constrained Moore machine executes the processing shown in FIG. 26, the flag (pass or mask) stored in the flag area of the memory block (22a-N) at the end of the buffer 22a is output. I do.

次に、フィルタモジュール22m2はステップS1020及びステップS1030の処理がN回実行されたか判定する。先に述べた通り、Nはバッファサイズである。ステップS1020、ステップS1030の処理がまだN回実行されていない場合(ステップS1040:NO)、処理はステップS1020に戻る。ステップS1020、ステップS1030の処理がN回実行された場合には(ステップS1040:YES)、フィルタモジュール22m2はステップS1050以降の処理を実行する。   Next, the filter module 22m2 determines whether the processing in steps S1020 and S1030 has been performed N times. As mentioned above, N is the buffer size. If the processes of steps S1020 and S1030 have not been executed N times yet (step S1040: NO), the process returns to step S1020. When the processing of steps S1020 and S1030 has been performed N times (step S1040: YES), the filter module 22m2 performs the processing of step S1050 and subsequent steps.

ステップS1050ではフィルタモジュール22m2は、入力インターフェース25を介してシーケンスデータを受信する。これはステップS1020と同様の処理である。ステップS1050ではフィルタモジュール22m2は、ステップS1050で受領したデータ(1バイトの文字)をムーアマシンに渡す。つまりステップS1050はステップS1030と同様の処理である。   In step S1050, the filter module 22m2 receives the sequence data via the input interface 25. This is a process similar to step S1020. In step S1050, the filter module 22m2 passes the data (one-byte character) received in step S1050 to the Moore machine. That is, step S1050 is the same process as step S1030.

先に述べた通り、ステップS1060が実行されることによりムーアマシンはフラグ(passまたはmask)を出力する。ステップS1070でフィルタモジュール22m2は、ムーアマシンの出力がpassか否か判定する。ムーアマシンの出力がpassの場合(ステップS1070:YES)、フィルタモジュール22m2はFIFOバッファの末尾に格納された1文字分のデータを、出力インターフェース26を介して外部の装置に出力する(ステップS1080)。ステップS1080では(N+1)個の要素(メモリブロック)を有するFIFOバッファの末尾に格納されたデータが出力されるので、たとえばステップS1050が(N+1)回目のデータ受信処理であった場合、ステップS1080では1回目に受信したデータが出力される。一方、ステップS1070でムーアマシンの出力がmaskの場合(ステップS1070:NO)、フィルタモジュール22m2はブロック文字⊥を出力インターフェース26を介して外部の装置に出力する(ステップS1090)。   As described above, the execution of step S1060 causes the Moore machine to output a flag (pass or mask). In step S1070, the filter module 22m2 determines whether the output of the Moore machine is pass. If the output of the Moore machine is pass (step S1070: YES), the filter module 22m2 outputs the data for one character stored at the end of the FIFO buffer to an external device via the output interface 26 (step S1080). . In step S1080, data stored at the end of the FIFO buffer having (N + 1) elements (memory blocks) is output. For example, if step S1050 is the (N + 1) -th data reception process, step S1080 The first received data is output. On the other hand, if the output of the Moore machine is mask in step S1070 (step S1070: NO), the filter module 22m2 outputs the block character $ to the external device via the output interface 26 (step S1090).

続いてフィルタモジュール22m2は、シーケンスデータの入力が終了したか(文字列の終端文字まで受け付けが完了したか)判定する(ステップS1100)。ステップS1100の処理は、図23のステップS104と同様である。シーケンスデータの入力が終了していないと判断された場合(ステップS1100:NO)、処理はステップS1050に戻る。シーケンスデータの入力が終了したと判断された場合(ステップS1100:YES)、次にステップS1100が行われる。   Subsequently, the filter module 22m2 determines whether the input of the sequence data has been completed (whether the reception up to the last character of the character string has been completed) (step S1100). The processing in step S1100 is the same as step S104 in FIG. If it is determined that the input of the sequence data has not been completed (step S1100: NO), the process returns to step S1050. If it is determined that the input of the sequence data has been completed (step S1100: YES), then step S1100 is performed.

ステップS1110では、フィルタモジュール22m2はブロック文字⊥をムーアマシンに渡す。これによりムーアマシンのバッファ22aからフラグが出力される。続いてステップS1120では、ステップS1100でムーアマシンから出力されたフラグの状態(passあるいはmask)に基づいて、ステップS1070〜ステップS1090の処理を行う。   In step S1110, the filter module 22m2 passes the block character $ to the Moore machine. As a result, the flag is output from the buffer 22a of the Moore machine. Subsequently, in step S1120, the processes in steps S1070 to S1090 are performed based on the state of the flag (pass or mask) output from the moor machine in step S1100.

続いてフィルタモジュール22m2は、ステップS1110及びS1120の処理がN回行われたか判定し(ステップS1130)、ステップS1110及びS1120の処理がN回行われた場合には(ステップS1130:YES)、処理を終了する。ステップS1110及びS1120の処理がまだN回行われていない場合には(ステップS1130:NO)、フィルタモジュール22m2は再びステップS1110を実行する。   Subsequently, the filter module 22m2 determines whether the processing of steps S1110 and S1120 has been performed N times (step S1130), and if the processing of steps S1110 and S1120 has been performed N times (step S1130: YES), performs the processing. finish. If the processes of steps S1110 and S1120 have not been performed N times yet (step S1130: NO), the filter module 22m2 executes step S1110 again.

ステップS1110〜S1130の処理は、図23のステップS105と同様の目的で行われる。つまり、ステップS1110実行直前の時点では、バッファ22aのメモリブロックにN個の(未出力の)フラグが残されているので、フィルタモジュール22m2はステップS1110〜S1130の処理をN回実行することで、バッファ22aのメモリブロックに残留しているフラグを出力させ、出力されたフラグに基づいて、フィルタモジュール22m2が外部装置に出力すべきデータを決定する。   The processing in steps S1110 to S1130 is performed for the same purpose as in step S105 in FIG. That is, at the time immediately before the execution of step S1110, the N (non-output) flags are left in the memory block of the buffer 22a. Therefore, the filter module 22m2 executes the processing of steps S1110 to S1130 N times. The flag remaining in the memory block of the buffer 22a is output, and the filter module 22m2 determines data to be output to the external device based on the output flag.

上で説明した通り、実施例2に係る前置情報処理回路4は、入力されるシーケンスデータの中で、マッチング条件に明らかに一致しないデータを除去するように加工されたデータを出力することができる。ただし実施例2に係る前置情報処理回路4では、入力されるシーケンスデータ中のあるデータ列(たとえば文字列)が実際にはマッチング条件に一致しないが、そのデータ列(文字列)マッチング条件に一致するかしないか不確かである場合には、そのデータ列を除去せずに(何の加工も施さずに)出力する。   As described above, the pre-information processing circuit 4 according to the second embodiment may output data processed so as to remove data that does not clearly match the matching condition from the input sequence data. it can. However, in the prefix information processing circuit 4 according to the second embodiment, although a certain data string (for example, a character string) in the input sequence data does not actually match the matching condition, If it is uncertain whether they match or not, the data string is output without removing it (without any processing).

このケースは、たとえば図24のステップS207の判定がYESの場合に発生し得る。図17〜図21、図24を用いて例を説明する。たとえば図17に示されたオートマトンAに基づいて生成されたムーアマシン(図21に示されたq'〜q'の5状態を有し、図20(または図19)に示されたルールで状態遷移するムーアマシン)で、かつバッファサイズが2のムーアマシンを想定する。このようなムーアマシンの現在の状態がq'の時、状態q'の状態部分集合は{(s,0),(s,1),(s,2)}である。この場合、図24(とくにステップS207,S208)から分かるとおり、この時点でバッファ22a内に格納されているデータはそのまま(ブロック文字に変換されることなく)出力される。ステップS208で、バッファ22aの全メモリブロックのフラグ領域を"pass"に変更されるからである。しかしながらこの時の状態部分集合は、受理状態(s)を要素として含んでいないため、バッファ22a内に格納されているデータ列は、図17に示されたオートマトンAとして記述されているマッチング条件の一部に合致しているが、必ずしもこのマッチング条件の全体に合致しているか否か、確かではない。このような場合、実施例2に係る前置情報処理回路4はバッファ22a内に格納されているデータをそのまま(ブロック文字に変換されることなく)出力するので、マッチング条件に合致する可能性があるデータを除去してしまうことがない。 This case may occur, for example, when the determination in step S207 in FIG. 24 is YES. An example will be described with reference to FIGS. For example, a Moore machine generated based on the automaton A shown in FIG. 17 (having five states of q 0 ′ to q 4 ′ shown in FIG. 21 and a rule shown in FIG. 20 (or FIG. 19)) , And a buffer size of 2 is assumed. When the current state of such a Moore machine is q 2 ′, the state subset of state q 2 ′ is {(s 0 , 0), (s 1 , 1), (s 1 , 2)}. In this case, as can be seen from FIG. 24 (especially steps S207 and S208), the data stored in the buffer 22a at this point is output as it is (without being converted to block characters). This is because in step S208, the flag areas of all the memory blocks in the buffer 22a are changed to "pass". However, since the state subset at this time does not include the reception state (s 2 ) as an element, the data string stored in the buffer 22a has the matching condition described as the automaton A shown in FIG. , But it is not necessarily certain that the whole of the matching condition is satisfied. In such a case, the front-end information processing circuit 4 according to the second embodiment outputs the data stored in the buffer 22a as it is (without being converted into a block character), so that there is a possibility that the matching condition is met. It does not remove certain data.

また、上では前置情報処理回路4が、マッチング条件に明らかに一致しないデータを除去するために、マッチング条件に明らかに一致しないデータをブロック文字⊥に変換する例を説明したが、マッチング条件に明らかに一致しないデータを除去する方法はこれに限定されない。たとえば前置情報処理回路4が、入力されるシーケンスデータのうち、マッチング条件に明らかに一致しないデータをブロック文字⊥に変換した結果、変換後のデータ列のなかにブロック文字⊥が複数回連続して出現する文字列が含まれていた場合には、たとえば前置情報処理回路4はこの文字列を「ブロック文字⊥とその出現回数」の組に変換してから外部の装置に出力してもよい。具体的には、前置情報処理回路4が、上で説明した処理(図23,図24)を行うことにより、文字列"abbbbbb"を"ab⊥⊥⊥⊥⊥"に変換した後、"ab⊥⊥⊥⊥⊥"を"ab⊥5"と変換して、外部の装置に出力してもよい(つまり、"⊥5"は、ブロック文字⊥が5文字連続していることを表す)。このような変換を行うことで、データサイズが実質的に圧縮されるため、外部の装置に出力されるデータ量を削減することができる。   In the above, the example has been described in which the prefix information processing circuit 4 converts data that does not clearly match the matching condition into the block character ⊥ in order to remove data that does not clearly match the matching condition. The method of removing data that does not clearly match is not limited to this. For example, as a result of the prefix information processing circuit 4 converting data which clearly does not match the matching condition in the input sequence data into block characters ⊥, the converted data sequence has block characters 複数 repeated a plurality of times. If a character string that appears in the form of a character string is included, for example, the prefix information processing circuit 4 may convert this character string into a set of “block character ⊥ and the number of appearances thereof” and then output it to an external device. Good. Specifically, the prefix information processing circuit 4 converts the character string "abbbbbb" to "ab @" by performing the above-described processing (FIGS. 23 and 24), ab @ "may be converted to" ab @ 5 "and output to an external device (that is," $ 5 "indicates that five consecutive block characters $). . By performing such conversion, the data size is substantially reduced, so that the amount of data output to an external device can be reduced.

図27は実施例2に係る前置情報処理回路4を構成するときの、リアルタイムオートマトンの決定化処理を示すフローチャートである。   FIG. 27 is a flowchart illustrating a real-time automaton determinizing process when configuring the pre-information processing circuit 4 according to the second embodiment.

図27のステップS61〜S63において、オートマトンにおける状態s から状態空間Sへの定義、現在の状態空間Scurr 及び状態空間Sの初期化、並びに出力関数Λ の初期化の処理を行う。ステップS64〜S75において、現在の状態空間Scurr が空でないときにステップS67〜S74の処理を実行する。また、ステップS65〜S72において、各状態s∈Scurr についてステップS67〜S69の処理を実行する。さらに、ステップS66〜S71において、各文字a∈Σについて、ステップS67〜S69の処理を実行する。またさらに、ステップS68〜S70において、各区間I'∈Jについて(なお、JはステップS67に示すように、区間の集合の最疎分割である)ステップS69の処理を実行する。ステップS76において、フィルタリング結果の状態空間S を状態空間Sの部分集合であって、フィルタリング結果の状態空間Sとの交叉が非空であるものと定義して当該決定化処理を終了する。 In steps S61 to S63 of FIG. 27, the definition of the state s 0 d to the state space S 0 in the automaton, the initialization of the current state space S curr d and the state space S d , and the initialization of the output function r r d Perform processing. In step S64~S75, current state-space S curr d executes step S67~S74 when not empty. In steps S65 to S72, the processes in steps S67 to S69 are executed for each state s d S curr d . Further, in steps S66 to S71, the processing of steps S67 to S69 is executed for each character a ^. Further, in steps S68 to S70, the processing of step S69 is executed for each section I′∈J (J is the least sparse division of a set of sections as shown in step S67). In step S76, the state space S F d of the filtering result is defined as a subset of the state space S d and the intersection with the state space S F of the filtering result is non-empty, and the determinizing process ends. I do.

以上説明したように、図27の決定化処理を実行することで、非決定的リアルタイムタイムを、決定的オートマトンに変換することができる。   As described above, the non-deterministic real-time can be converted to a deterministic automaton by executing the determinizing process of FIG.

図28は実施例2に係る前置情報処理回路4を構成するときの、実時間制約付きオートマトンをリアルタイムオートマトンに近似させる近似処理を示すフローチャートである。なお、パラメータの上付き文字のrtリアルタイムタイムのパラメータを表す。   FIG. 28 is a flowchart illustrating an approximation process for approximating a real-time constrained automaton to a real-time automaton when configuring the prefix information processing circuit 4 according to the second embodiment. Note that the rt real time parameter of the superscript character of the parameter is shown.

図28のステップS81〜S82において、オートマトンにおける状態s rtの定義、状態空間Srt,Srt currの初期化処理を行う。ステップS83〜S99において、現在の状態空間Srt currが空でないときにステップS84〜S98の処理を実行する。また、ステップS85〜S96において、各(s,Z)∈Srt currについてステップS87〜S94の処理を実行する。さらに、ステップS86〜S95において、各(s;a;δ,λ,s')∈Σについて、ステップS87〜S94の処理を実行する。なお、ステップS87におけるup(Z)は時間経過を表す。また、ステップS89におけるreset(Z',λ)はλに含まれるクロック変数の初期化を表す。さらに、ステップS94等におけるSrt nextはリアルタイムの状態空間Srtの次に追加すべき次の状態空間を表す。またさらに、ステップS90におけるDBMのゾーンは公知のDifference Bound Matrixで定義されたゾーンである。ステップS100では、フィルタリング結果の状態空間Srt を{(s,Z)∈Srt|s∈S}とすることで、当該近似処理を終了する。 In step S81~S82 in Figure 28, the definition of the state s 0 rt in automaton, state space S rt, the initialization processing of S rt curr performed. In steps S83 to S99, when the current state space S rt curr is not empty, the processing in steps S84 to S98 is executed. In steps S85 to S96, the processing of steps S87 to S94 is executed for each (s, Z) ZS rt curr . Further, in steps S86 to S95, the processing of steps S87 to S94 is executed for each (s; a; δ, λ, s ′)}. Note that up (Z) in step S87 represents the passage of time. Also, reset (Z ′, λ) in step S89 represents initialization of a clock variable included in λ. Further, S rt next in step S94 and the like represents the next state space to be added after the real-time state space S rt . Furthermore, the zone of the DBM in step S90 is a zone defined by a well-known Difference Bound Matrix. In step S100, the state space S rt F of the filtering result is set to {(s, Z)} S rt | s {S F }, and the approximation processing ends.

以上説明したように、図28の近似処理を実行することで、実時間制約付きオートマトンをリアルタイムオートマトンに近似させることができる。   As described above, by executing the approximation processing in FIG. 28, the automaton with the real-time constraint can be approximated to the real-time automaton.

異常時の自動停止機構.
図29は実施例3に係る異常時の自動停止機構を有する自動車制御システムの構成例を示すブロック図である。
Automatic stop mechanism when an error occurs.
FIG. 29 is a block diagram illustrating a configuration example of an automobile control system having an automatic stop mechanism at the time of abnormality according to the third embodiment.

図29において、自動車制御システムは、センサ装置1A及び1Bがそれぞれ通信回線10a,10bを介して自動車コントローラ30に接続されて構成される。   In FIG. 29, the vehicle control system is configured by connecting sensor devices 1A and 1B to a vehicle controller 30 via communication lines 10a and 10b, respectively.

センサ装置1Aにおいて、車速センサ3aにより検出された車速と、加速度センサ3bにより検出された角速度とが前置情報処理回路4aに入力される。前置情報処理回路4aは実施例2に係る前置情報処理回路4と同様の構成を有する。また前置情報処理回路4aは、入力される車速及び加速度の実時間付きシーケンスデータについて、上記マッチング条件にマッチングしないことが容易に分かるデータを除去するように加工し、加工後の実時間付きシーケンスデータを通信回線10aを介して後置情報処理回路5に送信する。   In the sensor device 1A, the vehicle speed detected by the vehicle speed sensor 3a and the angular speed detected by the acceleration sensor 3b are input to the front information processing circuit 4a. The prefix information processing circuit 4a has the same configuration as the prefix information processing circuit 4 according to the second embodiment. The pre-information processing circuit 4a processes the input real-time sequence data of vehicle speed and acceleration so as to remove data that can be easily recognized as not matching the above-mentioned matching condition. The data is transmitted to the post-processing circuit 5 via the communication line 10a.

センサ装置1Bにおいて、勾配センサ3cにより検出された勾配と、質量センサ3dにより検出された質量と、アクチュエータへの入力データ部3eに入力された入力データ(緊急停止指示データ)とが前置情報処理回路4bに入力される。前置情報処理回路4bも、実施例2に係る前置情報処理回路4と同様の構成を有する。前置情報処理回路4bは、入力される勾配、質量及び入力データの実時間付きシーケンスデータについて、上記マッチング条件にマッチングしないことが容易に分かるデータを除去するように加工し、加工後の実時間付きシーケンスデータを通信回線10bを介して後置情報処理回路5に送信する。   In the sensor device 1B, the gradient detected by the gradient sensor 3c, the mass detected by the mass sensor 3d, and the input data (emergency stop instruction data) input to the input data unit 3e to the actuator are pre-processed. Input to the circuit 4b. The prefix information processing circuit 4b has the same configuration as the prefix information processing circuit 4 according to the second embodiment. The pre-information processing circuit 4b processes the input gradient data, the mass, and the real-time sequence data of the input data so as to remove data that can be easily recognized as not matching the above-described matching condition, and processes the real-time data after the processing. The attached sequence data is transmitted to the downstream information processing circuit 5 via the communication line 10b.

自動車コントローラ30において、後置情報処理回路5は前置情報処理回路4aによって加工されたシーケンスデータと前置情報処理回路4bによって加工されたシーケンスデータとを受信する。そして後置情報処理回路5は、これらのシーケンスデータについて上述のマッチング条件(前置情報処理回路4aと前置情報処理回路4bで用いられたマッチング条件)にマッチングするシーケンスデータを抽出する処理を行って、抽出したシーケンスデータを故障検出部31に出力する。故障検出部31は入力されるシーケンスデータに基づいて所定の故障条件にマッチングするか否かを判断し、当該故障条件にマッチングするときにその旨の情報を自動車運転制御部32に出力することで、例えば自動車を緊急停止するなどの所定の制御処理を行う。   In the vehicle controller 30, the rear information processing circuit 5 receives the sequence data processed by the front information processing circuit 4a and the sequence data processed by the front information processing circuit 4b. Then, the post-processing circuit 5 performs a process of extracting sequence data that matches the above-described matching conditions (matching conditions used in the pre-processing circuit 4a and the pre-processing circuit 4b) for these sequence data. Then, the extracted sequence data is output to the failure detection unit 31. The failure detection unit 31 determines whether or not to match a predetermined failure condition based on the input sequence data, and outputs information to that effect to the vehicle operation control unit 32 when matching to the failure condition. For example, predetermined control processing such as emergency stop of a car is performed.

先に述べた通り前置情報処理回路4bは、マッチング条件の一部に合致しているが、必ずしもマッチング条件の全体に合致しているか否か確かではないデータについては加工しない(除去しない)。そのため後置情報処理回路5が行うデータの抽出処理では、前置情報処理回路4aや前置情報処理回路4bから受領した、加工されたシーケンスデータに対して、上述のマッチング条件に合致するデータをすべて抽出する処理が行われる。具体的には、たとえば前置情報処理回路4aや前置情報処理回路4bが、一部の文字(マッチング条件に明らかに一致しない文字)をブロック文字⊥に書き換えた文字列(シーケンスデータ)を後置情報処理回路5に送信する場合、後置情報処理回路5は文字列中からブロック文字を取り除くだけでなく、ブロック文字⊥に書き換えられていない文字列の中にマッチング条件に合致する文字列が含まれているか判定し、マッチング条件に合致する文字列を抽出する処理も行う。   As described above, the pre-information processing circuit 4b does not process (does not remove) data that matches a part of the matching conditions but does not necessarily determine whether the entire matching condition is satisfied. Therefore, in the data extraction processing performed by the post-processing circuit 5, the data that matches the above-described matching condition is compared with the processed sequence data received from the pre-processing circuit 4 a or the pre-processing circuit 4 b. The process of extracting all is performed. Specifically, for example, the prefix information processing circuit 4a or the prefix information processing circuit 4b converts a character string (sequence data) in which some characters (characters that clearly do not match the matching conditions) are rewritten into block characters 後. When transmitting to the post-processing information processing circuit 5, the post-processing information processing circuit 5 not only removes the block character from the character string, but also detects a character string that matches the matching condition among the character strings that have not been rewritten into the block character ⊥. It also determines whether the character string is included and extracts a character string that matches the matching condition.

なお、後置情報処理回路5がマッチング条件に合致する文字列(シーケンスデータ)を抽出するための処理負荷は、図29のように前置情報処理回路4aや前置情報処理回路4bが自動車制御システムに設けられている場合は、前置情報処理回路4aや前置情報処理回路4bが設けられていない場合に比べると低くなる。前置情報処理回路4aや前置情報処理回路4bによって、明らかにマッチング条件に合致しないデータ(文字列)は除去される(ブロック文字に変換される)ため、後置情報処理回路5で検索対象とするデータ量は大きく削減されるからである。   It should be noted that the processing load for the post-information processing circuit 5 to extract a character string (sequence data) that matches the matching condition is such that the front information processing circuit 4a and the front information processing circuit 4b perform vehicle control as shown in FIG. In the case where the information processing circuit is provided in the system, it is lower than in the case where the preceding information processing circuit 4a and the preceding information processing circuit 4b are not provided. The data (character string) that clearly does not match the matching condition is removed (converted into a block character) by the prefix information processing circuit 4a or the prefix information processing circuit 4b. Is significantly reduced.

以上説明したように、実施例3によれば、走行中の自動車のログデータ(車速、加速度、勾配、質量など)を、当該自動車制御システムを用いることによりモニタリングすることで故障を検知し、緊急停止する必要がある場合には自動車運転制御部32に適切な入力を与えることで緊急停止する。特に、前置情報処理回路4a,4bをそれぞれセンサ装置1A,1Bに取り付けることにより、通信回線10a,10bにおけるデータ転送量を削減し、より多くのデータを扱うことができる。   As described above, according to the third embodiment, a failure is detected by monitoring log data (vehicle speed, acceleration, gradient, mass, and the like) of a running vehicle by using the vehicle control system, and a failure is detected. If it is necessary to stop the vehicle, an appropriate input is given to the vehicle operation control unit 32 to perform an emergency stop. In particular, by attaching the front information processing circuits 4a and 4b to the sensor devices 1A and 1B, respectively, it is possible to reduce the data transfer amount in the communication lines 10a and 10b and handle more data.

セミコネクテッドカーの走行経路最適化.
図30は実施例4に係るセミコネクテッドカーの走行経路最適化機構を有する自動車制御システムの構成例を示すブロック図である。自動車制御システムは、自動車40が通信回線10c,10dを含むネットワークを介してサーバ装置50に接続されて構成される。ここで、セミコネクテッドカーとは、自動車40の制御部が常時サーバ装置50に接続せずに、必要に応じて接続することで自動車40の走行を制御するものである。
Route optimization for semi-connected cars.
FIG. 30 is a block diagram illustrating a configuration example of an automobile control system having a traveling route optimization mechanism for a semi-connected car according to the fourth embodiment. The vehicle control system is configured by connecting a vehicle 40 to a server device 50 via a network including communication lines 10c and 10d. Here, the semi-connected car controls the running of the car 40 by connecting the control unit of the car 40 as necessary without connecting to the server device 50 at all times.

自動車40において、アクセルセンサ3fにより検出されたアクセルデータと、ブレーキペダルセンサ3gにより検出されたアクセルペダルデータは駆動トルク推定部33に入力される。駆動トルク推定部33は、入力されるアクセルデータとアクセルペダルデータとに基づいて公知の方法により駆動トルクを推定して推定車速算出部34に出力する。また、勾配センサ3cにより検出された勾配と、質量センサ3dにより検出された質量とは推定車速算出部34に入力される。推定車速算出部34は入力される3つのデータに基づいて公知の方法により推定車速を算出して偏差量算出部35に出力する。偏差量算出部35は、算出された推定車速を、車速センサ3aにより検出された車速と比較することで、車速の偏差で道路状態を推定できる偏差量を算出して前置情報処理回路4cに出力する。前置情報処理回路4cは実施例2に係る前置情報処理回路4と同様の構成を有する。また前置情報処理回路4cは、入力される偏差量の実時間付きシーケンスデータについて、上記マッチング条件にマッチングしないことが容易に分かるデータを除去するように加工し、加工後の実時間付きシーケンスデータを通信回線10cを介してサーバ装置50の後置情報処理回路5に送信する。   In the automobile 40, the accelerator data detected by the accelerator sensor 3f and the accelerator pedal data detected by the brake pedal sensor 3g are input to the drive torque estimating unit 33. Driving torque estimating section 33 estimates the driving torque based on the input accelerator data and accelerator pedal data by a known method, and outputs the estimated driving torque to estimated vehicle speed calculating section 34. The gradient detected by the gradient sensor 3c and the mass detected by the mass sensor 3d are input to the estimated vehicle speed calculation unit 34. The estimated vehicle speed calculator 34 calculates the estimated vehicle speed by a known method based on the input three data, and outputs the calculated vehicle speed to the deviation amount calculator 35. The deviation amount calculation unit 35 compares the calculated estimated vehicle speed with the vehicle speed detected by the vehicle speed sensor 3a to calculate a deviation amount capable of estimating a road condition based on the deviation of the vehicle speed, and sends the calculated deviation amount to the front information processing circuit 4c. Output. The prefix information processing circuit 4c has the same configuration as the prefix information processing circuit 4 according to the second embodiment. The prefix information processing circuit 4c processes the input real-time sequence data of the deviation amount so as to remove data that can be easily recognized as not matching the above-mentioned matching condition. Is transmitted to the downstream information processing circuit 5 of the server device 50 via the communication line 10c.

サーバ装置50において、後置情報処理回路5は前置情報処理回路4cによって加工されたシーケンスデータを受信し、上記のマッチング条件にマッチングするシーケンスデータを抽出して、抽出したシーケンスデータを異常な道路状態検出部51に出力する。異常な動作状態検出部51は入力されるシーケンスデータに基づいて所定の「異常な道路状態」(例えば、偏差量が所定のしきい値以上で異常な道路状態と判定)の条件にマッチングするか否かを判断し、当該条件にマッチングするときにその旨の情報を走行プラン制御部52に出力する。走行プラン制御部52は入力される情報に基づいて好ましくない道路状況を検知し、道路状況に応じて走行プランの最適化を行い、その最適化された走行プランのデータを通信回線10dを介して自動車40の走行制御部36に出力することで、自動車40の走行を最適化する。   In the server device 50, the post information processing circuit 5 receives the sequence data processed by the front information processing circuit 4c, extracts sequence data matching the above matching condition, and converts the extracted sequence data into an abnormal road. Output to the state detection unit 51. The abnormal operation state detection unit 51 determines whether to match a predetermined “abnormal road state” condition (for example, the deviation amount is equal to or more than a predetermined threshold value and is determined to be an abnormal road state) based on the input sequence data. It is determined whether or not the condition is met, and when the condition is matched, information to that effect is output to the traveling plan control unit 52. The traveling plan control unit 52 detects an unfavorable road condition based on the input information, optimizes the traveling plan according to the road condition, and transmits the data of the optimized traveling plan via the communication line 10d. The driving of the automobile 40 is optimized by outputting to the traveling control unit 36 of the automobile 40.

以上説明したように、実施例4によれば、走行中のセミコネクテッドカーの走行ログ(アクセルデータ、ブレーキペダルデータ、勾配、質量、車速と、それに基づく所定の算出データ)をサーバ装置50に適宜通信回線10cを介して送信する。ここで、異常な道路状態検出部51によりそのデータをモニタリングすることで好ましくない道路状況を検知し、道路状況に応じて走行プランの最適化を行なう。ここで、セミコネクテッドカーである自動車40において前置情報処理回路4cを設け、サーバ装置50において後置情報処理回路5を設けることで、データ転送量を削減し、例えば無線通信の状況の良くない環境下においても適切に動作することができる。   As described above, according to the fourth embodiment, the running log (accelerator data, brake pedal data, gradient, mass, vehicle speed, and predetermined calculation data based thereon) of the running semi-connected car is appropriately transmitted to the server device 50. It is transmitted via the communication line 10c. Here, an unfavorable road condition is detected by monitoring the data by the abnormal road condition detecting unit 51, and the traveling plan is optimized according to the road condition. Here, by providing the front information processing circuit 4c in the automobile 40, which is a semi-connected car, and providing the rear information processing circuit 5 in the server device 50, the data transfer amount is reduced, and for example, the situation of wireless communication is not good. It can operate properly even in an environment.

サーバ装置への攻撃のモニタリングとアクセス遮断.
図31は実施例5に係るサーバ装置への攻撃のモニタリングとアクセス遮断機構を有する通信システムの構成例を示すブロック図である。通信システムは、サーバ装置60と、ルータ装置70とが通信回線10eを含むネットワークを介して接続されて構成される。
Monitoring attacks on server devices and blocking access.
FIG. 31 is a block diagram illustrating a configuration example of a communication system having a mechanism for monitoring an attack on a server device and blocking access according to the fifth embodiment. The communication system is configured by connecting a server device 60 and a router device 70 via a network including a communication line 10e.

サーバ装置60において、アクセスログ収集部61は、サーバ装置60に外部からのアクセスについてのログ(アクセス元情報、時刻等)を収集し、そのシーケンスデータを前置情報処理回路62に出力する。前置情報処理回路62は実施例2に係る前置情報処理回路4と同様の構成を有する。前置情報処理回路62は、入力される実時間付きシーケンスデータについて、上記マッチング条件にマッチングしないことが容易に分かるデータを除去するように加工し、加工後の実時間付きシーケンスデータを後置情報処理回路63に送信する。後置情報処理回路63は入力される実時間付きシーケンスデータを受信し、上記のマッチング条件にマッチングするシーケンスデータを抽出して、抽出したシーケンスデータを攻撃検出部64に出力する。攻撃検出部64は入力されるシーケンスデータに基づいて所定のしきい値データを参照してサーバ装置60への攻撃的なアクセスを検出し、検出されたアクセス情報を通信回線10eを介してルータ装置70のアクセス制御部71に送信する。これに応答して、アクセス制御部71は入力される検出されたアクセス情報に基づいてサーバ装置60へのアクセスを遮断するように制御する。   In the server device 60, the access log collection unit 61 collects a log (access source information, time, etc.) regarding an external access to the server device 60, and outputs the sequence data to the prefix information processing circuit 62. The prefix information processing circuit 62 has the same configuration as the prefix information processing circuit 4 according to the second embodiment. The pre-information processing circuit 62 processes the input real-time sequence data so as to remove data that is easily recognized as not matching the above matching condition, and converts the processed real-time sequence data to post-information. This is transmitted to the processing circuit 63. The post-information processing circuit 63 receives the input sequence data with real time, extracts sequence data matching the above-described matching condition, and outputs the extracted sequence data to the attack detection unit 64. The attack detection unit 64 detects aggressive access to the server device 60 with reference to predetermined threshold data based on the input sequence data, and transmits the detected access information to the router device via the communication line 10e. 70 to the access control unit 71. In response to this, the access control unit 71 performs control to block access to the server device 60 based on the detected access information input.

以上説明したように、実施例5によれば、WWWなどのサーバ装置60において外部からの通信ログを前置情報処理回路62及び後置情報処理回路63を含む実時間条件抽出装置を用いてモニタリングすることで外部からの攻撃を検知し、ルータに適切な入力を与えることで当該攻撃者からのアクセスを遮断する。当該実時間条件抽出装置の実時間データフィルタ部を用いることで、データ処理に必要なCPU時間を削減し、サーバ装置60の本来の動作を損なわずにモニタリングを行なうことができる。   As described above, according to the fifth embodiment, in the server device 60 such as WWW, an external communication log is monitored using the real-time condition extraction device including the front information processing circuit 62 and the rear information processing circuit 63. By doing so, an external attack is detected, and an appropriate input is given to the router to block access from the attacker. By using the real-time data filter unit of the real-time condition extraction device, the CPU time required for data processing can be reduced and monitoring can be performed without impairing the original operation of the server device 60.

以上の実施形態及び実施例においては、前置情報処理回路4は、入力されるイベントのシーケンスデータに関する所定のマッチング条件を記述したオートマトンに基づいてムーアマシンを生成し、生成されたムーアマシンを用いて、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去するようにフィルタリングしてフィルタリング結果のシーケンスデータを出力する。しかし、本発明はこれに限らず、フィルタリングのために生成するモデルはムーアマシンに限らず、ミーリマシン(Mealy Machine)などの種々の有限状態機械であってもよい。   In the above embodiments and examples, the pre-information processing circuit 4 generates a Moore machine based on an automaton describing a predetermined matching condition regarding sequence data of an input event, and uses the generated Moore machine. And filtering the sequence data so as to substantially remove data that does not match the matching condition, and outputs the filtered sequence data. However, the present invention is not limited to this, and the model generated for filtering is not limited to a Moore machine, but may be various finite state machines such as a Mealy machine.

本実施形態の特徴と特許文献2及び3との相違点. Difference between features of this embodiment and Patent Documents 2 and 3.

(1)特許文献2
特許文献2においては、並列動作を記述可能なプログラム言語を用いて複数のデバイスを定義したプログラム記述(1)を入力し、入力されたプログラム記述を中間表現に変換し(S2)、リアルタイム制約を満たすパラメータを生成する生成されたパラメータに基づいて、ハードウェア記述言語に基づく中間表現(S3)および回路記述を合成する(S4)。中間式は、同時制御フローフラグ、同時パラメータを有する時間オートマトンなどである。パラメトリックモデル検査は、パラメータ生成のために実行される。プログラム記述は、runメソッドを使用してデバイスを定義し、バリア同期を使用してデバイスのクロック同期を定義します。これにより、リアルタイム制約に合ったバスシステムを設計することができる。
(1) Patent Document 2
In Patent Document 2, a program description (1) in which a plurality of devices are defined using a programming language capable of describing parallel operations is input, the input program description is converted into an intermediate expression (S2), and real-time constraints are set. The intermediate representation (S3) based on the hardware description language and the circuit description are synthesized (S4) based on the generated parameters for generating the parameters to be satisfied. Intermediate expressions are simultaneous control flow flags, timed automata with simultaneous parameters, and the like. Parametric model checking is performed for parameter generation. The program description uses the run method to define the device, and uses barrier synchronization to define the clock synchronization of the device. As a result, a bus system that meets real-time restrictions can be designed.

特許文献2では、特に、JAVA(登録商標)等の並列動作を記述できる言語から回路設計を行う際、実時間制約を満たすようにバスシステムを効率よく設計するため、設計自動化のための検証プロセスの前処理としてモデル化を行う。その一工程として、コンカレントなコントロール・フロー・グラフ(C−CFG)からコンカレントなパラメータ付き時間オートマトン(C−TNFA)へ、さらにパラメータ付き時間オートマトン(TNFA)へと変換する。C−CFGからC−TNFA変換時に、後段の検証プロセスにおける前提に合わない状態遷移を削除する処理を行い、C−TNFAからTNFAへの変換時に、バス権をとる必要がない動作の並列実行で遷移時間の上限を設け、上限を満たさない状態を削除する処理を行う。   Patent Document 2 discloses a verification process for design automation in order to efficiently design a bus system so as to satisfy real-time constraints, particularly when designing a circuit from a language capable of describing parallel operation such as JAVA (registered trademark). Is modeled as preprocessing of. As one of the steps, a concurrent control flow graph (C-CFG) is converted into a concurrent timed automaton with parameters (C-TNFA) and further into a timed automaton with parameters (TNFA). At the time of conversion from C-CFG to C-TNFA, a process for deleting a state transition that does not meet the premise in the subsequent verification process is performed, and at the time of conversion from C-TNFA to TNFA, an operation that does not need to take the bus right is performed in parallel. An upper limit of the transition time is set, and a process of deleting a state that does not satisfy the upper limit is performed.

特許文献2では、前処理での後段処理をふまえたマスク処理を開示するが、オートマトンでの時間制約をふまえた決定化やバッファ最適化など本発明の具体的手法の開示はない。   Patent Literature 2 discloses mask processing based on post-processing in preprocessing, but does not disclose specific techniques of the present invention, such as determinism and buffer optimization based on time constraints in an automaton.

(2)特許文献3
特許文献3の方法は、ソフトウェアのソースコードを検査コードに変換するためのソースコードをコンピュータを用いて変換する方法であって、ソフトウェアのソースコードを入力するステップと、複数の異なる変換規則を入力するステップと、プロセス性能に関する制約である非機能ルールを入力するステップと、前記ソースコードを、前記複数の異なる変換規則と前記非機能規則とによって検証ツールの入力言語で記述された非機能検査コードに変換するステップとを含む。
(2) Patent Document 3
The method disclosed in Patent Document 3 is a method of converting a source code for converting software source code into an inspection code by using a computer. The method includes inputting a software source code and inputting a plurality of different conversion rules. And inputting a non-functional rule that is a constraint on process performance, and a non-functional check code written in an input language of a verification tool by using the plurality of different conversion rules and the non-functional rule. To the conversion.

特許文献3では、特に、ソフトウェア検査の前段の処理としてソフトウェアの振る舞いを入力言語(検査コード)に変換する際、ソフトウェアの各部品(機能)に実行環境による処理時間を付与した時間オートマトンに変換し、繰り返し実行時のみの特定の不具合がある場合にその繰り返し部分を除去し、状態数を削減しながらも他の不具合を検出可能として、計算時間が大きくなりすぎる状態爆発を回避する技術を開示している。   In Patent Literature 3, particularly, when converting the behavior of software into an input language (inspection code) as a process prior to software inspection, the software is converted into a time automaton in which each component (function) of the software is provided with a processing time according to an execution environment. In the case where there is a specific defect only at the time of repeated execution, a technology that removes the repeated portion and enables detection of other defects while reducing the number of states to avoid a state explosion that increases the calculation time too much is disclosed. ing.

しかしながら、特許文献3では、前処理でのマスク処理を開示するが、オートマトンでの時間制約をふまえた決定化やバッファ最適化など本発明の具体的手法の開示はない。   However, Patent Document 3 discloses mask processing in preprocessing, but does not disclose a specific method of the present invention such as determinization or buffer optimization based on time constraints in an automaton.

以上詳述したように、本発明に係る情報処理装置及び方法によれば、従来例に係る時系列相関抽出装置に比較して、効率的に処理することができる。   As described above in detail, according to the information processing apparatus and method according to the present invention, it is possible to perform processing more efficiently than the time-series correlation extraction apparatus according to the conventional example.

1,1A,1B センサ装置
2 モニタ装置
3 センサ
3a 車速センサ
3b 加速度センサ
3c 勾配センサ
3d 質量センサ
3e アクチュエータへの入力データ部
3f アクセルセンサ
3g ブレーキペダルセンサ
4,4a,4b,4c 前置情報処理回路
5 後置情報処理回路
6 表示部
7 フィルタ部
8 パターンマッチング部
10,10a〜10e 通信回線
11 フィルタ部
12 マスキング適用部
20 CPU
21 ROM
22 RAM
22a バッファ部
22b 非バッファ部
23 操作部
24 表示部
25 入力インターフェース
26 出力インターフェース
27 バス
30 自動車コントローラ
31 故障検出部
32 自動車運転制御部
33 駆動トルク推定部
34 推定車速算出部
35 偏差量算出部
36 走行制御部
40 自動車
50 サーバ装置
51 異常な道路状態検出部
52 走行プラン制御部
60 サーバ装置
61 アクセスログ収集部
62 前置情報処理回路
63 後置情報処理回路
64 攻撃検出部
70 ルータ装置
71 アクセス制御部
1, 1A, 1B Sensor device 2 Monitoring device 3 Sensor 3a Vehicle speed sensor 3b Acceleration sensor 3c Gradient sensor 3d Mass sensor 3e Input data section to actuator 3f Accelerator sensor 3g Brake pedal sensor 4, 4a, 4b, 4c Pre-processing information processing circuit 5 Post-processing information circuit 6 Display unit 7 Filter unit 8 Pattern matching unit 10, 10a to 10e Communication line 11 Filter unit 12 Masking application unit 20 CPU
21 ROM
22 RAM
22a Buffer unit 22b Non-buffer unit 23 Operation unit 24 Display unit 25 Input interface 26 Output interface 27 Bus 30 Car controller 31 Failure detection unit 32 Car operation control unit 33 Drive torque estimation unit 34 Estimated vehicle speed calculation unit 35 Deviation amount calculation unit 36 Running Control unit 40 Automobile 50 Server device 51 Abnormal road condition detection unit 52 Driving plan control unit 60 Server device 61 Access log collection unit 62 Pre-information processing circuit 63 Post-information processing circuit 64 Attack detection unit 70 Router 71 Access control unit

Claims (16)

入力されるイベントのシーケンスデータに関する所定のマッチング条件に基づいて有限状態機械を生成し、生成された有限状態機械を用いて、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去するように加工されたシーケンスデータを出力する情報処理回路を備えたことを特徴とする情報処理装置。   A finite state machine is generated based on a predetermined matching condition regarding sequence data of an input event, and data that does not match the matching condition is substantially removed from the sequence data using the generated finite state machine. An information processing apparatus, comprising: an information processing circuit that outputs sequence data that has been processed into an image. 前記シーケンスデータが実時間のタイムスタンプ付きイベントのシーケンスデータで、前記マッチング条件は実時間制約付きオートマトンとして記述されている、請求項1記載の情報処理装置。   The information processing apparatus according to claim 1, wherein the sequence data is sequence data of a real-time time-stamped event, and the matching condition is described as a real-time restricted automaton. 前記有限状態機械は、N個のメモリブロックを有するFIFOバッファと、前記有限状態機械の状態遷移のルールを記述した情報を有し、前記N個のメモリブロックのそれぞれは、第1状態と第2状態のいずれかを表すフラグを格納する領域を有する請求項2記載の情報処理装置。   The finite state machine has a FIFO buffer having N memory blocks and information describing rules of state transitions of the finite state machine. Each of the N memory blocks has a first state and a second state. 3. The information processing apparatus according to claim 2, further comprising an area for storing a flag indicating one of the states. 前記有限状態機械は、前記シーケンスデータの一単位のデータの入力を受け付けるたびに、
前記バッファの末尾のメモリブロックの内容を取り出し、
前記受け付けたデータと前記ルールとに基づいて、前記有限状態機械の状態を遷移させ、
前記バッファの先頭のメモリブロックに、前記受け付けたデータに対応するフラグの初期値として、第2状態を格納し、
遷移後の前記有限状態機械の状態に応じて、前記バッファ内の各メモリブロックに格納されているフラグの更新を行う、
請求項3に記載の情報処理装置。
Each time the finite state machine receives an input of one unit of data of the sequence data,
Fetch the contents of the memory block at the end of the buffer,
Based on the received data and the rules, transition the state of the finite state machine,
A second state is stored in a first memory block of the buffer as an initial value of a flag corresponding to the received data,
Update the flag stored in each memory block in the buffer according to the state of the finite state machine after the transition,
The information processing device according to claim 3.
前記有限状態機械がとり得る状態の各々は、前記オートマトンがとり得る状態sと、初期状態から前記状態sに達するまでに要する遷移回数に相当するカウンタnの組(s,n)の集合{(s,n),(s,n),...(s,n)}からなり(kは1以上の整数)、
前記情報処理回路は、
(1)前記有限状態機械の状態を遷移させた後の状態に含まれる、前記組の集合の中に、前記カウンタの値がNである組が存在する場合、前記バッファ中のN個のメモリブロックのフラグをすべて第1状態に変更し、
(2)前記有限状態機械の状態が含む前記状態s,s,,...sの中に受理状態が含まれる場合、受理状態の前記状態に対応付けられた前記カウンタの最大値Mを特定し、前記バッファの先頭からM個のメモリブロックのフラグを第1状態に変更する、
請求項4記載の情報処理装置。
Each of the possible states of the finite state machine is a set s (s) of a set (s, n) of a state s that the automaton can take and a counter n corresponding to the number of transitions required from the initial state to the state s. s 1 , n 1 ), (s 2 , n 2 ),... (s k , n k )} (k is an integer of 1 or more),
The information processing circuit,
(1) If there is a set whose counter value is N in the set of sets included in the state after the state transition of the finite state machine, N memories in the buffer Change all the flags of the block to the first state,
(2) the finite state the state s 1 the machine state includes, s 2 ,, ... if it contains an accepting state in the s k, the maximum value of the counter associated with the state of accepting states M, and change the flags of the M memory blocks from the head of the buffer to the first state;
The information processing device according to claim 4.
前記シーケンスデータは、前記一単位のデータごとにタイムスタンプが付された、タイムスタンプ付き文字列であり、前記文字列を構成する文字は、所定の文字セット内の要素であり、
前記有限状態機械は前記一単位のデータの入力を受け付けるたびに、前記バッファの末尾のメモリブロックに記憶されているフラグを出力し、
前記情報処理回路は、
前記有限状態機械が出力したフラグが第1状態である場合、前記有限状態機械が出力したフラグに対応する一単位分のデータを外部に出力し、
前記有限状態機械が出力したフラグが第2状態である場合、前記有限状態機械が出力したフラグに対応する一単位分のデータを、前記文字セットに含まれない文字に変換して外部に出力することで、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去する、
請求項5記載の情報処理装置。
The sequence data is a time-stamped character string to which a time stamp is attached for each unit of data, and the characters constituting the character string are elements within a predetermined character set.
The finite state machine outputs a flag stored in a memory block at the end of the buffer each time the unit of data is received,
The information processing circuit,
When the flag output by the finite state machine is the first state, one unit of data corresponding to the flag output by the finite state machine is output to the outside,
When the flag output by the finite state machine is the second state, one unit of data corresponding to the flag output by the finite state machine is converted to a character not included in the character set and output to the outside. By substantially removing data that does not match the matching condition from the sequence data,
The information processing device according to claim 5.
複数の記号からなるシーケンスデータに含まれる所定のパターンを検索するためのマッチング条件の入力を受け付け、
前記受け付けたマッチング条件に基づいて、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去するための情報を生成するように構成された有限状態機械を生成する、
情報処理回路。
Accepting input of a matching condition for searching for a predetermined pattern included in sequence data composed of a plurality of symbols,
Based on the received matching condition, generate a finite state machine configured to generate information for substantially removing data that does not match the matching condition from the sequence data,
Information processing circuit.
前記マッチング条件は、オートマトンとして記述されている、請求項7記載の情報処理回路。   The information processing circuit according to claim 7, wherein the matching condition is described as an automaton. 前記有限状態機械は、N個のメモリブロックを有するFIFOバッファと、前記有限状態機械の状態遷移のルールを記述した情報を有し、前記N個のメモリブロックのそれぞれは、第1状態と第2状態のいずれかを表すフラグを格納する領域を有する請求項8記載の情報処理回路。   The finite state machine has a FIFO buffer having N memory blocks and information describing rules of state transitions of the finite state machine. Each of the N memory blocks has a first state and a second state. 9. The information processing circuit according to claim 8, further comprising an area for storing a flag indicating one of the states. 前記有限状態機械は前記シーケンスデータの一単位のデータの入力を受け付けるたびに、
前記バッファの末尾のメモリブロックの内容を出力し、
前記受け付けたデータと前記ルールとに基づいて、前記有限状態機械の状態を遷移させ、
前記バッファの先頭のメモリブロックに、前記受け付けたデータに対応するフラグの初期値として、第2状態を格納し、
遷移後の前記有限状態機械の状態に応じて、前記バッファ内の各メモリブロックに格納されているフラグの更新を行う、
請求項9に記載の情報処理回路。
Each time the finite state machine receives an input of one unit of data of the sequence data,
Output the contents of the memory block at the end of the buffer,
Based on the received data and the rules, transition the state of the finite state machine,
A second state is stored in a first memory block of the buffer as an initial value of a flag corresponding to the received data,
Update the flag stored in each memory block in the buffer according to the state of the finite state machine after the transition,
An information processing circuit according to claim 9.
前記有限状態機械がとり得る状態の各々は、前記オートマトンがとり得る状態sと、初期状態から前記状態sに達するまでに要する遷移回数に相当するカウンタnの組(s,n)の集合{(s,n),(s,n),...(s,n)}からなり(kは1以上の整数)、
前記情報処理回路は、
(1)前記有限状態機械の状態を遷移させた後の状態に含まれる、前記組の集合の中に、前記カウンタの値がNである組が存在する場合、前記バッファ中のN個のメモリブロックのフラグをすべて第1状態に変更し、
(2)前記有限状態機械の状態が含む前記状態s,s,,...sの中に受理状態が含まれる場合、受理状態の前記状態に対応付けられた前記カウンタの最大値Mを特定し、前記バッファの先頭からM個のメモリブロックのフラグを第1状態に変更する、
ことを特徴とする請求項10記載の情報処理回路。
Each of the possible states of the finite state machine is a set s (s) of a set (s, n) of a state s that the automaton can take and a counter n corresponding to the number of transitions required from the initial state to the state s. s 1 , n 1 ), (s 2 , n 2 ),... (s k , n k )} (k is an integer of 1 or more),
The information processing circuit,
(1) If there is a set whose counter value is N in the set of sets included in the state after the state transition of the finite state machine, N memories in the buffer Change all the flags of the block to the first state,
(2) the finite state the state s 1 the machine state includes, s 2 ,, ... if it contains an accepting state in the s k, the maximum value of the counter associated with the state of accepting states M, and change the flags of the M memory blocks from the head of the buffer to the first state;
The information processing circuit according to claim 10, wherein:
前記N個のメモリブロックのそれぞれはさらに、前記シーケンスデータの一単位分のデータを格納するためのデータ領域を有し、
前記情報処理回路は、前記有限状態機械に前記シーケンスデータを一単位ずつ入力するよう構成されており、
前記有限状態機械は前記一単位のデータの入力を受け付けた時に、
前記バッファの先頭のメモリブロックに、前記受け付けたデータに対応するフラグの初期値を格納することに加え、前記先頭のメモリブロックのデータ領域に、前記受け付けたデータを格納する、
請求項11記載の情報処理回路。
Each of the N memory blocks further has a data area for storing data of one unit of the sequence data,
The information processing circuit is configured to input the sequence data to the finite state machine one unit at a time,
When the finite state machine receives the input of the one unit of data,
In addition to storing an initial value of a flag corresponding to the received data in a head memory block of the buffer, storing the received data in a data area of the head memory block.
The information processing circuit according to claim 11.
前記シーケンスデータは文字列であり、前記文字列を構成する文字は、所定の文字セット内の要素であり、
前記有限状態機械は前記一単位のデータの入力を受け付けた時に、
前記バッファの先頭のメモリブロックのフラグが第1状態である場合、前記バッファの先頭のメモリブロックの内容を出力し、
前記バッファの先頭のメモリブロックのフラグが第2状態である場合、前記バッファの先頭のメモリブロックの内容を前記文字セットに含まれない文字に変更して出力することで、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去する、
請求項12記載の情報処理回路。
The sequence data is a character string, the characters constituting the character string are elements in a predetermined character set,
When the finite state machine receives the input of the one unit of data,
When the flag of the head memory block of the buffer is in the first state, the contents of the head memory block of the buffer are output;
When the flag of the first memory block of the buffer is in the second state, the contents of the first memory block of the buffer are changed to characters that are not included in the character set and output, so that the matching from the sequence data is performed. Substantially remove data that does not match the conditions,
The information processing circuit according to claim 12.
前記シーケンスデータは、前記一単位のデータごとにタイムスタンプが付された、タイムスタンプ付き文字列であり、前記文字列を構成する文字は、所定の文字セット内の要素であり、
前記オートマトンは実時間制約付きオートマトンであり、
前記有限状態機械は前記一単位のデータの入力を受け付けるたびに、前記バッファの末尾のメモリブロックに記憶されているフラグを出力し、
前記情報処理回路は、
前記有限状態機械が出力したフラグが第1状態である場合、前記有限状態機械が出力したフラグに対応する一単位分のデータを外部に出力し、
前記有限状態機械が出力したフラグが第2状態である場合、前記有限状態機械が出力したフラグに対応する一単位分のデータを、前記文字セットに含まれない文字に変換して外部に出力することで、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去する、
請求項11記載の情報処理回路。
The sequence data is a time-stamped character string to which a time stamp is attached for each unit of data, and the characters constituting the character string are elements within a predetermined character set.
The automaton is a real-time constrained automaton;
The finite state machine outputs a flag stored in a memory block at the end of the buffer each time the unit of data is received,
The information processing circuit,
When the flag output by the finite state machine is the first state, one unit of data corresponding to the flag output by the finite state machine is output to the outside,
When the flag output by the finite state machine is the second state, one unit of data corresponding to the flag output by the finite state machine is converted to a character not included in the character set and output to the outside. By substantially removing data that does not match the matching condition from the sequence data,
The information processing circuit according to claim 11.
請求項1ないし6のうちのいずれか1つに記載の情報処理装置である第1の情報処理装置と、
前記第1の情報処理装置に所定の通信回線又はネットワークを介して接続された第2の情報処理装置とを備えた情報処理システムであって、
前記第2の情報処理装置が有する情報処理回路は、第1の情報処理装置が出力した、前記加工されたシーケンスデータから前記マッチング条件に一致するデータを抽出して、前記抽出されたデータを出力することを特徴とする情報処理システム。
A first information processing device, which is the information processing device according to any one of claims 1 to 6,
An information processing system comprising: a second information processing device connected to the first information processing device via a predetermined communication line or a network;
The information processing circuit included in the second information processing device extracts data that matches the matching condition from the processed sequence data output by the first information processing device, and outputs the extracted data. An information processing system, comprising:
入力されるイベントのシーケンスデータに対して所定の加工を行う、情報処理装置による情報処理方法であって、
前記情報処理装置の有する情報処理回路が、
シーケンスデータに関する所定のマッチング条件を記述したオートマトンを受領する工程と、
前記オートマトンに基づいて有限状態機械を生成する工程と、
前記シーケンスデータの入力を受け付ける工程と、
前記有限状態機械を用いて、前記シーケンスデータから前記マッチング条件に一致しないデータを実質的に除去するように、前記シーケンスデータを加工する工程と、
前記加工されたシーケンスデータを出力する工程と、
を実行することを特徴とする、情報処理方法。
An information processing method by an information processing device, which performs a predetermined process on sequence data of an input event,
The information processing circuit of the information processing device includes:
Receiving an automaton describing a predetermined matching condition for the sequence data;
Generating a finite state machine based on the automaton;
Receiving an input of the sequence data;
Using the finite state machine, processing the sequence data so as to substantially remove data that does not match the matching condition from the sequence data,
Outputting the processed sequence data;
An information processing method, comprising:
JP2019129643A 2018-10-02 2019-07-11 Information processing device, information processing circuit, information processing system, and information processing method Active JP7383273B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US16/583,876 US11537415B2 (en) 2018-10-02 2019-09-26 Information processing apparatus, information processing circuit, information processing system, and information processing method

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2018187340 2018-10-02
JP2018187340 2018-10-02

Publications (2)

Publication Number Publication Date
JP2020057362A true JP2020057362A (en) 2020-04-09
JP7383273B2 JP7383273B2 (en) 2023-11-20

Family

ID=70107415

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2019129643A Active JP7383273B2 (en) 2018-10-02 2019-07-11 Information processing device, information processing circuit, information processing system, and information processing method

Country Status (1)

Country Link
JP (1) JP7383273B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023112168A1 (en) * 2021-12-14 2023-06-22 日本電信電話株式会社 Extraction device, extraction method, and extraction program
JP7464268B2 (en) 2020-04-14 2024-04-09 大学共同利用機関法人情報・システム研究機構 Automaton generation device, automaton generation method and program

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10198706A (en) * 1996-11-15 1998-07-31 Digital Vision Lab:Kk Information retrieval device, and method therefor
GB2362789A (en) * 1999-11-23 2001-11-28 Ibm System and method for searching patterns in real-time over a shared medium
JP2003308333A (en) * 2002-04-16 2003-10-31 Fujitsu Ltd Retrieval device and method using order pattern that includes repetition
JP2004110327A (en) * 2002-09-18 2004-04-08 Fujitsu Ltd Time series correlation extracting device
JP2006302082A (en) * 2005-04-22 2006-11-02 Mitsubishi Electric Corp Character string retrieval system
JP2013008329A (en) * 2011-06-27 2013-01-10 Fujitsu Ltd Collation device and collation program

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10198706A (en) * 1996-11-15 1998-07-31 Digital Vision Lab:Kk Information retrieval device, and method therefor
GB2362789A (en) * 1999-11-23 2001-11-28 Ibm System and method for searching patterns in real-time over a shared medium
JP2003308333A (en) * 2002-04-16 2003-10-31 Fujitsu Ltd Retrieval device and method using order pattern that includes repetition
JP2004110327A (en) * 2002-09-18 2004-04-08 Fujitsu Ltd Time series correlation extracting device
JP2006302082A (en) * 2005-04-22 2006-11-02 Mitsubishi Electric Corp Character string retrieval system
JP2013008329A (en) * 2011-06-27 2013-01-10 Fujitsu Ltd Collation device and collation program

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7464268B2 (en) 2020-04-14 2024-04-09 大学共同利用機関法人情報・システム研究機構 Automaton generation device, automaton generation method and program
WO2023112168A1 (en) * 2021-12-14 2023-06-22 日本電信電話株式会社 Extraction device, extraction method, and extraction program

Also Published As

Publication number Publication date
JP7383273B2 (en) 2023-11-20

Similar Documents

Publication Publication Date Title
Zang et al. A BDD-based algorithm for reliability analysis of phased-mission systems
Wang Petri Nets for Dynamic Event-Driven System Modeling.
WO2019060327A1 (en) Online detection of anomalies within a log using machine learning
US20110022617A1 (en) Finite automaton generation system for string matching for multi-byte processing
WO1999050746A2 (en) A method and an apparatus for analyzing a state based system model
KR101857510B1 (en) Sorting
JP2020057362A (en) Information processing apparatus, information processing circuit, information processing system, and information processing method
Valmari et al. Stubborn set intuition explained
US11537415B2 (en) Information processing apparatus, information processing circuit, information processing system, and information processing method
CN114841103B (en) Parallel simulation method, system, storage medium and equipment for gate-level circuit
Madhusudan Reasoning about sequential and branching behaviours of message sequence graphs
Morgenstern et al. From LTL to symbolically represented deterministic automata
Kutrib et al. Real-time reversible iterative arrays
D’Aprile et al. CSL model checking for the GreatSPN tool
Baier et al. Model checking linear-time properties of probabilistic systems
Teruel et al. Well-defined generalized stochastic Petri nets: A net-level method to specify priorities
CN116361153A (en) Method and device for testing firmware codes, electronic equipment and storage medium
Karoui et al. On hierarchical construction of the state space of an automated manufacturing system modeled with Petri nets
Cohen et al. EventScript: an event-processing language based on regular expressions with actions
CN112862080A (en) Hardware calculation method of attention mechanism of EfficientNet
Hwang et al. A reachable graph of finite and deterministic DEVS networks
Kutrib et al. One-dimensional cellular automaton transducers
Babaee et al. From UML state machines to verifiable lotos specifications
Niculescu et al. From Kernel P Systems to X-Machines and FLAME.
Keung et al. State space reconfigurability: an implementation architecture for self modifying finite automata

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7426

Effective date: 20190723

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A821

Effective date: 20190723

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20220601

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20230425

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20230516

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20230713

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20231024

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20231031

R150 Certificate of patent or registration of utility model

Ref document number: 7383273

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150