JPH03105581A - Parallel data processing system - Google Patents

Parallel data processing system

Info

Publication number
JPH03105581A
JPH03105581A JP1243969A JP24396989A JPH03105581A JP H03105581 A JPH03105581 A JP H03105581A JP 1243969 A JP1243969 A JP 1243969A JP 24396989 A JP24396989 A JP 24396989A JP H03105581 A JPH03105581 A JP H03105581A
Authority
JP
Japan
Prior art keywords
data processing
data
tray
input
matrix
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.)
Pending
Application number
JP1243969A
Other languages
Japanese (ja)
Inventor
Hideki Kato
英樹 加藤
Hideki Yoshizawa
英樹 吉沢
Hiromoto Ichiki
宏基 市來
Kazuo Asakawa
浅川 和雄
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.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP1243969A priority Critical patent/JPH03105581A/en
Priority to AU63030/90A priority patent/AU641418B2/en
Priority to DE69032259T priority patent/DE69032259T2/en
Priority to EP90310302A priority patent/EP0421639B1/en
Publication of JPH03105581A publication Critical patent/JPH03105581A/en
Priority to US08/227,472 priority patent/US5600843A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To perform a matrix arithmetic or a neuro-computer arithmetic in terms of an analog signal by carrying out the transfer of data of a shift means, the transfer of data between a tray and a data processing unit, and a data processing operation of the data processing unit synchronously with each other. CONSTITUTION:The data processing units 1 process data and the trays 2 transfer data and form a shift register 3. The register 3 performs a circulating shift of data. The units 1 are separated from the trays 2 having the data holding functions so that a product is obtained between and (nXm) matrix and the vector of the element number (n) with the simultaneous and parallel operations of the transfer of data and the process of data regardless of the coincidence or noncoincidence secured between the number (m) of units 1 and the number (n) of trays 2. Thus the original parallel degree is used to the full to obtain the satisfactory effects of the number of units even with such a process that obtains a product between a rectangular matrix and the vector. As a result, a matrix arithmetic or a neuro-computer arithmetic is performed in terms of an analog signal.

Description

【発明の詳細な説明】 〔}既     要〕 複数個のデータ処理ユニットを同期的に用いてデータを
処理する並列データ処理方式に関し、リングシストリッ
クアレイ方式や共通ハス結合型S I MD (Sfn
gle Instruction Multi Dat
.a )合方式と同程度なハードウエア構成で、データ
転送によるオーバヘッドを減少せしめ、特に、長方形行
列とベクトルとの積を求めるような処理に対しても、本
来の並列度を最大限利用できるようにして良好な台数効
果を得ることにより、行列演算あるいはニューロコンピ
ュータ演算をアナログ信号について行うことをことを目
的とし、各々少なくとも一つの入力を持つ複数個のデー
夕処理ユニットと、各々第1の入力及び出力を持ちかつ
各々データ保持及びデータ転送を行う複数個のトレイで
あって、前記トレイの全部又はその一部が各々前記デー
タ処理ユニットの第1の入力に接続された第2の出力を
有するものと、前記接続するトレイの第1の入力及び出
力が接続されて成るシフト手段とを具備し、前記シフト
手段上のデータ転送と、前記トレイと前記データ処理ユ
ニット間のデータ転送と、前記データ処理ユニットによ
るデータ処理とを同期して行うことにより、行列演算あ
るいはニューロコンピュータ演算をアナログ信号につい
て行うように構成する。
[Detailed Description of the Invention] [Already Required] Regarding parallel data processing methods that process data by using a plurality of data processing units synchronously, ring systolic array methods and common hash combination type SIMD (Sfn
gle Instruction Multi Dat
.. a) With a hardware configuration comparable to that of the combination method, the overhead due to data transfer is reduced, and the inherent degree of parallelism can be utilized to the maximum, especially for processing such as calculating the product of a rectangular matrix and a vector. The purpose is to perform matrix calculations or neurocomputer calculations on analog signals by obtaining a good number effect by using a plurality of data processing units each having at least one input, and each having a first input. and a plurality of trays each for data retention and data transfer, the trays having a second output connected to the first input of the data processing unit, all or a portion of the trays each having a second output connected to the first input of the data processing unit. and a shifting means connected to a first input and an output of the connecting tray, the data transfer means on the shifting means, the data transfer between the tray and the data processing unit, and the data By synchronously performing data processing by the processing unit, matrix calculations or neurocomputer calculations are configured to be performed on analog signals.

〔産業上の利用分野〕[Industrial application field]

本発明は並列データ処理方式に係り、更に詳しくは、複
数個のデータ処理ユニットを同期的に用いてデータを処
理する並列データ処理方式に関する。
The present invention relates to a parallel data processing system, and more particularly to a parallel data processing system that processes data using a plurality of data processing units synchronously.

近年、電子計算機或いはデジタル信号処理装置等のシス
テムにおいて、データ処理の適用分野の拡大に伴い、処
理されるデータの量が膨大になり、特に画像処理或いは
音声処理等の分野では高速なデータ処理を行う必要があ
り、そのため、複数個のデータ処理ユニットを同期的に
用いてデータを処理するデータ処理の並列性の利用が重
要となる。
In recent years, with the expansion of the fields of application of data processing in systems such as electronic computers and digital signal processing devices, the amount of data being processed has become enormous.Especially in fields such as image processing and audio processing, high-speed data processing is required. Therefore, it is important to utilize parallelism in data processing, in which multiple data processing units are used synchronously to process data.

一般に、複数の処理ユニットを用いた処理において重要
な概念に台数効果がある。これは用意されたデータ処理
ユニットの台数に比例したデータ処理速度の向上が得ら
れることを意味するが、並列処理方式においては良好な
台数効果を得ることが非常に重要となる。
In general, an important concept in processing using multiple processing units is the number effect. This means that the data processing speed can be improved in proportion to the number of data processing units prepared, but in parallel processing systems, it is very important to obtain a favorable number effect.

台数効果が悪化する主要な原因は、問題そのものの並列
度による限界を別にすれば、データ処理に伴うデータ転
送に要する時間が本来のデータ処理に要する時間に加算
されてトータルとしての処理時間が引き延ばされること
にある。従って、台数効果の向上にはデータ伝送路の容
量をフルに活用することが有効であるが、これはなかな
か難しい しかし、処理が規則的な場合には、この規則性を利用し
て台数効果を上げることが可能となる。
The main reason for the deterioration of the number-of-units effect is that, apart from the limitation due to the parallelism of the problem itself, the time required for data transfer associated with data processing is added to the time required for original data processing, which reduces the total processing time. It lies in being postponed. Therefore, it is effective to make full use of the capacity of the data transmission path to improve the number of devices, but this is difficult. However, if the processing is regular, this regularity can be used to improve the number of devices. It is possible to raise it.

データをシストリソクアレイ、すなわち、巡回的にデー
タを流し、2つのデータがその流れにおいてそろったと
ころで演算を行うようにする。処理が規則的なことを利
用する並列処理がシストリソクアレイ方式であり、この
中でリングシストリンクアレイ方弐と呼ばれる1次元の
シストリシクアレイ方式は、複数個のデータ処理ユニッ
トを同期的に用いてシストリックなデータを処理する並
列データ処理方弐であって実現が比較的容易である。
Data is distributed in a system array, that is, data is passed cyclically, and an operation is performed when two pieces of data are aligned in the flow. Parallel processing that takes advantage of the regularity of processing is the systolic array method. Among these, the one-dimensional systolic array method called ring system linked array method uses multiple data processing units synchronously. This is a parallel data processing method for processing systolic data, and it is relatively easy to implement.

規則性のある処理として、ベクトルの内積演算を基本と
した行列演算や、ニューラルネットの積和演算に非線形
関数を介して出力する並列処理がある。
Examples of regular processing include matrix operations based on inner product operations of vectors and parallel processing that outputs output via nonlinear functions in neural network product-sum operations.

〔従来の技術〕[Conventional technology]

第11図(A)は従来の共通ハス結合型並列方式の原理
構成図である。同図において91はプロセッサエレメン
ト、4はメモリ、93は共通バス、92は共通バスに接
続されるバス、94は各ブロセンサエレメントと、それ
に対応して接続されるメモリ4を接続する内部バスであ
る。この共通バス結合型並列方式においては、プロセッ
サエレメント(以下PEと称す)間の通信が共通ハス9
3を介して行われる。特定な時間区域には共通ハスに乗
せるデータは1つであるため、共通バスによる通信は共
通バス全体にわたって同期をとる必要がある。
FIG. 11(A) is a diagram illustrating the principle of a conventional common helical coupling type parallel system. In the figure, 91 is a processor element, 4 is a memory, 93 is a common bus, 92 is a bus connected to the common bus, and 94 is an internal bus that connects each processor element and the memory 4 connected to it. be. In this common bus-coupled parallel system, communication between processor elements (hereinafter referred to as PEs) is carried out using a common bus 9.
3. Since only one piece of data can be carried on the common bus in a specific time period, communication using the common bus must be synchronized over the entire common bus.

第11図(B)はこの共通バス結合型並列方式による行
列ベクトル積の動作フローチャートである。各PEは他
のPEからのデータXと内部レジスタのYとをかけ、そ
の積をYに足しこむ動作を行う。そのためフローチャー
トに示すように、i番目のPEに関して、その内部にあ
るレジスタの内容、すなわち、Ylの値をまず0にする
。そして以下をn回繰り返す。すなわち、共通バス93
にX,を与えるとi番目のPEは共通バスに接続された
ハス92からの入力とメモリ4から内部バス94を介し
て与えられる入力を掛け合わせ、その積をYlに足し込
む。これを繰り返す。
FIG. 11(B) is an operational flowchart of matrix-vector product using this common bus-coupled parallel method. Each PE multiplies data X from other PEs by Y in the internal register and adds the product to Y. Therefore, as shown in the flowchart, for the i-th PE, the contents of the internal register, that is, the value of Yl, are first set to 0. Then, repeat the following n times. That is, the common bus 93
When X is given to , the i-th PE multiplies the input from the lotus 92 connected to the common bus by the input given from the memory 4 via the internal bus 94, and adds the product to Yl. Repeat this.

?12図(A)は従来のリングシストリック方式の原理
説明図である。同図において20はプロセッサエレメン
ト(PE)である。各PEは巡回バス22によって接続
されている。また、21は係数WIJを格納するメモリ
である。Wl+.  ’W+■,・・・,W33などは
係数行列の要素であり、一般にWIJは行列のij成分
である。この係数行列Wと、ヘク}Pvx−(X+ ,
X2 ,Xz )を掛ケル動作をこのリングシストリッ
ク方式で行う場合、次のようにして行われる。
? FIG. 12(A) is a diagram explaining the principle of the conventional ring systolic method. In the figure, 20 is a processor element (PE). Each PE is connected by a circular bus 22. Further, 21 is a memory that stores the coefficient WIJ. Wl+. 'W+■, . . . , W33, etc. are elements of a coefficient matrix, and generally WIJ is an ij component of the matrix. This coefficient matrix W and Hek}Pvx−(X+,
When performing the multiplication operation using this ring systolic method, it is performed as follows.

第12図(B)はブロセソサエレメントの第i番目の内
部構造である。同図において23は乗算器、24は加算
器、25はアキュムレータ(ACC)、21は係数の要
素W1,を格納するレジスタ群である。このレジスタ群
はいわゆるFIFOであって、係数行列の第i行目に関
する係数としてW口、すなわちj番目の列の要素が出力
されようとしている状態である。このFIFOは出力さ
れた次のクロックでは巡回し、バス22を介して後ろ側
からまた入力される。従って図に示すように、Wl+,
  ・・・,W,,−,はすでに巡回されて後側6こ格
納されている状態となっている。
FIG. 12(B) shows the i-th internal structure of the Brocesosa element. In the figure, 23 is a multiplier, 24 is an adder, 25 is an accumulator (ACC), and 21 is a register group for storing the coefficient element W1. This register group is a so-called FIFO, and the W entry, that is, the element in the j-th column is about to be output as the coefficient for the i-th row of the coefficient matrix. This FIFO circulates at the next output clock and is input again from the rear side via the bus 22. Therefore, as shown in the figure, Wl+,
. . , W,, -, have already been cycled through and are stored in the rear six locations.

一方、ベクトルの各要素はバス22を介しテ入力される
。現在、要素Xjが入力されている状態である。すでに
アキュムレータ25にはW,,XX,+・・・+Wi 
J−I XXj−1 の内積結果が格納されている。こ
れが今アキュムレータ25がら出力され、加算器24の
一方の入力に入力されている。
On the other hand, each element of the vector is input via the bus 22. Currently, element Xj is being input. W,,XX,+...+Wi are already in the accumulator 25.
The inner product result of J-I XXj-1 is stored. This is now output from the accumulator 25 and input to one input of the adder 24.

外部からのXjとFIFOから出力されるw,Jの積が
乗算器23によって乗算され、その結果が加算器24の
他方の入力に入力され、現在のアキュムレータ25の内
容とが加えられ、次のクロ・ンクで同じアキュムレータ
25に加算される。この繰り返しによって、係数行列W
の第i行目の行ベクトルと外部から与えらるXベクトル
との内積演算がW行される。なお、スイッチ(Swit
ch)はデータXIをスルーに外部に出すか、あるいは
内部に取り込み、アキュムレータ25にセットする場合
との選択を行うためのものである。このようなPEで、
行列×ベクトルの積を行う場合、第12図?A)に示す
ように、PE−1はまず、W.とx1を掛け、次のクロ
ック周期に、X2が右側のPE一2から流れ込み、W,
2がメモリ21から出力されるので、WI2×x2が演
算される。同様に次のクロックではW13とX3との積
が実行され、このことにより係数行列の第1列目とベク
トル入との積がPE−1において可能となる。また、第
2列目とベクトルとの積はPE−2において行われる。
The product of Xj from the outside and w, J output from the FIFO is multiplied by the multiplier 23, the result is input to the other input of the adder 24, the current content of the accumulator 25 is added, and the next It is added to the same accumulator 25 at the clock. By this repetition, the coefficient matrix W
The inner product calculation between the i-th row vector and the externally given X vector is performed W times. Note that the switch
ch) is for selecting whether to output the data XI to the outside or take it inside and set it in the accumulator 25. With such PE,
When performing matrix x vector product, Fig. 12? As shown in A), PE-1 first undergoes W. is multiplied by x1, and in the next clock period, X2 flows from PE-2 on the right, and W,
Since 2 is output from the memory 21, WI2×x2 is calculated. Similarly, in the next clock, the product of W13 and X3 is executed, which allows the product of the first column of the coefficient matrix and the vector input in PE-1. Also, the product of the second column and the vector is performed in PE-2.

すなわち、W2■とX2を掛け、次のクロンーク周期に
、W2■とX3を掛け、次のクロンク周期においてW2
1と巡回的にもどってきたX1との積を行うことになる
。同様に、第3行目とベクトルとの積はW33とX3を
掛け、W31と巡回してくるXIとを掛け、W3■と巡
回して戻ってくるX2との積をとって内積演算を実行す
ることによって可能となる。従って、この動作において
、W11と×1との積、及びW2■とX2、W33とX
3との積は同時に行えることになる。しかし、図に示す
ように、この同時性を実行するためには係数行列の要素
の並べ方にねじれが生じている。このようなリングシス
トリソクアレイ方式においては、各PE間のデータ転送
と、各PEでのデータ処理を同期して実行することで、
データ転送路を有効に利用でき、従って良好な台数効果
を得ることができる。
That is, multiply W2■ by X2, multiply the next Cronk period by W2■ and X3, and multiply W2■ by X3 in the next Cronk period.
1 and X1 returned cyclically are multiplied. Similarly, for the product of the third row and the vector, multiply W33 by X3, multiply W31 by the circulating XI, and perform the inner product operation by multiplying W3■ by the circulating X2. This becomes possible by doing so. Therefore, in this operation, the product of W11 and ×1, W2■ and X2, W33 and X
The product with 3 can be done at the same time. However, as shown in the figure, in order to achieve this simultaneity, the arrangement of the elements of the coefficient matrix is distorted. In such a ring system litho array method, by synchronously executing data transfer between each PE and data processing at each PE,
The data transfer path can be used effectively, and therefore a good effect on the number of devices can be obtained.

第12図(C)は、第12図(A)のリングシストリッ
ク方式の構戒を多段に組み合わせたのもであり、この構
成により、連続する行列とベクトルの積を行うことが可
能となる。このようなシストリックアレイ方式は処理が
規則的であるため、データ伝送路の容量をフルに活用す
ることが可能であり、従って台数効果の向上が計れる。
FIG. 12(C) is a multi-stage combination of the ring systolic method configurations of FIG. 12(A), and this configuration makes it possible to perform the product of continuous matrices and vectors. Since such a systolic array method performs regular processing, it is possible to make full use of the capacity of the data transmission path, and therefore the number of devices can be improved.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

第II図(A)のような従来の共通ハス結合の並列方式
においては、プロセンシングエレメント、すなわちPE
間の結合が共通バスによっているため、一時には1つの
データしか転送できない。また、共通バスによる結合は
共通パス全体にわたる同期をとらなければならない。し
たがって、従来の共通バス結合型並列方式においては良
好な台数効果を得られる処理の種類が少ないという問題
が生じ、さらに共通バスによる結合は、結合されるPE
の個数の増加とともに共通バスが長くなり、共通バス全
体にわたる同期をとるのが難しくなるという問題、そし
て、大規模並列には適さないという問題が生じていた。
In the conventional common helical coupling parallel system as shown in FIG.
Since the connection between them is through a common bus, only one piece of data can be transferred at a time. Also, coupling by a common bus requires synchronization across the common path. Therefore, in the conventional common bus coupling type parallel system, there is a problem that there are only a few types of processing that can obtain a good number of units effect.
As the number of devices increases, the common bus becomes longer, causing problems such as difficulty in synchronizing the entire common bus and unsuitability for large-scale parallelism.

また、第12図のような従来のリングシストリックアレ
イ方式においては、各PE間のデータ転送とPEでのデ
ータ処理を同期して実行することにより、台数効果を得
ることができるが、この方式では、各PE間でのデータ
転送と、各PE間でのデータ処理のタイミングを合わせ
ねばならない。また、この方式では、たとえば長方形の
行列とベクトルとの積を求める場合などのようにデータ
処理ユニントとデータ保持ユニットのそれぞれの最適な
個数が等しくない場合には、実際のデータ処理に係わら
ないPEが必要となり、すなわち、遊ぶPEが多くなり
、そのため台数効果が悪化するという問題がある。言い
換えれば、効率よくとける問題と回路構成とが固く対応
し、問題の大きさが最適な値と異なると台数効果が悪化
してしまう。逆にいうと、良好な台数効果が得られる問
題が特定されてしまい、広範な処理に適用できず、柔軟
性、あるいは汎用性に欠け、結果として、ある程度広い
範囲の処理に適用できる高速なデータ処理系を実現する
ことが困難となる。
In addition, in the conventional ring systolic array method as shown in FIG. 12, the effect of the number of devices can be obtained by synchronizing data transfer between each PE and data processing in the PE, but this method Then, it is necessary to match the timing of data transfer between each PE and the timing of data processing between each PE. In addition, in this method, if the optimal numbers of data processing units and data holding units are not equal, such as when calculating the product of a rectangular matrix and a vector, PEs that are not involved in actual data processing In other words, there is a problem that the number of PEs to play increases, and the number effect worsens. In other words, there is a strong correspondence between the problem of efficient solving and the circuit configuration, and if the size of the problem differs from the optimal value, the number effect will worsen. Conversely, the problem of obtaining a good number of units effect has been identified, and it cannot be applied to a wide range of processing, lacks flexibility or versatility, and as a result, high-speed data that can be applied to a somewhat wide range of processing has been identified. This makes it difficult to implement a processing system.

本発明は、リングシストリックアレイ方式や共通バス結
合型S I M D (Single Instruc
tionMulti Data)結合方式と同程度なハ
ードウエア構成で、データ転送によるオーバヘッドを減
少せしめ、特に、長方形行列とヘクトルとの積を求める
ような処理に対しても、本来の並列度を最大限利用でき
るようにして良好な台数効果を得ることにより、行列演
算あるいはニューロコンピュータ演算をアナログ信号に
ついて行うことを目的とする。
The present invention is applicable to a ring systolic array method or a common bus-coupled type SIMD (Single Instrument
With the same hardware configuration as the combination method (Multi Data), it reduces the overhead due to data transfer, and can maximize the original degree of parallelism, especially for processing such as calculating the product of a rectangular matrix and a hector. The purpose is to perform matrix calculations or neurocomputer calculations on analog signals by obtaining a good number of units effect in this manner.

〔課題を解決するための手段] 第1図は本発明の原理説明図である。同図において1は
データ処理ユニット、2はデータの保持及び転送を行う
トレイ、3は各トレイの相互接続により構成されるシフ
トレジスタ、11はデータ処理ユニノトの第1の入力、
12はデータ処理ユニットの第2の入力、21はトレイ
の第1の入力、22はトレイの第1の出力、23はトレ
イ2の第2の出力である。
[Means for Solving the Problems] FIG. 1 is a diagram explaining the principle of the present invention. In the figure, 1 is a data processing unit, 2 is a tray that holds and transfers data, 3 is a shift register formed by interconnecting each tray, 11 is a first input of a data processing unit,
12 is the second input of the data processing unit, 21 is the first input of the tray, 22 is the first output of the tray, and 23 is the second output of the tray 2.

データ処理ユニット1はデータの処理を行い、トレイ2
は転送の動作を行うものでシフトレジスタ3を構威して
、データの巡回シフトを行う。本発明では、mxn行列
仄と要素数nのベクl・ルXとの積を求める場合、行列
Aの行数mが列数nより小さい場合であっても、或いは
mがnより大きい場合であっても、m個のデータ処理ユ
ニントとn個のトレイを用いてnに比例する処理時間で
その積が実行可能となり、従って、良好な台数効果を得
ることができる。すなわち、第1図(A)に示すように
、それぞれ2つの入力を持ち、その入力間の乗算機能と
その乗算結果の累積機能、すなわち内積演算を実・行す
るm個のデータ処理ユニノト1と、n個のトレイ2とか
らなる構戒において、ユニット内の累積レジスタをYと
した場合に、デ一ク処理ユニノトは11からの入力とl
2からの入力を掛け合わせ、積を累積Yに足し込み、そ
の後、シフトレジスタ3内の隣接するトレイ間でベクト
ルXの要素をシフトする。この動作をn回繰り返すこと
により、mXnの行列Aと、n次元ベクトルとの乗算が
m個のデータ処理ユニットを用いてnに比例する処理時
間で実行可能となる。すなわち、本発明は、従来方式と
異なり、データ処理ユニット1とデータ保持機能を有す
るトレイ2とを分離することにより、それぞれmとnが
異なっている場合であっても、タイミングを合わせるた
めの処理を必要とせずに良好な台数効果を得ることが可
能となる。さらに、本発明では、トレイ2間のデータ転
送とデータ処理ユニント1によるデータ処理とを同時並
行的に行い、一i的にはデータ処理ユニットがデータ処
理に有する時間よりもデータ転送時間を短くすることが
期待できるので、データ転送時間をデータ処理時間の影
に隠すことで実質的にOにし、そのことにより、処理時
間を短縮することが可能となっている。このことにより
、行列演算あるいはニューロコンピュータ演算をアナロ
グ信号について行う。
Data processing unit 1 processes data and tray 2
performs a transfer operation, and utilizes the shift register 3 to perform cyclic shifts of data. In the present invention, when calculating the product of an mxn matrix and a vector X having n elements, it is possible to calculate the product even if the number of rows m of the matrix A is smaller than the number of columns n, or if m is larger than n. Even if there are, the product can be executed using m data processing units and n trays with a processing time proportional to n, and therefore a good number effect can be obtained. That is, as shown in FIG. 1(A), there are m data processing units 1 each having two inputs and performing a multiplication function between the inputs and an accumulation function of the multiplication result, that is, an inner product operation. , n trays 2, and if the cumulative register in the unit is Y, then the deck processing unit has input from 11 and l
2, add the product to the accumulation Y, and then shift the elements of vector X between adjacent trays in shift register 3. By repeating this operation n times, the multiplication of the m×n matrix A by the n-dimensional vector can be performed using m data processing units in a processing time proportional to n. That is, unlike the conventional system, the present invention separates the data processing unit 1 and the tray 2 having a data holding function, so that even if m and n are different from each other, processing for synchronizing the timing can be performed. It is possible to obtain a good number of units without the need for Furthermore, in the present invention, data transfer between the trays 2 and data processing by the data processing unit 1 are performed simultaneously in parallel, and the data transfer time is generally shorter than the time taken by the data processing unit for data processing. Therefore, by hiding the data transfer time behind the data processing time, it is essentially possible to reduce the processing time to zero. This allows matrix operations or neurocomputer operations to be performed on analog signals.

[作    用] データ処理ユニットと、データ保持機能を有するトレイ
とを分離することにより、データ処理ユニ,トの個数m
とトレイの個数nとが同一の場合も違っている場合も、
nXmの行列Aと要素数nのベクトル鬼との積を、デー
タ転送と、データ処理の同時並列処理により行うことが
できる。
[Function] By separating the data processing unit and the tray having the data holding function, the number of data processing units m can be reduced.
Regardless of whether and the number of trays n are the same or different,
The product of the n×m matrix A and the vector demon having n elements can be performed by simultaneous data transfer and data processing in parallel.

〔実  施  例] 以下、本発明の実施例を図面を参照して説明する。〔Example] Embodiments of the present invention will be described below with reference to the drawings.

第1図(B)は第1図(A)の本発明の原理構成図のシ
ステムの動作フローチャートである。第1図(A)に示
されるように本発明ではデータ処理ユニントlとデータ
保持機能を有するトレイ2とを分離し、さらにトレイを
隣接間で接続し、巡回接続することによってシストリッ
クなシステム?構成している。データ処理ユニットの数
をn、トレイの数をmとした場合に、mXnの行列八と
要素数nのへクトルXとの積を求める場合、第1図(B
)のフローチャートに示される動作となる。
FIG. 1(B) is an operation flowchart of the system shown in FIG. 1(A) which is a diagram of the principle configuration of the present invention. As shown in FIG. 1(A), in the present invention, a data processing unit 1 and a tray 2 having a data holding function are separated, and the trays are connected adjacently to each other for circular connection to create a systolic system. It consists of When the number of data processing units is n and the number of trays is m, when calculating the product of a matrix 8 of mXn and a hector X of n elements, as shown in Figure 1 (B
) The operation is shown in the flowchart.

Xlをトレイ2のi番目にセットする。Y,の値を0に
する。すなわちデータ処理ユニットのi番目のユニット
における累積レジスタの値を初期化する。i番目の処理
ユニッ}1+ はlitからの入力と、12iの入力を
掛け合わせて、積を累積器Y.に足し込む。そしてシフ
トレジスタ3をシフトする。この内積とシフト動作をn
回繰り返す。
Set Xl in the i-th position of tray 2. Set the value of Y to 0. That is, the value of the accumulation register in the i-th data processing unit is initialized. The i-th processing unit}1+ multiplies the input from lit by the input from 12i, and sends the product to the accumulator Y. Add to. Then, shift register 3 is shifted. This inner product and shift operation are n
Repeat times.

この処理において長方行列AとベクトルXとの積が形成
される。この場合、トレイ間のデータ転送とデータ処理
ユニットにおけるデータ処理とは同時並行処理となる。
In this process, a product of rectangular matrix A and vector X is formed. In this case, data transfer between trays and data processing in the data processing unit are simultaneous and parallel processes.

第1図(C)は本発明方式の動作概念図である。FIG. 1(C) is a conceptual diagram of the operation of the system of the present invention.

同図においてトレイ2内のデータXIからX■はベクト
ルXの要素でその個数はnであるとする。
In the figure, it is assumed that data XI to X■ in tray 2 are elements of vector X, and the number thereof is n.

またデータ処理ユニットはm個あり、その各々に累積器
がY+ ,Yz ,  ・・・,Y1がある。m×?の
長方行列の要素はA I +からA■までのmXn個存
在する。データ処理ユニノトの11には係数行列の第1
行目であるAz,A+■,・・・ A,nが同期的に1
2.の入カハスから入力される。またデータ処理ユニッ
ト12はA22.  A23.  ・・・A21がシス
トリック動作の各タイミングで順番に与えられる。また
、データ処理ユニットllIにはA ffill+ A
m +m+1+・・・,  Aq m−1が同期的に与
えられる。
Furthermore, there are m data processing units, each of which has an accumulator Y+, Yz, . . . , Y1. mx? There are mXn elements of the rectangular matrix from A I + to A■. 11 of the data processing unit is the first coefficient matrix.
The row Az, A+■,... A, n are 1 synchronously
2. It is input from the input cassette. Further, the data processing unit 12 is A22. A23. ... A21 is given in order at each timing of the systolic operation. In addition, the data processing unit llI has A ffill+A
m+m+1+..., Aq m-1 are given synchronously.

第1図(D)は第1図(C)の動作のタイピングチャー
トである。時間T1からTnの動作は第1図(C)のそ
れぞれの図と第1図(D)の時間T+ ,Tz ,  
・・・,Tnとが対応している。時間タイミングT,に
おいては第1図(C)に示されるようにトレイの21.
22,  ・・・ 2nにはx,,x2,x.,−−−
,xnがあり、ユニント11,12,  ・・・,lm
にはそれぞれ係数行列の要素AII+ A22+  ・
・・八〇が入力されている。従って、このタイミングに
おいてデータ処理ユニットはA目とトレイ21のデータ
X1との?を求め、データ処理ユニットに対応するトレ
イ22にあるX2と、メモリから与えられるA2■との
積を求め、同様に、トレイ2mにおいてはA mIlと
X,,lの積を求める。このタイ主ングは第1図(D)
のT1のタイミングで行われている。すなわち積和を求
める同期クロックにおいて、バス111にはx1があり
、バス12,にはAI+があり、バス112にはX2、
122にはA22、113にはX3、123にはA33
があり、11,,にはX1、】2.,にはA■がのって
いる。従って、第1図(C)のT1タイムにおける図に
示すように内積演算が行われる。累積器Yの値はこの時
は0であるから内積結果は0に掛けた値が加わることに
なる。積和演算が終わるとシフト動作に入る。すなわち
第1図(D)に示されるようにTIとT2との間がシフ
ト動作であり、隣接するトレイ間でデータのシフトが行
われる。すなわち左シフトがこの場合行われる。すると
第1図(C)のタイミングT2に移る。第1図(D)の
動作タイミングでも同様にT2の積和の時間区域となる
。するとシ?トされているからトレイ2,にはX2、ト
レイ22にはX3、そしてトレイ2mにはX m+1が
格納され、また、係数行列の要素もトレイ1,2,・−
・,mにはそれぞれAI2, A23  Am I+l
+1が入力される。これは第1図(D)のT2のタイミ
ングにおいてもハス上のデータがそれぞれ示されている
。従って、T2のタイミングにおいて、A1■とX2と
の積をとり、前の累積器Yとの和が求められる。従って
ユニット11においてはT,において求まったA.とX
1との積とT2において求められるA+■とX2との積
との和が求められその結果が累積器に格納される。同様
にユニット12においては前の結果であるA 22 X
 X 2 + A 23 X X 3の結果が累積器に
格納される。ユニット1■に対しても同様である。そし
てまたシフトし、タイミングT3に移る。トレイlには
X3、トレイ2にはX4、トレイmにはXmm+2、ト
レイnにはX2が入り、第1図(C)のT3時間におけ
る図に示されるような内積演算が実行される。
FIG. 1(D) is a typing chart of the operation of FIG. 1(C). The operations from time T1 to Tn are shown in the respective diagrams in FIG. 1(C) and times T+, Tz, and Tz in FIG. 1(D).
..., Tn correspond to each other. At time timing T, as shown in FIG. 1(C), the tray 21.
22, ... 2n has x,, x2, x. ,---
, xn, and units 11, 12, ..., lm
are respectively the coefficient matrix elements AII+ A22+ ・
...80 is entered. Therefore, at this timing, the data processing unit calculates the difference between the A-th data and the data X1 on the tray 21? is obtained, and the product of X2 in the tray 22 corresponding to the data processing unit and A2 given from the memory is obtained. Similarly, in the tray 2m, the product of A mIl and X,,l is obtained. This tie is shown in Figure 1 (D).
This is done at the timing of T1. In other words, in the synchronous clock for calculating the sum of products, bus 111 has x1, bus 12 has AI+, bus 112 has X2,
A22 for 122, X3 for 113, A33 for 123
, and 11,, has X1, ]2. , has A■ on it. Therefore, the inner product calculation is performed as shown in the diagram at time T1 in FIG. 1(C). Since the value of the accumulator Y is 0 at this time, the value multiplied by 0 is added to the inner product result. When the product-sum operation is completed, a shift operation begins. That is, as shown in FIG. 1(D), a shift operation is performed between TI and T2, and data is shifted between adjacent trays. That is, a left shift is performed in this case. Then, the process moves to timing T2 in FIG. 1(C). Similarly, the operation timing shown in FIG. 1(D) corresponds to the time area of the sum of products of T2. Then shi? Therefore, X2 is stored in tray 2, X3 is stored in tray 22, and X m+1 is stored in tray 2m, and the elements of the coefficient matrix are also stored in trays 1, 2, .
・, m respectively have AI2, A23 Am I+l
+1 is input. This data is also shown on the lotus at the timing T2 in FIG. 1(D). Therefore, at timing T2, the product of A1 and X2 is calculated, and the sum with the previous accumulator Y is obtained. Therefore, in unit 11, A. and X
The sum of the product with 1 and the product of A+■ and X2 obtained at T2 is calculated and the result is stored in the accumulator. Similarly, in unit 12, the previous result A 22
The result of X 2 + A 23 X X 3 is stored in the accumulator. The same applies to unit 1■. Then, it shifts again and moves to timing T3. X3 is placed in tray l, X4 is placed in tray 2, Xmm+2 is placed in tray m, and X2 is placed in tray n, and an inner product calculation as shown in the diagram at time T3 in FIG. 1(C) is executed.

第1図(D)の動作タイξングの時間区域T3において
は、データ処理ユニ・ノトに入るべき入力の記号が示さ
れている。このような演算が進み、時間区域Tnまで行
うと、第1図(C)の時間区域T,,に示されるように
AIr+XXnは前の累積器との値に加えられると、ト
レイ21においては、T1で求めたAzXX+ ..T
zにおけるAI2X X2 、Telで求めたA,,X
X3等の積の和が求まり、Tn−1までの内積結果が累
算器Yに格納されているので、その結果にA 1 6 
X X (.が加わって行列Aの1行目とベクトルXと
の内積が実行される。トレイ22においては同様に、行
列八の2行目の行ベクトルとベクトルXとの内積演算が
nクロック周期で行われ、同様にm行目の行ベクトルと
、ヘクトルXの内積がデータ処理ユニソトl.で実行さ
れる。
In the time period T3 of the operation timing ξ in FIG. 1(D), the symbols of the inputs to be entered into the data processing unit are shown. When this kind of calculation progresses and is performed up to time area Tn, as shown in time area T, , in FIG. 1(C), when AIr+XXn is added to the value of the previous accumulator, in tray 21, AzXX+ determined at T1. .. T
AI2X X2 at z, A,,X determined by Tel
The sum of products such as
X X (. is added and the inner product of the first row of matrix A and vector Similarly, the inner product of the m-th row vector and the hector X is performed in the data processing unit 1.

従って、このような時系列で処理を行うことによって、
mXnの長方行列とn次元ベクトルとの乗算がm個のデ
ータ処理ユニットを用いてnに比例する処理時間で実行
可能となる。従って、良好な台数効果を得ることが可能
となる。ここで重要なことは、データを処理するデータ
処理ユニノトと、データ保持機能を有するトレイとを分
離し、それぞれの個数を長方行列の行と列に対応させ、
それらの次元が異なっていても、時系列動作が同期的に
可能となっている点である。なおnがmよりも小さい場
合でもm個のトレイ2を用いることで処理時間は延びる
が、すなわちmに比例するが、台数効果的な処理が可能
となる。
Therefore, by performing processing in such a chronological order,
Multiplication of an m×n rectangular matrix by an n-dimensional vector can be performed using m data processing units in a processing time proportional to n. Therefore, it is possible to obtain a good effect on the number of units. What is important here is to separate the data processing unit that processes data from the tray that has the data holding function, and to make the number of each correspond to the rows and columns of the rectangular matrix.
The point is that time-series operations can be performed synchronously even if their dimensions are different. Note that even if n is smaller than m, the processing time will be extended by using m trays 2, that is, it will be proportional to m, but it will be possible to process the trays effectively in terms of the number of trays 2.

第2図(A)は第1図の構成の詳細ブロック図であり、
mXn (n≧m≧1)の行列Aと要素数nのベクトル
Xの積Y(要素数m)を求めるものである。同図におい
て、第1図で示したものと同一のものは同一の記号で示
してあり、1aはデータ処理ユニットlの処理装置であ
り、例えばデジタルシグナルプロセッサで構成され、2
aはトレイ2のデータ保持回路であり、例えばラッチ回
路で構成され、2bはトレイ2のデータ転送回路であり
、例えばハスドライバで構威され、2Cはトレイ2の制
御手段であり、例えば論理回路で構威され、4はデータ
処理ユニット1にデータを供給する手段の一部であると
同時にデータ処理ユニット1を制御する手段の一部であ
る記憶装置であり、例えばRAM (ラングムアクセス
メモリ)で構成され、5はデータ処理ユニット1とトレ
イ2の同期動作を行う手段であり、5aはクロック発生
回路であり、例えば水晶発振回路で構威され、5bはク
ロック分配回路であり、例えばバッファ回路から構威さ
れる。
FIG. 2(A) is a detailed block diagram of the configuration of FIG. 1,
This is to find the product Y (number of elements m) of matrix A of mXn (n≧m≧1) and vector X of n elements. In the same figure, the same parts as shown in FIG.
2b is a data transfer circuit for the tray 2, such as a lotus driver, and 2C is a control means for the tray 2, such as a logic circuit. 4 is a storage device which is part of the means for supplying data to the data processing unit 1 and at the same time is part of the means for controlling the data processing unit 1, such as RAM (Rangular Access Memory). 5 is a means for synchronizing the data processing unit 1 and the tray 2, 5a is a clock generation circuit, for example, a crystal oscillation circuit, and 5b is a clock distribution circuit, for example, a buffer circuit. is threatened by

本実施例の動作は本発明の原理図で説明した動作とほぼ
同しである。
The operation of this embodiment is almost the same as the operation explained in the principle diagram of the present invention.

第2図(B)は第2図(A)の本発明のシステムの動作
フローチャートである。第2図(A)に示されるように
本発明ではデータ処理ユニット1とデータ保持機能を有
するトレイ2とを分離し、さらにトレイを隣接間で接続
し、巡回接続することによってシストリックなシステム
を構戒している。データ処理ユニソトの数をm、トレイ
の数をnとした場合に、mXnの行列Aと要素数mのベ
クトルXとの積を求める場合、第4図(B)のフローチ
ャートに示される動作となる。X1をトレイ2iにセッ
トする。Y1の値を0にする。すな?ちデータ処理ユニ
ットのi番目のユニットにおける累積レジスタの値を初
期化する。i番目の処理ユニットをhは111からの入
力と、12.の入力を掛け合わせて、積を累算器Yiに
足し込む。そしてシフトレジスタ3をシフトする。この
内積とシフト動作をn回繰り返す。この処理において長
方行列AとベクトルXとの積が形成される。
FIG. 2(B) is an operation flowchart of the system of the present invention shown in FIG. 2(A). As shown in FIG. 2(A), in the present invention, a data processing unit 1 and a tray 2 having a data holding function are separated, and the trays are connected between adjacent trays for circular connection, thereby creating a systolic system. I am cautious. When the number of data processing units is m and the number of trays is n, when calculating the product of a matrix A of mXn and a vector X of m elements, the operation is shown in the flowchart of Figure 4 (B). . Set X1 on tray 2i. Set the value of Y1 to 0. sand? First, the value of the accumulation register in the i-th data processing unit is initialized. The i-th processing unit h receives input from 111 and 12. , and add the product to the accumulator Yi. Then, shift register 3 is shifted. This inner product and shift operation is repeated n times. In this process, a product of rectangular matrix A and vector X is formed.

この場合、トレイ間のデータ転送とデータ処理ユニノト
におけるデータ処理とは同時並行処理となる。
In this case, data transfer between trays and data processing in the data processing unit are simultaneous and parallel processes.

第2図(C)は本発明方式の動作概念図である。FIG. 2(C) is a conceptual diagram of the operation of the system of the present invention.

同図においてトレイ2内のデータX1からXnはベクト
ルXの要素でその個数はnであるとする。
In the figure, it is assumed that data X1 to Xn in tray 2 are elements of vector X, and the number thereof is n.

またデータ処理ユニットはm個あり、その各々に累積器
がY+ ,Yz ,  ・・・,Y..がある。m×n
の長方行列の要素はA目からA■までのmXn個存在す
る。データ処理ユニットのhには係数行列の第1行目で
あるAz.. Arz+  ・・・. Axnが同期的
に121の入力パスから入力される。またデータ処理ユ
ニット12はA22、A23,・・・?Hがシストリッ
ク動作の各タイミングで順番に与えられる。また、デー
タ処理ユニット1ffiにはA mm+ Am m++
 +  ” ’ + Am .w−1が同期的に与えら
れる。
Furthermore, there are m data processing units, each of which has an accumulator Y+, Yz, . . . , Y. .. There is. m×n
There are mXn elements of the rectangular matrix from A to A. h of the data processing unit has Az. which is the first row of the coefficient matrix. .. Arz+... Axn is synchronously input from 121 input paths. Also, the data processing units 12 are A22, A23,...? H is given in turn at each timing of the systolic operation. In addition, the data processing unit 1ffi has A mm+ Am m++
+ ” ' + Am .w-1 is given synchronously.

第2図(D)は第2図(C)の動作のタイミングチャー
トである。時間T,からTnの動作は第1図(C)のそ
れぞれの図と第1図(D)の時間Tr , Tz . 
 ・・・,T7とが対応している。時間タイミングT1
においては,第2図(C)に示されるように、トレイ2
1,22,  ・・・,2nにはX,,X2+ X.,
  ・−・,Xnがあり、ユニソ}11,12,  ・
・・,lmにはそれぞれ係数行列の要素AIt, Az
z, A一が入力されている。
FIG. 2(D) is a timing chart of the operation of FIG. 2(C). The operations from time T, to Tn are shown in the respective diagrams of FIG. 1(C) and times Tr, Tz .
..., T7 correspond. Time timing T1
In this case, as shown in Fig. 2(C), the tray 2
1, 22, ..., 2n has X, , X2+ X. ,
・-・, Xn, Uniso}11, 12, ・
..., lm are coefficient matrix elements AIt, Az, respectively
z and A1 are input.

従って、このタイミングにおいてデータ処理ユニット1
1のA11とトレイ21のデータX1との積を求め、デ
ータ処理ユニット12においてはトレイ22にあるX2
と、メモリから与えられるA2■との積を求め、同様に
、トレイmにおいてはAーとX1の積を求める。このタ
イミングは第2図(D)のT1のタイミングで行われて
いる。すな?ち積和を求める同期クロックにおいて、バ
ス1hにはX1があり、バス121にはA + +があ
り、バス11■にはX2、122にはA 2 2、11
3にはX3、123にはA33があり、111にはX1
、121には7!t, mmがのっている。従って、第
2図(C)のT1タイムにおける図に示すように内積演
算が行われる。累積器Yの値はこの時は0であるから内
積結果はOに掛けた値が加わることになる。積和演算が
終わるとシフト動作に入る。すなわち第2図(D)の図
に示されるようにT+ とT2との間がシフト動作であ
り、トレイの隣接するトレイ間でデータのシフトが行わ
れる。すなわち左シフトがこの場合行われる。すると第
2図(C)のタイミングT2に移る。第2図(D)の動
作タイミングでも同様にT2の積和の時間区域となる。
Therefore, at this timing, the data processing unit 1
1 and the data X1 on the tray 21, and the data processing unit 12 calculates the product of the data X2 on the tray 22.
and A2■ given from memory, and similarly, for tray m, the product of A- and X1 is found. This timing is performed at the timing T1 in FIG. 2(D). sand? In other words, in the synchronous clock that calculates the sum of products, bus 1h has X1, bus 121 has A + +, bus 11■ has X2, and 122 has A 2 2, 11.
3 has X3, 123 has A33, 111 has X1
, 7 for 121! It has t and mm on it. Therefore, the inner product calculation is performed as shown in the diagram at time T1 in FIG. 2(C). Since the value of the accumulator Y is 0 at this time, the value multiplied by O is added to the inner product result. When the product-sum operation is completed, a shift operation begins. That is, as shown in FIG. 2(D), a shift operation is performed between T+ and T2, and data is shifted between adjacent trays. That is, a left shift is performed in this case. Then, the process moves to timing T2 in FIG. 2(C). Similarly, the operation timing shown in FIG. 2(D) corresponds to the time area of the sum of products of T2.

するとシフトされているからトレイ21にはX2、トレ
イ22にはX3、そしてトレイし2mにはX ffl+
 1が格納され、また、係数行列の要素もトレイ21,
22,  ・・−,2mにはそれぞれAI2. A23
. A−■1が入力される。これは第2図(D)のT2
の?イミングにおいてもバス上のデータがそれぞれ示さ
れている。従って、T2のタイミングにおいて、A1■
とX2との積をとり、前の累積器Yとの和が求められる
。従って、ユニット11においてはT1において求まっ
たAI.とXI との積とT2において求められるA1
2とX2との積との和が求められ、その結果が累積器に
格納される。同様にユニット12においては前の結果で
あるA zz X X 2+ A 2 3 X X 3
の結果が累積器に格納される。ユニット1mに対しても
同様である。そしてまたシフトし、タイミングT3に移
る。トレイ21にはX3、トレイ22にはX4、トレイ
2mにはXlll。2、トレイ2nにはX2が入り、第
2図(C)のT,時間における図に示されるような内積
演算が実行される。
Then, since it has been shifted, there is X2 on tray 21, X3 on tray 22, and X ffl+ on tray 2m.
1 is stored, and the elements of the coefficient matrix are also stored in the tray 21,
22,...-, 2m each have AI2. A23
.. A-■1 is input. This is T2 in Figure 2 (D)
of? The timing also shows the data on the bus. Therefore, at the timing of T2, A1■
The product of and X2 is taken, and the sum with the previous accumulator Y is determined. Therefore, in unit 11, the AI. A1 obtained at the product of and XI and T2
The product of 2 and X2 is summed and the result is stored in an accumulator. Similarly, in unit 12, the previous result A zz X X 2+ A 2 3 X X 3
The result is stored in the accumulator. The same applies to the unit 1m. Then, it shifts again and moves to timing T3. X3 for tray 21, X4 for tray 22, and Xlll for tray 2m. 2. X2 enters the tray 2n, and the inner product calculation as shown in the diagram at T and time in FIG. 2(C) is executed.

第2図(D)の動作タイミングにおいての時間区域T3
においては、データ処理ユニットに入るべき入力の記号
が示されている。このような演算が進み、時間区域Tn
まで行うと第2図(C)の時間区域T.に示されるよう
にA+.xX,+は前の累積器との値に加えられると、
トレイIにおいてはT+で求めたA++XX I,T2
におけるA,2×X2、T3で求めたA 1 3X X
 3等の積の和が求まり、’rn−+までの内積結果が
累積器Yに格納されているので、その結果にA 1 1
1 X X,,が加わって行列Aの1行目とへクトル見
との内積が実行される。
Time zone T3 in the operation timing of FIG. 2(D)
In , the symbols of the inputs to be entered into the data processing unit are shown. As such calculations proceed, the time area Tn
If the process is performed up to the time zone T in FIG. 2(C). As shown in A+. When xX,+ is added to the value with the previous accumulator,
For tray I, A++ determined by T+ I, T2
A, 2×X2, A 1 3X X determined by T3
The sum of the 3-magnitude products is found, and the inner product result up to 'rn-+ is stored in the accumulator Y, so the result is A 1 1
1 X

トレイ2においては同様に、行列八の2行目の行ベクト
ルとベクトルXとの内積演算がnクロック周期で行われ
、同様にm行目の行ベクトルと、ベクトルXの内積がデ
ータ処理ユニソト11Iで実行される。従って、このよ
うな時系列で処理を行うことによってmxnの長方行列
とn次元ベクトルとの乗算がm個のデータ処理ユニット
を用いてnに比例する処理時間で実行可能となる。従っ
て、良好な台数効果を得ることが可能となる。
Similarly, in tray 2, the inner product calculation of the row vector of the second row of matrix 8 and the vector is executed. Therefore, by performing processing in such a time series, multiplication of an m×n rectangular matrix by an n-dimensional vector can be performed using m data processing units in a processing time proportional to n. Therefore, it is possible to obtain a good effect on the number of units.

第3図は、本発明の第2の実施例説明図である。FIG. 3 is an explanatory diagram of a second embodiment of the present invention.

mXnの行列Aと要素数nのヘクトルXとの積に対し、
引き続きkXmの行列旧を左から掛ける場合の動作に対
するシストリック方式の構戒図である。第3図(A)に
おいて第1図で示したものと同一のものは同一の記号で
示してある。すなわち1aはデータ処理ユニットlの処
理装置であり、例えばデジタルシグナルプロセッサであ
る。2aはトレイ2のデータ保持回路であり、例えばラ
ッチ回路で構成され、2bはトレイ2のデータ転送回路
であり、例えばバスドライバで構戒され、2Cはトレイ
2の制御手段であり、例えば論理回路で構成されている
。4はデータ処理ユニット1にデータを供給する手段の
一部であると同時にデータ処理ユニット1を制御する手
段の一部でもある記憶装置であって、例えばRAM (
ランダムアクセスメモリ)で構成されている。5はデー
タ処理ユニット1とトレイ2の同期動作を行う手段であ
り、内部の5aは、クロツク発生回路で、例えば、水晶
発振回路で構成され、5bはクロック分配回路であり、
例えば、バッファ回路から構威される。
For the product of mXn matrix A and hector X with n elements,
It is a composition diagram of the systolic method for the operation when the matrix old of kXm is subsequently multiplied from the left. Components in FIG. 3(A) that are the same as those shown in FIG. 1 are indicated by the same symbols. That is, 1a is a processing device of the data processing unit 1, for example a digital signal processor. 2a is a data holding circuit for the tray 2, which is composed of, for example, a latch circuit; 2b is a data transfer circuit for the tray 2, which is controlled by, for example, a bus driver; and 2C is a control means for the tray 2, which is composed of, for example, a logic circuit. It consists of Reference numeral 4 denotes a storage device which is part of the means for supplying data to the data processing unit 1 and at the same time is part of the means for controlling the data processing unit 1, such as a RAM (
consists of random access memory). 5 is a means for synchronizing the data processing unit 1 and the tray 2; 5a therein is a clock generation circuit, for example, a crystal oscillation circuit; 5b is a clock distribution circuit;
For example, it can be constructed from a buffer circuit.

6はシストリック的に戻るデータとトレイに入力する場
合のデータと外部データとの選択を行う選択回路で、7
はシストリックされるデータを途中からバイパスする選
択回路である。
6 is a selection circuit that selects between systically returned data, data to be input into the tray, and external data;
is a selection circuit that bypasses systolic data from the middle.

本実施例は、中間結果Axを求めるところまでは第1の
実施例と全く同一であり、各データ処理ユニット中にそ
の中間結果Axの各要素が求まっている状態から (a)中間結果をトレイ2に書き込み、(b)バイパス
の選択回路7をオンさせて、シフトレジスタの長さをm
に変更し、 (C)以後は本発明の第1の実施例において、行列Aを
行列旧に、そして、nをmに、mをkにそれぞれ変更す
ればまったく同じ動作となる。
This embodiment is exactly the same as the first embodiment up to the point where the intermediate result Ax is obtained, and from a state in which each element of the intermediate result Ax has been obtained in each data processing unit, (a) the intermediate result is transferred to the tray. (b) Turn on the bypass selection circuit 7 and set the length of the shift register to m.
(C) From now on, in the first embodiment of the present invention, if matrix A is changed to matrix old, n is changed to m, and m is changed to k, the operation will be exactly the same.

第3図(B)は第2の実施例の動作フローチャート、第
3図(C)は第2の実施例の動作概要図、第3図(D)
は第2の実施例の動作タイムチャートである。
FIG. 3(B) is an operation flowchart of the second embodiment, FIG. 3(C) is an operation overview diagram of the second embodiment, and FIG. 3(D)
is an operation time chart of the second embodiment.

まず、mXnの行列Aと要素数nのへクトルXとの積、
そして、kXmの行列旧を左から掛ける場合、第3図(
B)のフローチャートに示される動作となる。Xiをト
レイ21にセットする。ytO値を0にする。すなわち
データ処理ユニットのi番目のユニットにおける累積レ
ジスタの値を初期化する。i番目の処理ユニットhはl
ltからの入力と、12+の入力を掛け合わせて、積を
累積器Ylに足し込む。そしてシフトレジスタ3をシフ
トする。この内積とシフト動作をn回繰り返す。この処
理において長方行列AとベクトルXとの積が形威される
First, the product of a matrix A of mXn and a hector X of n elements,
Then, when multiplying the kXm matrix old from the left, Figure 3 (
The operation is shown in the flowchart B). Set the Xi on the tray 21. Set the ytO value to 0. That is, the value of the accumulation register in the i-th data processing unit is initialized. The i-th processing unit h is l
Multiply the input from lt by the input from 12+ and add the product to accumulator Yl. Then, shift register 3 is shifted. This inner product and shift operation is repeated n times. In this process, the product of rectangular matrix A and vector X is expressed.

次に、シフトレジスタの長さをmに変更し、Y1をトレ
イ2iに転送する。そして、Z+  (i=1,・・・
,k)をOにする。次にB行列を掛けるために、まず、
i番目の処理ユニットhと1hからの入力と121の入
力を掛け合わせて、積を累積器Ziに足し込む。そして
、シフトレジスタ3をシフトするこの内積とシフト動作
をk回繰り返す。
Next, the length of the shift register is changed to m, and Y1 is transferred to tray 2i. And Z+ (i=1,...
, k) to O. Next, in order to multiply the B matrix, first,
The inputs from the i-th processing units h and 1h are multiplied by the input of 121, and the product is added to the accumulator Zi. Then, this inner product and shift operation for shifting the shift register 3 is repeated k times.

第3図(C)は以上の動作概念図である。同図において
トレイ2内のデータX1からX。はベクトルXの要素で
その個数はまず、nであるとする。
FIG. 3(C) is a conceptual diagram of the above operation. In the figure, data X1 to X in tray 2. is an element of vector X and its number is first assumed to be n.

またデータ処理ユニットは最初は、m個が有効で、その
各々に累積器がY+ ,Yz ,  ・・・,Y.があ
るとする。まず、mXnの長方行列Aの要素は?.から
A■までのmXn個存在する。データ処理ユニットのh
には係数行列の第1行目であるA++, A.+2+ 
 + H +, AH,1が同期的に121の入力ハス
から入力される。またデータ処理ユニット1■はA 2
 2 , A 2 3 ,  ・・・,A2.がシスト
リック動作の各タイミングで順番に与えられる。また、
データ処理ユニット1ゆにはA a s + A a 
m + + +・・+  All It−l が同期的
に与えられる。
In addition, m data processing units are initially effective, and each of them has an accumulator Y+, Yz, . . . , Y. Suppose there is. First, what are the elements of mXn rectangular matrix A? .. There are mXn numbers from A to A. data processing unit h
The first row of the coefficient matrix is A++, A. +2+
+H+, AH,1 are synchronously input from 121 input lotuses. Also, data processing unit 1■ is A2
2, A23, ..., A2. are given in turn at each timing of the systolic operation. Also,
Data processing unit 1: A a s + A a
m + + +...+ All It-l are given synchronously.

第3図(D)は第3図(C)の動作のタイミングチャー
トである。時間T1からT0の動作は第3図(C)のそ
れぞれの図と第3図(D)の時間TI,T2 ,  ・
・・,Tnとが対応している。時間タイミングT,にお
いては、第3図(C)に示されるように、トレイの1,
2,・・・,nにはXI   X2,  ・・・,X,
,・・・,X,があり、ユニッl−1.2,  ・・・
,k,・・・,mにはそれぞれ係数行列の要素AII.
A2■,・・・,Akk,・・・,A..が入力されて
いる。従って、このタイミングにおいてデータ処理ユニ
ットは、トレイ1において、A11とトレイlのデータ
X1との積?求め、データ処理ユニット2においてはト
レイ2にあるX2と、メモリから与えられるA22との
積を求め、同様に、トレイkにおいてはAkkとXkの
積を求め、トレイmにおいて、A mlllとX8の積
を求める。このタイミングは第3図(D)のTのタイミ
ングで行われている。すなわち積和を求める同期クロッ
クにおいて、バス11+ にはX,があり、バス121
にはAI1があり、ハス112にはXz、12zにはA
22、11kにはX,、12kにはAkkがあり、11
■にはX.、l21IにはA一がのっている。従って、
第3図(C)のT,タイムにおける図に示すように、内
積演算が行われる。累積器Yの値はこの時は0であるか
ら内積結果はOに掛けた値が加わることになる。積和演
算が終わるとシフト動作に入る。すなわち第3図(D)
の図に示されるように、T,とT2との間がシフト動作
であり、トレイの隣接するトレイ間でデータのシフトが
行われる。すなわち左シフトがこの場合行われる。する
と第3図(C)のタイミングT2に移る。第3図(D)
の動作タイミン?でも同様にT2の積和の時間区域とな
る。するとシフトされているからトレイ1にはx2、ト
レイ2にはX3、トレイkにはXk.■、そしてトレイ
mにはX1.,が格納され、また、係数行列の要素もト
レイ1,2,・・・,k,・・・,mにはそれぞれAI
21 A23,  ・・・Ay k++ ,  ・・・
,Asll1。1が入力される。これは第3図(D)の
T2のタイミングにおいてもバス上のデータがそれぞれ
示されている。従ってT2のタイミングにおいて、AI
■とX2との積をとり、前の累積器Yとの和が求められ
る。従ってトレイ1においてはT+において求まったA
.とX1との積とT2において求められるA1■とX2
との積との和が求められその結果が累積器に格納される
。同様にトレイ2においては前の結果であるA22X 
X2 +A2]X X3の結果が累積器に格納される。
FIG. 3(D) is a timing chart of the operation of FIG. 3(C). The operation from time T1 to T0 is shown in each diagram in FIG. 3(C) and at time TI, T2, ・ in FIG. 3(D).
..., Tn correspond. At time timing T, as shown in FIG. 3(C), tray 1,
2,...,n is XI X2,...,X,
,...,X, and the unit l-1.2,...
, k, . . . , m each have coefficient matrix elements AII.
A2■,...,Akk,...,A. .. is entered. Therefore, at this timing, the data processing unit calculates the product of A11 and the data X1 of tray 1 in tray 1? In data processing unit 2, the product of X2 in tray 2 and A22 given from memory is found. Similarly, in tray k, the product of Akk and Xk is found, and in tray m, the product of A mlll and X8 is found. Find the product. This timing is performed at timing T in FIG. 3(D). In other words, in the synchronous clock that calculates the sum of products, bus 11+ has X, and bus 121
has AI1, Has112 has Xz, 12z has A
22, 11k has X, 12k has Akk, 11
■ is X. , l21I has A1 on it. Therefore,
As shown in the diagram at T and time in FIG. 3(C), an inner product calculation is performed. Since the value of the accumulator Y is 0 at this time, the value multiplied by O is added to the inner product result. When the product-sum operation is completed, a shift operation begins. That is, Figure 3 (D)
As shown in the figure, the shift operation is between T and T2, and data is shifted between adjacent trays. That is, a left shift is performed in this case. Then, the process moves to timing T2 in FIG. 3(C). Figure 3 (D)
Operation timing? Similarly, it becomes the time domain of the sum of products of T2. Then, since they have been shifted, x2 is placed on tray 1, X3 is placed on tray 2, and Xk is placed on tray k. ■, and tray m has X1. , and the elements of the coefficient matrix are also stored in trays 1, 2, ..., k, ..., m, respectively.
21 A23, ...Ay k++, ...
, Asll1.1 are input. This also shows the data on the bus at the timing T2 in FIG. 3(D). Therefore, at timing T2, AI
2 is multiplied by X2, and the sum with the previous accumulator Y is obtained. Therefore, in tray 1, A found at T+
.. A1■ and X2 found at the product of and X1 and T2
The sum of the product and the product is calculated and the result is stored in the accumulator. Similarly, in tray 2, the previous result is A22X
The result of X2 + A2]X X3 is stored in the accumulator.

トレイkやmに対しても同様である。そしてまたシフト
し、タイミングT3に移る。トレイ1にはX3、トレイ
2にはX4、トレイkにはXkk.■、トレイmにはX
I,l..2、トレイnにはX2が入り、第3図(C)
の?3時間における図に示されるような内積演算が実行
される。
The same applies to trays k and m. Then, it shifts again and moves to timing T3. Tray 1 has X3, tray 2 has X4, tray k has Xkk. ■、X for tray m
I, l. .. 2. Tray n contains X2, Figure 3 (C)
of? A dot product operation as shown in the figure at 3 hours is performed.

このような演算が進み、時間区域Tnまで行うと第3図
(C)の時間区域T,,lに示されるようにA,。×X
IIが前の累積器との値に加えられるとトレイ1におい
てはT,で求めたAIIXXI 、T2におけるAI■
X X2 、T*で求めたAIkXχ、等の積の和が求
まり、Tn−Iまでの内積結果が累積器Yに格納されて
いるので、その結果にAlnXXnが加わって行列Aの
I行目とベクトル入との内積が実行される。トレイ2に
おいては同様に行列八の2行目の行ヘクトルとベクトル
罵との内積演算がnクロック周期で行われ、同様にk行
目の行ベクトルと、ベクトルXの内積がデータ処理ユニ
ン}lmで実行される。
When this kind of calculation progresses and is performed up to time area Tn, A, as shown in time area T,,l in FIG. 3(C). ×X
When II is added to the value of the previous accumulator, T in tray 1, AIIXXI determined by T, AI■ in T2
The sum of the products of X Dot product with vector input is performed. Similarly, in tray 2, the inner product calculation of the row hector of the second row of matrix 8 and the vector is performed in n clock cycles, and similarly, the inner product of the row vector of the k-th row and the vector is executed.

データ処理ユニットの有効数をk、トレイの有効数をm
とした場合に、kXmの行列Bと要素数mのヘクトルy
との積を求める動作となる。Ylをトレイ2の1iにセ
ットする。Zlの値をOにする。すなわちデータ処理ユ
ニットのi番目のユニットにおける累積レジスタの値を
初期化する。
The effective number of data processing units is k, and the effective number of trays is m.
In this case, matrix B of kXm and hector y of m elements
The operation is to find the product of . Set Yl on tray 2 1i. Set the value of Zl to O. That is, the value of the accumulation register in the i-th data processing unit is initialized.

i番目の処理ユニットhはILからの入力と、121の
入力を掛け合わせて、積を累積器Ziに足し込む。そし
てシフトレジスタ3をシフトする。
The i-th processing unit h multiplies the input from IL by the input of 121, and adds the product to the accumulator Zi. Then, shift register 3 is shifted.

この内積とシフト動作をm回繰り返す。この処理におい
て長方行列Bとベクトル1との積が形威される。
This inner product and shift operation is repeated m times. In this process, the product of rectangular matrix B and vector 1 is expressed.

第3図(C)においてトレイ2内のデータY1からY。In FIG. 3(C), data Y1 to Y in tray 2.

はベクトルlの要素でその個数はmであるとする。また
データ処理ユニットの有効数はk個あり、その各々に累
積器がZl,Z2,  ・・・Zkがある。kXmの長
方行列Bの要素はBl+からBk..までのkXm個存
在する。データ処理ユニットの11には係数行列Bの第
1行目であるBll、B12,・・・.B1.が同期的
に12+の人カバスから入力される。またデータ処理ユ
ニットl2はB 22,  B 23,  ・・・,B
21がシストリック動作の各タイミングで順番に与えら
れる。また、データ処理ユニット1kにはB++h, 
Bh k。1,・・・Bh h−+が同期的に与えられ
る。
is an element of vector l and its number is m. Further, the effective number of data processing units is k, and each of them has an accumulator Zl, Z2, . . . Zk. The elements of the kXm rectangular matrix B are from Bl+ to Bk. .. There are up to kXm pieces. The data processing unit 11 stores the first row of the coefficient matrix B, Bll, B12, . B1. is input synchronously from 12+ people's cabs. Moreover, the data processing unit l2 has B 22, B 23, ..., B
21 are given in turn at each timing of the systolic operation. In addition, the data processing unit 1k includes B++h,
Bhk. 1,...Bh h-+ are given synchronously.

?3図(D)は第3図(C)の動作のタイピングチャー
トでも同様の記号が使われている。時間T,,。1から
Tn。.1の動作は第3図(C)のそれぞれの図と第3
図(D)の時間とが対応している。
? Similar symbols are used in FIG. 3(D) in the typing chart for the operation in FIG. 3(C). Time T,. 1 to Tn. .. The operation of step 1 is shown in each figure in Figure 3 (C) and in Figure 3.
This corresponds to the time shown in Figure (D).

時間タイミングT n + + においては第3図(C
)に示されるように、トレイ1,2,・・・,mにはY
+ ,Y2 ,  ・・・,Y.が移され、ユニットl
.2,・・・,kにはそれぞれ係数行列Bの要素BB2
■,・・・,Bkkが入力されている。次のタイごング
T n + 2においてデータ処理ユニット1において
Bl+とトレイ1のデータY1との積を求め、データ処
理ユニット2においてはトレイ2にあるY2と、メモリ
から与えられるE3zzとの積を求め、同様にユニット
kにおいてはBkkとY,の積を求める。このタイξン
グは第5図(d)のT0+2のタイミングで行われてい
る。すなわち積和を求める同期クロックにおいて、バス
11+にはY,があり、バス12+にはBllがあり、
バス11■にはY2、122にはB22、113にはY
3、123にはB。
At time timing T n + + , as shown in Fig. 3 (C
), trays 1, 2, ..., m have Y
+ , Y2 , ..., Y. is transferred, unit l
.. 2,...,k are elements BB2 of coefficient matrix B, respectively.
■,...,Bkk are input. In the next timing T n + 2, the data processing unit 1 calculates the product of Bl+ and the data Y1 of the tray 1, and the data processing unit 2 calculates the product of Y2 in the tray 2 and E3zz given from the memory. Similarly, in unit k, the product of Bkk and Y is found. This timing ξ is performed at timing T0+2 in FIG. 5(d). In other words, in the synchronous clock for calculating the sum of products, bus 11+ has Y, bus 12+ has Bll,
Y2 for bus 11■, B22 for 122, Y for 113
3, 123 is B.

があり、llkにはYh,12hにはBkkがのっ?い
る。従って、第3図(C)のT n 4 2における図
に示すように内積演算が行われる。累積器Zの値はこの
時は0であるから内積結果はOに掛けた値が加わること
になる。積和演算が終わるとシフト動作に入る。すなわ
ち第3図(D)の図に示されるようにT n + 2 
とT。。3との間がシフト動作であり、トレイの隣接す
るトレイ間でデータのシフトが行われる。すなわち左シ
フトがこの場合行われる。すると第3図(C)のタイミ
ングT n + ffに移る。第3図(D)の動作タイ
ミングでも同様にT n + 3の積和の時間区域とな
る。すると、シフトされているからトレイ1にはY2、
トレイ2にはY3、そしてトレイkにはYkや.が格納
され、また、係数行列Bの要素もトレイ1,2,・・・
,kにはそれぞれB1■+B23+  ・・・+ Bk
 k+1が入力される。これは第3図(D)のT0.3
のタイミングにおいてもバス上のデータがそれぞれ示さ
れている。従ってT,。3のタイξングにおいてB1■
とY2との積をとり、前の累積器Zとの和が求められる
。従って、ユニット1においては、T,。2?おいて求
まったB.とY1との積とT■3において求められるB
1■とY2との積との和が求められその結果が累積器Z
に格納される。同様にユニット2においては前の結果で
あるB2■X Yz + B 23×Y3の結果が累積
器Zに格納される。トレイkに対しても同様である。そ
してまたシフトし、タイミングT0.4に移る。
There is Yh in llk and Bkk in 12h? There is. Therefore, the inner product calculation is performed as shown in the diagram at T n 4 2 in FIG. 3(C). Since the value of the accumulator Z is 0 at this time, the value multiplied by O is added to the inner product result. When the product-sum operation is completed, a shift operation begins. That is, as shown in the diagram of FIG. 3(D), T n + 2
and T. . 3 is a shift operation, in which data is shifted between adjacent trays. That is, a left shift is performed in this case. Then, the process moves to timing T n + ff in FIG. 3(C). Similarly, the operation timing shown in FIG. 3(D) corresponds to the time area of the sum of products of T n +3. Then, since it has been shifted, tray 1 has Y2,
Tray 2 has Y3, and tray k has Yk and so on. are stored, and the elements of coefficient matrix B are also stored in trays 1, 2,...
, k respectively have B1■+B23+ ...+ Bk
k+1 is input. This is T0.3 in Figure 3 (D)
The data on the bus is also shown at the timing of . Therefore, T. In the tying ξ of 3, B1■
is multiplied by Y2 and summed with the previous accumulator Z. Therefore, in unit 1, T,. 2? B. B obtained from the product of and Y1 and T■3
The sum of the product of 1■ and Y2 is calculated and the result is stored in the accumulator Z.
is stored in Similarly, in unit 2, the previous result B2*X Yz + B23*Y3 is stored in the accumulator Z. The same applies to tray k. Then, it shifts again and moves to timing T0.4.

このような演算が進み、時間区域T n + a + 
1まで行うと第3図(C)の時間区域T rl + m
 + 1に示されるようにBIMX Y 11が前の累
積器Zとの値に加えられるとユニットlにおいてはTn
。2で求めたB+xy, 、Tn.2におけるBI2X
Y2 、Tn+3で求めたB .]X Y3等の積の和
が求まり、T Q +。までの内積結果が累積器Zに格
納されているので、その結果にBl■×Y.が加わって
行列Bの1行目とへクトルlとの内積が実行される。ユ
ニット2においては同様に行列Bの2行目の行ベクトル
とベクトルlとの内積演算が行われ、同様にk行目の行
ヘクトルと、ベクトルyの内積がデータ処理ユニットl
kで実行される。従って、このような時系列で処理を行
うことによってkXmの長方行列旧に対してmに比例す
る処理時間で実行可能となり、従って良好な台数効果を
得ることが可能となる。
As such calculations proceed, the time area T n + a +
1, the time area T rl + m in Figure 3 (C)
+ 1, when BIMX Y 11 is added to the value with the previous accumulator Z, in unit l Tn
. B+xy, , Tn. BI2X in 2
Y2, B determined by Tn+3. ]X Y3, etc. The sum of the products is found, and T Q +. Since the inner product result up to is stored in the accumulator Z, the result is Bl■×Y. is added and the inner product of the first row of matrix B and hector l is performed. In unit 2, an inner product operation is similarly performed between the row vector of the second row of matrix B and vector l, and similarly, the inner product of the row hector of the k-th row and vector y is calculated by data processing unit l.
It is executed in k. Therefore, by performing the processing in such a time series, it becomes possible to perform the processing for a kXm rectangular matrix old in a processing time proportional to m, and therefore it becomes possible to obtain a good number of units effect.

本実施例においてはシフトレジスタ3の長さを変更でき
ること、及び中間結果をトレイ2に書き込み、それを新
たなデータとして処理できることが重要である。シフト
レジスタ3の長さを変更できなければ、データをすべて
巡回するためにn単位時間が必要になってしまう。また
中間結果を新たなデータとして処理できることで小規模
なハードウエアでリングシストリンクアレイ方弐より広
い範囲の処理が実行可能となっている。さらに書き込み
に要する時間が短くて各一定であることも重要である。
In this embodiment, it is important that the length of the shift register 3 can be changed and that intermediate results can be written to the tray 2 and processed as new data. If the length of the shift register 3 cannot be changed, it will take n units of time to cycle through all the data. Additionally, by being able to process intermediate results as new data, it is possible to perform a wider range of processing than the ring system link array method with small-scale hardware. Furthermore, it is important that the time required for writing is short and constant.

第4図は本発明の第3の実施例説明図である。FIG. 4 is an explanatory diagram of a third embodiment of the present invention.

このシステムではmxnの長方行列八の転置行列AT、
すなわち(nXm)の行列と要素数mのベクトルXとの
積とを計算するものである。同図において第1図に示し
たもの回しものは同一の記号で示してある。
In this system, the transposed matrix AT of eight mxn rectangular matrices,
That is, it calculates the product of an (nXm) matrix and a vector X having m elements. In the same figure, the rotating parts shown in FIG. 1 are indicated by the same symbols.

転置行列八〇とベクトルルとの積を求める場合において
は行列Aを構成する部分行ヘクトルを各データ処理ユニ
ット1に接続された記憶装置4中に格納し、演算途中に
生ずる部分和をトレイ中のデータ保持回路2a上に累積
しつつシフトレジスク3上のデータを循環させる。
When calculating the product of the transposed matrix 80 and the vector, the partial row hectors constituting the matrix A are stored in the storage device 4 connected to each data processing unit 1, and the partial sum generated during the calculation is stored in the tray. The data on the shift register 3 is circulated while being accumulated on the data holding circuit 2a.

第4図(A)は第3の実施例の構成の詳細ブロック図で
あり、nXm(n≧m≧1)の行列八〇と要素数mのベ
クトルXの積l(要素数n)を求めるものである。同図
において、第1図で示したものと同一のものは同一の記
号で示してあり、1aはデータ処理ユニット1の処理装
置であり、例えばデジタルシグナルプロセッサで構成さ
れ、2aはトレイ2のデータ保持回路であり、例えばラ
ッチ回路で構威され、2bはトレイ2のデータ転送回路
であり、例えばバスドライバで構威され、2Cはトレイ
2の制御手段であり、例えば論理回路で構成され、4は
データ処理ユニット1にデータを供給する手段の一部で
あると同時にデータ処?ユニット1を制御する手段の一
部である記憶装置であり、例えばRAM (ラングムア
クセスメモリ)で構威され、5はデータ処理ユニットl
とトレイ2の同期動作を行う手段であり、5aはクロッ
ク発生回路であり、例えば水晶発振回路で構成され、5
bはクロック分配回路であり、例えばバッファ回路から
構威される。
FIG. 4(A) is a detailed block diagram of the configuration of the third embodiment, and the product l (number of elements n) of a matrix 80 of nXm (n≧m≧1) and a vector X of m elements is calculated. It is something. In the figure, the same components as those shown in FIG. 2b is a holding circuit, for example, a latch circuit; 2b is a data transfer circuit for the tray 2, for example, a bus driver; 2C is a control means for the tray 2, which is composed of, for example, a logic circuit; is part of the means for supplying data to the data processing unit 1 and at the same time is a data processor? 5 is a storage device that is part of the means for controlling the unit 1, and is made up of, for example, a RAM (RAM); 5 is a data processing unit l;
and tray 2, and 5a is a clock generation circuit, which is composed of, for example, a crystal oscillation circuit;
b is a clock distribution circuit, which is composed of, for example, a buffer circuit.

第4図(B)は第3の実施例の動作フローチャートであ
る。Xiをユニットlt  (i=1,  ・・m)に
セットする。そしてYl  (i=1,・・ n)の値
をOにする。各ユニノトli はA■とX.を掛け合わ
せ、積をY,に足し込む動作をi=1,・・・,nに対
して行ってシフトする。
FIG. 4(B) is an operation flowchart of the third embodiment. Set Xi to unit lt (i=1, . . . m). Then, set the value of Yl (i=1, . . . n) to O. Each unit is A■ and X. , and add the product to Y for i=1, . . . , n, and then shift.

この動作をj ’= 1 ,  ・・・.mに対して繰
り返す。
This operation is expressed as j'=1, . Repeat for m.

転置行列とベクトルの掛け算は、記憶装置4中に格納さ
れた行列Aの各部分行ヘクトルをそのままにして計算可
能となり、これは後述するニューラルネットの学習アル
ゴリズムのlつであるバックプロバゲションの実行にお
いては極めて重要となる。またネットワークの量はオー
ダnですむこと。
The multiplication of a transposed matrix and a vector can be calculated by leaving each sub-row hector of the matrix A stored in the storage device 4 unchanged, and this can be done using backpropagation, which is one of the neural network learning algorithms described later. This is extremely important in execution. Also, the amount of network should be on the order of n.

?ングネットワークである。またデータ転送時間が処理
時間の影に隠れて転送時間に対するオーバヘッドはない
ことになる。しかもSIMD方式である。
? It is a networking network. Furthermore, since the data transfer time is hidden by the processing time, there is no overhead to the transfer time. Moreover, it is a SIMD method.

第4図(C)は第3の実施例の動作概要図である。ユニ
ット1.には、A.からA1■までを順に与えていく。
FIG. 4(C) is a schematic diagram of the operation of the third embodiment. Unit 1. In, A. to A1■ are given in order.

ユニット1■にはA22からA23,・・,A2.を与
え、k番目のユニットには記憶回路を介して、Aik.
  Ah k+1 .  ・・・■,  Ak k−1
を順に与える。m番目にはA I1ffi+  Am 
m。,,・・r As +,I−1 を順に与えていく
。また、トレイ上を循環するものはY,からY,,であ
る。
Unit 1 ■ includes A22 to A23,..., A2. Aik. is given to the k-th unit via a memory circuit.
Ah k+1. ...■, Ak k-1
are given in order. For mth, A I1ffi+ Am
m. ,,... r As +, I-1 are given in order. Moreover, the items circulating on the tray are Y, to Y,,.

第4図(D)は第3の実施例の動作タイムチャートであ
る。時間区域T1からT。までのバス上のデータが示さ
れ、これらは第6図(C)の時間区域T1からT。まで
の図にそれぞれ対応している。
FIG. 4(D) is an operation time chart of the third embodiment. Time zone T1 to T. The data on the bus up to and including the time period T1 to T of FIG. 6(C) are shown. Each corresponds to the previous figures.

時間区域T1においては、Y1からY,,まではすべて
0である。そしてA 1 1とX1との積がユニット1
+ で形威され、それをY,に足し込む。それと同時に
A22とX2がY2に足し込まれ、Akk×?kがYk
に足し込み、A am X X mがY.に足し込まれ
る。そしてシフト動作に入るとタイミングT2になる。
In time area T1, all values from Y1 to Y, , are 0. And the product of A 1 1 and X1 is unit 1
It is expressed as +, and it is added to Y. At the same time, A22 and X2 are added to Y2, and Akk×? k is Yk
and A am X X m becomes Y. It is added to. Then, when the shift operation starts, timing T2 occurs.

すなわちYデータが循環する。第1のユニットではA 
1 2 X X 1が計算され、これがY2に足し込ま
れるが、そのY2はT1において求まったA2■xXz
の値が格納されているのでこれに足し込まれる。そのた
め、A22XX2+AI■XX,の結果がY2となる。
In other words, the Y data circulates. In the first unit A
1 2 X X 1 is calculated and added to Y2, but Y2 is A2 x Xz found at T1
Since the value of is stored, it is added to this. Therefore, the result of A22XX2+AI■XX becomes Y2.

同様にユニット2においては、前のY3の結果にA23
XX2が足し込まれる。
Similarly, in unit 2, A23 is added to the previous Y3 result.
XX2 is added.

k番目のユニットにおいてはY1.1にAkk.IXX
kが加えられる。また、m番目のユニットにはY.。1
にAm m++ X Xraが加えられことになる。
In the k-th unit, Akk. IXX
k is added. Also, the m-th unit has Y. . 1
Am m++ X Xra will be added to.

このようにYデータを循環するとm番目の時間区域Tn
においては、例えば第1のユニット1、においては、そ
の前までに求まったY,,にA,fiXX,が加えられ
る。またY+ にはA 2 1 X X zが加えられ
る。これを全体的に眺めてみると、例えば、ベクトルX
の第1の要素X1には、T1においてAIIと積がとら
れ、A . , X X ,が計算される。それはY1
に格納される。また、転置行列八〇の第1行?の第2番
目の要素A21XX2は実は最後のクロック周期T,,
において計算されている。これは同じY1に格納されて
いる形になっている。また、転置行列ATの第1行目の
最後の要素であるA1とX1との積は第4図(C)のク
ロック周期T,,1.2のm番目のユニットで計算され
ている。すなわちA1とX.の積がY+に足し込むこと
によって得られる。転置行列A7の第2行目においても
同様であり、AI■とX1との積はT2のクロンクにお
いては、ユニント1において計算されている。
When Y data is circulated in this way, the mth time area Tn
For example, in the first unit 1, A, fiXX, is added to Y, , which has been found up to that point. Further, A 2 1 X X z is added to Y+. Looking at this as a whole, for example, vector
The first element X1 of A. is multiplied with AII at T1, and A. , X X , are calculated. That is Y1
is stored in Also, the first row of the transposed matrix 80? The second element A21XX2 of is actually the last clock period T, .
It is calculated in This is stored in the same Y1. Further, the product of A1 and X1, which is the last element in the first row of the transposed matrix AT, is calculated in the mth unit of the clock period T, 1.2 in FIG. 4(C). That is, A1 and X. can be obtained by adding the product to Y+. The same holds true for the second row of the transposed matrix A7, and the product of AI■ and X1 is calculated in unit 1 at Cronk of T2.

また、A2■XXzはクロック周期T+の第2番目のユ
ニットにおいて行われている。モしてY2が再び循環し
て積の実行が行われるのは、時間区域T n − as
 * 3である。その時間区域以後は乗算が行われ、シ
フト動作が行われる。そして時間区域TnにおいてはY
2に足し込まれる値は第3番目のユニットであり、Y2
に足し込まれる値はA3■×X3である。従って、Tn
において転置行列AT・の第2行目とベクトルXの内積
が計算される。一般に第k番目のユニントに関してはk
番目のトレイからのデータ線が11kであるから第4図
(D)に示されるように、11,に示すところを追って
いけばよいことになる。すなわち、T1においてはYk
 十AkkXXk 、T2においてはY h − + 
f A kk+I xXk,T3においてはYh+B 
+Akk+2 Xkが計算され、Tn−1 においては
Yk−z + Ah k−zX,が計算され、時間区域
TnにおいてはYk.十八kk−1 Xkが計算される
ことになる。このことにより転置行列ATとm次元のベ
クトルXの積が実行される。すなわち、転置行列ATと
ベクトルXとの積を求める場合においては、行列Aを構
成する部分行ベクトルを各データ処理ユニッ}1に接続
された記憶装置4中に格納し、演算途中に生ずる部分和
をトレイ2中のデータ保持回路上に累積しつつシフトレ
ジスタ上を循環させている。
Further, A2■XXz is performed in the second unit of clock period T+. Then, Y2 is circulated again and the product is performed in the time area T n − as
*3. After that time period, a multiplication is performed and a shift operation is performed. And in the time area Tn, Y
The value added to 2 is the third unit, Y2
The value added to is A3×X3. Therefore, Tn
The inner product of the second row of the transposed matrix AT· and the vector X is calculated in . Generally, for the kth unit, k
Since the data line from the th tray is 11k, it is sufficient to follow the line 11, as shown in FIG. 4(D). That is, at T1, Yk
10AkkXXk, Y h − + at T2
f A kk+I xXk, Yh+B at T3
+Akk+2 18 kk-1 Xk will be calculated. As a result, the product of the transposed matrix AT and the m-dimensional vector X is executed. That is, when calculating the product of the transposed matrix AT and the vector is accumulated on the data holding circuit in tray 2 and circulated on the shift register.

このような方法により行列AとベクトルUとの積Xに継
続して行列Aの転置八〇とベクトルλの積を求める場合
は、行列AとベクトルUとの積を求める時に用いた各デ
ータ処理ユニット1に接続された記憶装置4中に格納さ
れた行列Aの各部分行ベクトルをそのまま用いて、すな
わち転置行列ATの部分行列を各データ処理ユニット1
に転送することなしに処理をおこなしうことかでき、従
って転送に要する時間が節約でき、さらに処理時間が短
縮できることになる。
When calculating the product of the transposed 80 of matrix A and the vector λ following the product X of matrix A and vector U using such a method, each data processing used when calculating the product of matrix A and vector U Each data processing unit 1 uses each partial row vector of the matrix A stored in the storage device 4 connected to the unit 1 as it is, that is, the partial matrix of the transposed matrix AT.
Processing can be performed without having to transfer the data to another computer, thereby saving time required for transfer and further reducing processing time.

第4図(E)は第4図(B)の繰り返し部分を詳細に分
解して示したフローチャートである。
FIG. 4(E) is a flowchart showing a detailed breakdown of the repeated portion of FIG. 4(B).

第5図は本発明の第4の実施例図である。本実施例は本
発明を利用したニューロコンピュータの構成図である。
FIG. 5 is a diagram showing a fourth embodiment of the present invention. This embodiment is a configuration diagram of a neurocomputer using the present invention.

同図において第4図に示したものと同一のものは同一の
記号で示してある。同図において1aはデータ処理ユニ
ットlの処理装置であり、例えばデジタルシグナルプロ
セッサで構成される。2aはトレイ2のデータ保持回路
であり、例えばラッチ回路で構成される。2bはトレイ
2のデータ転送回路であり、例えばバスドライバで構成
される。2Cはトレイ2の制御手段であり、例えば論理
回路で構戒される。4はデータ処理ユニッl−1にデー
タを供給する手段の一部であると同時にデータ処理ユニ
ット1を制御する手段の一部でもある記憶装置である。
In this figure, the same parts as those shown in FIG. 4 are indicated by the same symbols. In the figure, 1a is a processing device of a data processing unit 1, which is composed of, for example, a digital signal processor. Reference numeral 2a denotes a data holding circuit for the tray 2, which is composed of, for example, a latch circuit. 2b is a data transfer circuit for the tray 2, which is composed of, for example, a bus driver. 2C is a control means for the tray 2, and is controlled by, for example, a logic circuit. A storage device 4 is part of the means for supplying data to the data processing unit l-1 and is also part of the means for controlling the data processing unit 1.

例えばRAMで構成される。5aはデータ処理ユニット
1とトレイ2の同期動作を行う手段であり、5aはクロ
ック発生回路、例えば水晶発振回路で構威される。5b
はクロンク分配回路であり、例えばバッファ回路で構威
される。これに加えて101はシグモイド関数と称され
る単調非減少連続関数及びその微分係数を計算するシグ
モイド関数ユニットであり、例えば多項式による近似式
により実現される。103は学習時の終了を判定する手
段であり、例えば通信手段により前記各処理ユニット1
と接続されたホストコンピュータと、各処理ユニット1
が計算した出力誤差を前記通信手段により前記ホストコ
ンピュータに通知する手段と、一般に複数個の前記出力
誤差値を基に学習の終了を判定し、ニューロコンピュー
タの停止を行う手段とから構威される。なお102はニ
ューロコンピュータの全体である。
For example, it is composed of RAM. 5a is a means for synchronizing the data processing unit 1 and the tray 2, and 5a is constituted by a clock generation circuit, for example, a crystal oscillation circuit. 5b
is a Cronk distribution circuit, and is configured with a buffer circuit, for example. In addition, 101 is a sigmoid function unit that calculates a monotonically non-decreasing continuous function called a sigmoid function and its differential coefficient, and is realized by, for example, an approximate expression using a polynomial. Reference numeral 103 denotes a means for determining the end of learning, and for example, communicates with each processing unit 1 by communication means.
and a host computer connected to each processing unit 1.
means for notifying the host computer of the output error calculated by the neurocomputer through the communication means, and means for determining the end of learning based on the plurality of output error values and stopping the neurocomputer. . Note that 102 is the entire neurocomputer.

第5図(B)は本発明のニューロコンピュータにおいて
処理の計算における基本素子であるニューロンモデルの
実施例図である。ニューロンモデルは入力X,,X2,
  ・・・+Lの各々にシナプス結合としての重み時W
,,W2,  ・・・,Wnをそれぞれ掛け、その総和
を求め、これを内部値Uとする。このUに非線形関数f
を施し、出力Yとする。ここで非線形関数fは図に示す
ようなS型のシグモイド関数が一般に使われる。
FIG. 5(B) is an example diagram of a neuron model which is a basic element in processing calculations in the neurocomputer of the present invention. The neuron model has inputs X,,X2,
...+L for each weight W as a synaptic connection
,, W2, . This U has a nonlinear function f
and output Y. Here, as the nonlinear function f, an S-type sigmoid function as shown in the figure is generally used.

第5図(C)は第5図(D)のニューロンモデルの複数
を用いて入力層、中間層、出力層の3N構造でニューロ
コンピュータを形或する階層型のニューラルネットワー
クの概念図である。第1層の入力層は入力信号II,I
2,  ・・・,■、。,を入力する。第2層の中間層
は各々のユニット、すなわち、各々のニューロンモデル
が第1層のすべてのニューロンモデルに接続され、その
結合技がシナプス結合であって、重み値Wi4が与えら
れている。第3Nの出力層は同様に中間層の各ニューロ
ンモデルの全てに各々のユニットが接続されている。そ
の出力は外部に出される。このニューラルネットにおい
ては学習時において入力層に与えられる入力パターンの
信号に対応する教師信号と出力層との出力信号との誤差
を求め、この差が非常に小さくなるように中間層と出力
層との間の重み及び第1iと第2Hの間の重みを定める
ようにする。このアルゴリズムがバックプロパゲーショ
ン法則、すなわち逆伝播学習則と呼ばれるものである。
FIG. 5(C) is a conceptual diagram of a hierarchical neural network that forms a neurocomputer with a 3N structure of an input layer, an intermediate layer, and an output layer using a plurality of the neuron models shown in FIG. 5(D). The input layer of the first layer is the input signal II, I
2, ...,■,. , input. In the intermediate layer of the second layer, each unit, that is, each neuron model, is connected to all the neuron models of the first layer, and the connection technique is synaptic connection, and a weight value Wi4 is given. Similarly, each unit of the 3N output layer is connected to all of the neuron models in the intermediate layer. The output is output to the outside. In this neural network, during learning, the error between the teacher signal corresponding to the input pattern signal given to the input layer and the output signal of the output layer is calculated, and the error between the intermediate layer and the output layer is determined so that this difference is very small. The weight between the first i and the second H is determined. This algorithm is called the backpropagation law, or backpropagation learning law.

逆伝播学習則によって定められた重み値を保存し、例え
ばパターン認識等の連想処理を行う場合には、第1層の
入力にて認識するべきパターンからややずれた不完全な
パターンを与えると、出力層からそのパターンに対応し
た出力信号が出力され、その信号は学習時に与えたその
パターンに対応する教師信号と非常に似たような信号が
出てくる。教師信号との差が非常に小さければ、その不
完全なパターンを認識したことになる。
When storing the weight values determined by the backpropagation learning rule and performing associative processing such as pattern recognition, if an incomplete pattern slightly deviated from the pattern to be recognized is given as input to the first layer, An output signal corresponding to the pattern is output from the output layer, and this signal is very similar to the teacher signal corresponding to the pattern given during learning. If the difference from the teacher signal is very small, this means that the incomplete pattern has been recognized.

第5図(A)のニューロコンピュータ102を用いてこ
のニューラルネットワークの動作を工学的に実現できる
。本実施例では第5図(C)に示すような3層のネット
ワーク構成を用いるが、以下の説明のようにこの層数は
本実施例の動作にはなんら本質的な影響を受けない。同
図においてN(1)は第1層のニューロン数である。ま
た通常、第1層、すなわち入力層の各ニューロンの出力
は入力と等しいものとするので、実質的な処理の必要は
ない。通常の動作、すなわちパターン認識を行う場合の
前向きの処理を第5図(D)に示す。
The operation of this neural network can be realized engineeringly using the neurocomputer 102 shown in FIG. 5(A). In this embodiment, a three-layer network configuration as shown in FIG. 5(C) is used, but as explained below, this number of layers has no essential influence on the operation of this embodiment. In the figure, N(1) is the number of neurons in the first layer. Further, since the output of each neuron in the first layer, that is, the input layer is usually equal to the input, there is no need for any substantial processing. FIG. 5(D) shows normal operation, that is, forward-looking processing when performing pattern recognition.

第5図(D)は第4の実施例の前向き処理フローチャー
トである。前向き処理では第5図(C)に示すネットワ
ークにおいて、各層間の結合技上の重み係数は定まって
いるものとする。第5図(C)のネットワークを第5図
(A)のニューロコンピュータで実現する場合、次の処
理が行われる。前向き動作の基本動作は第5図(B)の
ニューロンモデルにおいて、入力に重みを掛けその総和
をとったものをUとし、そのUに非線形関数を施す処理
となる。これを各層において行うことになる。そのため
、まず、ステンプ7oにおいて入力データ、すなわち■
1からIN(11までのデータをシフトレジスタ上にセ
ットする。そして層の数をLで表すと、以下のすべての
処理を層分繰り返す。例えばLが3であった場合には、
3回繰り返す。繰り返される層は1層分の前向き処理で
ある。
FIG. 5(D) is a forward processing flowchart of the fourth embodiment. In the forward processing, it is assumed that in the network shown in FIG. 5(C), the weighting coefficients for the connection technique between each layer are fixed. When the network of FIG. 5(C) is realized by the neurocomputer of FIG. 5(A), the following processing is performed. The basic operation of the forward movement is a process of multiplying the inputs with weights and taking the summation as U, and applying a nonlinear function to that U in the neuron model shown in FIG. 5(B). This will be done for each layer. Therefore, first, in step 7o, the input data, that is, ■
Set the data from 1 to IN (11) on the shift register. Then, if the number of layers is represented by L, all the following processes are repeated for each layer. For example, if L is 3,
Repeat 3 times. The repeated layer is one layer of forward processing.

そして、処理が終了する。その1層分の前向き処理が下
側に示されている。今、中間層に注目すると、lは2で
ある。ステップ72において、シフトレジスタの長さを
N(f−1)にする。すなわち、f=2であるからN(
1)、すなわち入力層の数にする。ステップ73は中間
層におけるニューロンモデルの処理である。インデック
スのjは1から入力層のユニット数N(1)まで変化さ
せる。Wz(f)は入力層と中間層の間の結合における
重み係数である。すなわちI2−2である。Yj(f−
1)は入力層のj番目のユニットからの出力である。i
は中間層のi番目のユニットを意味する。i番目のユニ
ットの状態U+(2)は入力層の出力Yj、すなわちj
番目のYに重みW,をかけてその総和より計算される。
Then, the process ends. The forward processing for one layer is shown at the bottom. Now, if we focus on the middle layer, l is 2. In step 72, the length of the shift register is set to N(f-1). In other words, since f=2, N(
1), that is, the number of input layers. Step 73 is processing of the neuron model in the intermediate layer. The index j is varied from 1 to the number of units in the input layer N(1). Wz(f) is a weighting factor in the connection between the input layer and the hidden layer. That is, I2-2. Yj(f-
1) is the output from the j-th unit of the input layer. i
means the i-th unit of the intermediate layer. The state U+(2) of the i-th unit is the output Yj of the input layer, i.e. j
It is calculated from the sum of the weights W multiplied by the weight W.

ステップ74に移って、“その中間層のi番目の状態U
+(2)は非線形関数、すなわちシグモイド関数に入力
され、その出力がYl(2)となる。すなわちステップ
73の内積計算は第5図(A)のユニット内で行うが、
このシグモイド関数の計算は、101によって行われる
。ステップ75で例えば、中間層のi番目のユニットの
出力Yi(2)はトレイのi番目に出力される。そして
処理が終わる。以上の前向き処理を入力層、中間層、出
力層に対して行うことになる。このようにして各層の前
向き処理が終了する。すなわちニューロン単体のシξユ
レーションに必要な処理は第5図(B)の式で示される
演算で、その内容は重みと入力ベクトルとの内積演算及
びその演算結果に対するシグモイド関数値の計算であり
、その関数値の計算はシグモイド関数ユニット101に
より実現される。従って、ネットワーク中のある1層の
処理は第5図(C)に示すように、そのニューロン単体
の演算をその層内の全ニューロン分行うことである。従
って内積演算は各ニューロンi番目とするの結合係数ベ
クトルを並べた行列w B)= (WIJ (j2))
と、その層への入力を並べたヘクトルx (j2) 一
CXi(l)〕の積のヘクトル U  (1!)=  (Ui (1))となり、これは
本発明の第3の実施例で説明した方法で実行可能となる
。またシグモイド関数演算は各シグモイド関数ユニット
lO1が積ベクトルの各要素、Ui(f)を入力し、対
応する関数値yt (p) =r (U1 (/!))
を出力することによってなされる。継続する層すなわち
、第(ffi+1)層が存在する場合は、その各関数値
出力y.(x)を各トレイに書き込み、第(l+1)層
の処理においてはこれを入力として以上の過程を繰り返
す。
Proceeding to step 74, “the i-th state U of the intermediate layer
+(2) is input to a nonlinear function, that is, a sigmoid function, and its output becomes Yl(2). That is, the inner product calculation in step 73 is performed within the unit of FIG. 5(A),
Calculation of this sigmoid function is performed by 101. In step 75, for example, the output Yi(2) of the i-th unit of the intermediate layer is output to the i-th tray. Then the process ends. The above forward processing is performed on the input layer, intermediate layer, and output layer. In this way, the forward processing of each layer is completed. In other words, the processing required for the simulation of a single neuron is the calculation shown in the equation shown in FIG. , the calculation of the function value is realized by the sigmoid function unit 101. Therefore, as shown in FIG. 5(C), the processing of one layer in the network is to perform calculations for a single neuron for all neurons in that layer. Therefore, the inner product operation is a matrix w B) = (WIJ (j2)) in which the coupling coefficient vectors of each i-th neuron are arranged.
and the hector x (j2) - CXi(l)] in which the inputs to that layer are arranged, the hector U (1!) = (Ui (1)), which is the third embodiment of the present invention. This can be done using the method described. In addition, in the sigmoid function operation, each sigmoid function unit lO1 inputs each element of the product vector, Ui (f), and the corresponding function value yt (p) = r (U1 (/!))
This is done by outputting . If a continuing layer exists, that is, the (ffi+1)th layer, each function value output y. (x) is written in each tray, and in the processing of the (l+1)th layer, this is input and the above process is repeated.

次に第5図(A)のニューロコンピュータヲ用いて学習
動作、すなわちハノクプロバゲーションアルゴリズムを
実行する場合について説明する。
Next, a case will be described in which a learning operation, that is, a Hanok provagation algorithm is executed using the neurocomputer shown in FIG. 5(A).

第5図(E)は第4の実施例の学習処理フローチャート
である。ニューロコンピュータにおける学習とはネ7}
ワークが所望の入出力関係を満たすようになるまで各ニ
ューロンの重みを修正することである。学習方法は所望
の入力信号ベクトルと教師信号ベクトルとの対を複数個
、すなわち教師信号の集合分だけ用意し、その中から1
対を選び、その入力信号I,を学習対象ネットワークに
入力し、入力に対するネットワークの出力と正しい出力
信号、すなわちその入力信号に対応した教師信号OF 
とを比較する。この差を誤差と称するが、その誤差、及
びこの時の入出力信号の値を基に、各ニューロンの重み
を修正することになる。
FIG. 5(E) is a learning process flowchart of the fourth embodiment. What is learning in neurocomputers?7
The goal is to modify the weights of each neuron until the workpiece satisfies the desired input-output relationship. The learning method is to prepare a plurality of pairs of a desired input signal vector and a teacher signal vector, that is, for a set of teacher signals, and select one from them.
Select a pair, input the input signal I, to the network to be learned, and combine the output of the network with respect to the input and the correct output signal, that is, the teacher signal OF corresponding to the input signal.
Compare with. This difference is called an error, and the weight of each neuron is corrected based on the error and the values of the input and output signals at this time.

この過程を教師信号の集合中の全要素にわたり学習が収
束するまで繰り返すものである。すなわち、入力パター
ンの数の分だけ、すべて重み値として分布的に記憶する
ことになる。この後ろ向き処理と呼ばれる重みの修正過
程において出力層で得られた誤差を途中で変形しながら
入力層に向け通常の信号の流れる向きとは逆方向に伝播
させる。これがバックプロパゲーションのアルゴリズム
である。
This process is repeated until learning converges over all elements in the set of teacher signals. That is, the number of input patterns are all stored as weight values in a distributed manner. In this weight correction process called backward processing, the error obtained in the output layer is propagated toward the input layer in the opposite direction to the normal signal flow direction, while being modified along the way. This is the backpropagation algorithm.

まず前記誤差Dを以下のように再帰的に定義する。Di
(ff)は第fJiJのi番目のニューロンから逆向き
に伝播される誤差、Lはネットワークの層数である。
First, the error D is defined recursively as follows. Di
(ff) is the error propagated backward from the i-th neuron of fJiJ, and L is the number of layers of the network.

Di (L) 一V  (Ui (L))(Yi (L
)○pi)       (最終層)(1)Di (f
f−1)一f’  (Ui  (1−1))Σt=+.
N+L,Wj i  (j2) D j (j2)(f
fi=2,  ・・・,L)   (2)(i=1, 
 ・・・, N (12) )ここでr’  (u)は
シグモイド関数r (x)のXに対する微係数r’  
(x)のX=Uの時の値であり、例えば f (X) =tanhX            (
3)ならば、 f ’  (X) =d (LanhX) / d X
= 1−tanh2X= 1 − f z(4) であるから、 f’  (Ui)=1−f2 (Ui)=1−Yiz(
5) である。
Di (L) 1V (Ui (L)) (Yi (L)
)○pi) (Final layer) (1) Di (f
f-1) -f' (Ui (1-1))Σt=+.
N+L, Wj i (j2) D j (j2) (f
fi=2,...,L) (2)(i=1,
..., N (12)) where r' (u) is the differential coefficient r' of the sigmoid function r (x) with respect to X.
It is the value of (x) when X=U, for example, f (X) = tanhX (
3), then f' (X) = d (LanhX) / dX
= 1-tanh2X= 1-f z (4), so f' (Ui) = 1-f2 (Ui) = 1-Yiz(
5).

このDiとYiを基に、以下にように重みを更新する。Based on these Di and Yi, the weights are updated as follows.

基本的には次の式を用いる。ここでηは重みを更新する
刻み巾であり、小さければ学習安定に収束する収束が遅
くなり、大きすぎると収束ひなくなるという性質を持っ
たパラメタである。
Basically, the following formula is used. Here, η is the increment width for updating the weights, and is a parameter that has the property that if it is small, the convergence to stable learning will be delayed, and if it is too large, the convergence will not occur.

W i j  (f) (t”’  =W i j (
jl!) (L)+ΔWi j  (j2) ′t′(
6)ΔWij(f)(” =ηDf  (j!) Yj
(j2−1)      (j2=2.  ・・・,L
)(7)しかし、次に式も良く用いられている。これは
上式のΔWi j (j2) Ct)を1次にデジタル
ローバスフィルタに通したことになっており、αはその
時定数を決めるパラメタである。
W i j (f) (t”' = W i j (
jl! ) (L)+ΔWi j (j2) 't'(
6) ΔWij (f) (” = ηDf (j!) Yj
(j2-1) (j2=2....,L
) (7) However, the following formula is also often used. This means that ΔWi j (j2) Ct) in the above equation is passed through a primary digital low-pass filter, and α is a parameter that determines its time constant.

ΔWi j (A) LL”’ =ηDi(f)Yj(
f−1)+αΔW i j (f) (t)(8)この
後ろ向き処理の過程において必要となる演算はベクトル
間の演算、或いは行列とベクトルとの演算であり、特に
その中心となるのは各層のニューロンの重みを要素とす
る重み行列Wの転置行列WTと前記誤差ベクトルDi 
(1)との乗算である。この誤差ベクトルは1層内に複
数個のニューロンがある一般の場合、誤差はヘクトルと
なる。
ΔWi j (A) LL"' = ηDi(f)Yj(
f-1) + αΔW i j (f) (t) (8) The operations required in this backward processing process are operations between vectors, or operations between matrices and vectors, and the main focus is on each layer. The transposed matrix WT of the weight matrix W whose elements are the weights of the neurons and the error vector Di
(1). In the general case where there are a plurality of neurons in one layer, this error vector becomes a hector.

第5図(E)の左のフローチャートを説明する。The flowchart on the left side of FIG. 5(E) will be explained.

1層分の前向きの処理と後向きの処理が行われる。まず
、入力データIPをシフトレジスタ上にセットし、1層
分の前向き処理をシステムで行う。
Forward processing and backward processing for one layer are performed. First, input data IP is set on a shift register, and the system performs forward processing for one layer.

これは各層で行われるため、この前向き処理を層の数分
だけ操り返す。すると出力データOpが出力されるので
、これをシフトレジスタ上にセットする。そして、ステ
ップ79から以下を出力層のユみット分だけ並列に実行
する。すなわち誤差D,(L)−Yi(L)  Or(
i)を計算し、この誤差をトレイのi番目にセットする
。そして出力層から入力層に向かって各層毎に後向き処
理を行う。
This is done for each layer, so this forward processing is repeated by the number of layers. Then, output data Op is output, so this is set on the shift register. Then, from step 79, the following steps are executed in parallel for as many units as the output layer. That is, the error D, (L) - Yi (L) Or (
i) and set this error to the i-th tray. Then, backward processing is performed for each layer from the output layer to the input layer.

この後向き処理は第5図(E)の右上側に示されている
。第L番目の層に関して、この層の数はN(j2)であ
るからシフトレジスタ長をN(I!.)にする。そして
以下の動作をこの前の層のユニット数だけ並列に実行す
る。すなわち、上記(2)式を、ステップ83において
実行する。ここで重要なのは重みはWJI(l)となっ
ており、これは重み行列の転置行列WTの要素になって
いる。そしてステップ84において、上記(6), (
7)あるいは(8)式を計算し、重みの更新を行う。ス
テップ85で、求まった誤差D.(i  Nをトレイの
i番目に出力する。これは次の誤差を計算するため、ス
テップ84の動作に必要となる。第5図(A)の右下は
第5図(E)の左のフローチャート、すなわち前向き処
理と後向き処理の連続処理を学習が習得するまで繰り返
すことを意味するフローチャートである。また、このよ
うな処理において重みの更新と学習を安定にするために
重みの修正量の平滑化等の処理があるが、これらはいず
れも行列のスカラ倍及び行列同士の加減算からなり、や
はり、本ニューロコンピュータにおいて行える。またシ
グモイド関数ユニット101はハードウエアで実現する
ものとしているが、ソフトウェアで実現してもよい。ま
た、学習の終了の反転千段103はホストコンピュータ
上のソフトウエアで実現してもよい。
This backward processing is shown on the upper right side of FIG. 5(E). Regarding the Lth layer, since the number of layers is N(j2), the shift register length is set to N(I!.). Then, the following operations are executed in parallel for the number of units in the previous layer. That is, the above equation (2) is executed in step 83. What is important here is the weight WJI(l), which is an element of the transposed matrix WT of the weight matrix. Then, in step 84, the above (6), (
7) or (8) is calculated and the weights are updated. In step 85, the error D. (i N is output to the i-th tray. This is necessary for the operation of step 84 in order to calculate the next error. The lower right of FIG. 5(A) is the same as the left of FIG. 5(E). This is a flowchart that means that sequential processing of forward processing and backward processing is repeated until learning is mastered.In addition, in such processing, in order to update the weights and stabilize learning, the amount of weight correction is smoothed. These processes include scalar multiplication of matrices and addition and subtraction between matrices, which can also be performed on this neurocomputer.Furthermore, although the sigmoid function unit 101 is assumed to be realized by hardware, it can be realized by software. Furthermore, the inversion step 103 at the end of learning may be realized by software on the host computer.

以上のニューロコンピュータをさらに第5図(F)を用
いて説明する。第5図(F)はエラーパックプロパゲー
ションの学習を行う時の処理フロー図である。ここでは
、ベクトル表示を用いている。同図においてx (f)
は第1層のニューロンベクトル、Wは同じく結合係数、
すなわち重み行列である。rはシグモイド関数、e (
f)は第1層の出力側から逆向きに伝播してきた誤差ベ
クトル、ΔWは重みの修正量である。入力信号が与えら
れると、まず、3層である場合には、入力層はないもの
とすれば、隠れ層の前向き処理を行う。
The above neurocomputer will be further explained using FIG. 5(F). FIG. 5(F) is a processing flow diagram when learning error pack propagation. Vector representation is used here. In the same figure, x (f)
is the neuron vector of the first layer, W is also the coupling coefficient,
That is, it is a weight matrix. r is a sigmoid function, e (
f) is an error vector propagated in the opposite direction from the output side of the first layer, and ΔW is a weight correction amount. When an input signal is given, first, in the case of three layers, forward processing of the hidden layer is performed, assuming that there is no input layer.

それがu=Wx(f)である。このUに非線形関数を施
せば、次の層、すなわち(ffi+1)層の入力となる
。これは出力層の入力であるから、その前向き処理を行
う。そして教師信号を入力し、後向き処理になる。出力
層においては教師信号と出力信号の誤差eをfの微分を
掛けて後向き処理にする。また中間層等の間の誤差は逆
伝播してくる誤差信号に微分をかけた変数に重み行列の
転置行列W7をかけて求められる。誤差ベクトルの各要
素にシグモイドの微分をかけた値に前のW7の要素を掛
けてこれよりΔWを求め、Wを更新すればよい。このよ
うにして、出力層の後向き処理、及び隠れ層の後向き処
理が行われる。前向き処理で行う演算は、重み行列Wと
入力ベクトルXとの積、この結果ベクトルの各要素のシ
グモイド関数の値の計算である。この計算は各ニューロ
ンで並列に計算できる。また後向き処理でも仕事は大き
く分けて2あり、1つ目は教師信号と出力信号との誤差
を順次変形しながら、後から前へ逆向きに伝播すること
、また2つ目はその誤差を基に重みを修正することであ
る。この逆向きの計算では重み行列Wの転置行列W7に
よる乗算が必要になる。転置行列WTとベクトルの積は
前の実施例で述べている。すなわちパックプロパゲーシ
ョンの学習を実現する再の重要な点は重み行列の転置行
列WTとベクトル乗算の効率な実現方法である。
That is u=Wx(f). If a nonlinear function is applied to this U, it becomes the input for the next layer, that is, the (ffi+1) layer. Since this is the input of the output layer, forward processing is performed on it. A teacher signal is then input, and backward processing begins. In the output layer, the error e between the teacher signal and the output signal is multiplied by the differential of f to perform backward processing. Furthermore, the error between the intermediate layers and the like is obtained by multiplying the variable obtained by differentiating the back-propagated error signal by the transposed matrix W7 of the weight matrix. W can be updated by multiplying the value obtained by multiplying each element of the error vector by the sigmoid differential by the previous element of W7 to obtain ΔW. In this way, backward processing of the output layer and backward processing of the hidden layer are performed. The calculation performed in forward processing is the product of the weight matrix W and the input vector X, and the calculation of the value of the sigmoid function of each element of the resulting vector. This calculation can be performed in parallel in each neuron. In addition, there are two main tasks in backward processing: the first is to sequentially transform the error between the teacher signal and the output signal and propagate it backwards from the back to the front, and the second is to propagate the error based on the error. The solution is to modify the weights. This inverse calculation requires multiplication of the weight matrix W by the transposed matrix W7. The product of the transposed matrix WT and the vector is described in the previous embodiment. That is, an important point in realizing pack propagation learning is an efficient method of realizing vector multiplication with the transpose matrix WT of the weight matrix.

さらに第5図(G)と(H)を用いて前向き積和計算、
及び後向き積和計算の実施例を説明する。
Further, using Figure 5 (G) and (H), calculate the forward sum of products,
An example of backward product-sum calculation will be described.

前向き積和演算は行列×ベクトルの計算で、特に行列は
重み行列Wである。本発明で、行列ベクトル積u=Wx
を計算する場合、例えば、次の弐? ・ ・(9) に対して、重み行列の行とベクトルXとの積が同時に行
われる。この処理方弐を第7図(8)を用いて説明する
。重み行列Wは長方行列である。例えば、3×4の行列
である。ヘクトルXの各要素はトレイ上に入力される。
The forward product-sum operation is a matrix×vector calculation, and in particular, the matrix is a weight matrix W. In the present invention, the matrix-vector product u=Wx
For example, if you want to calculate the following 2?・ ・For (9), the rows of the weight matrix and the vector X are simultaneously multiplied. This second processing method will be explained using FIG. 7(8). The weight matrix W is a rectangular matrix. For example, it is a 3×4 matrix. Each element of hector X is entered on the tray.

T1の時刻において、X,とW.、X2とW2■、X3
とW。が各々のユニットで計算される。T2に移るとベ
クトルXの各要素は上に巡回シフトする。T2において
W+2とX2との積がU,に足される。したがってU1
はこの時刻にはX + X W + + + X 2 
X W +■となる。また、第2のユニットではW23
とX3が掛けられ、第3番目のユニントではW34×X
4が掛けられる。T3において、WI3とx3が掛けら
れU,に足し込まれる。W24とX4が掛けられ、U2
に加えられる.W31とXIが掛けられU3に足し込ま
れる。この時x2は演算の対象からはずされている。T
4におイテ、W14とX4、W2,とXI、W32とX
2がそれぞれ同時に掛けられ(−L , U2 、TJ
3にそれぞれ足し込まれる。この場合、x3は演算の対
象外となっている。この演算の対象外を考慮すること乙
こよって長方行列とベクトルとの積が実行される。
At time T1, X, and W. , X2 and W2 ■, X3
and W. is calculated for each unit. Moving to T2, each element of vector X is cyclically shifted upward. At T2, the product of W+2 and X2 is added to U. Therefore U1
is at this time X + X W + + + X 2
It becomes X W + ■. Also, in the second unit W23
is multiplied by X3, and in the third unit W34×X
Multiplyed by 4. At T3, WI3 and x3 are multiplied and added to U. W24 and X4 are multiplied and U2
is added to. W31 and XI are multiplied and added to U3. At this time, x2 is excluded from the calculation target. T
Ite to 4, W14 and X4, W2, and XI, W32 and X
2 are multiplied simultaneously (-L, U2, TJ
Each is added to 3. In this case, x3 is not subject to calculation. By taking into account the objects that are not subject to this operation, the product of a rectangular matrix and a vector is executed.

Wの部分ベクトルWi0はPE−tのローカルメモリ上
にWiiが先頭になるようにスキューされて格納されて
いる。Xiはトレイにのってリング上を反時計回りに一
回転する。UiはPE−t内部のレジスタ上に累積され
る。
The partial vector Wi0 of W is stored in the local memory of PE-t in a skewed manner so that Wii is at the beginning. Xi gets on the tray and rotates counterclockwise around the ring. Ui is accumulated on a register inside PE-t.

左端の状態でUi=Oの状態からスタートする。It starts from the state of Ui=O in the leftmost state.

PE−tは自分の目の前にあるXjとwijと掛け合わ
せ、その結果をUiに加算する。同時にXjは隣のトレ
イに隣接される(リング上を反時計回りに循環する)。
PE-t multiplies Xj and wij in front of it, and adds the result to Ui. At the same time, Xj is adjacent to the next tray (circulating counterclockwise on the ring).

これを4回繰り返すと全てのUiが同時に求まる。By repeating this four times, all Ui's can be found at the same time.

Wiiがスキューされていること、Xiが全てトレイ中
にある状態からスタートすること、Uiが全て同時に求
まる。
The Wii is skewed, the Xi starts with all in the tray, and the Ui are all found at the same time.

第5図(H)は後向き積和計算の説明である。FIG. 5(H) is an explanation of backward product-sum calculation.

これは転置行列と行ベクトル積、e=W”vを計算する
時のタイ稟ング図である。この場合、ベクトルVは前の
層の誤差ベクトルに非線形関数の微分を掛けた要素から
なるベクトルである。eは求めらようとする次の層での
逆伝播用の誤差ベクトルである。本発明で重要なことは
、転置行列W?であっても、前向き積和計算において利
用されるメモリ上のWと同じ配置にしたままで演算でき
ることである。
This is a tie diagram when calculating the transposed matrix and the row vector product, e=W''v. In this case, the vector V is a vector consisting of the elements obtained by multiplying the error vector of the previous layer by the differential of the nonlinear function. e is the error vector for backpropagation in the next layer to be determined.What is important in the present invention is that even if the transposed matrix W? It is possible to perform calculations with the same arrangement as W above.

すなわち本発明では求めるべきeのベクトルの巡回シフ
トによってなされる。演算するべき転置行列W7とベク
トルVとの式は00式に従う。
That is, in the present invention, this is done by cyclically shifting the vector of e to be determined. The formulas for the transposed matrix W7 and vector V to be calculated follow formula 00.

上の式において示されるように、行列Wは転置?れしか
も、長方行列である。e1はW11Xvl十w2,xV
2+w,,xV3である。この演算を行うために、第5
図(H)において、時間区域T1においては第1のユニ
ッl− (DSP)において、WIIとVlの積が演算
されている。これがOであるe1に差し込まれる。そし
て、巡回シフトするとT2に移るが、e1はT2時刻に
おいては演算の対象になっていない。そしてT3になる
と、3番目のユニットにおいて演算対象となっている。
As shown in the above formula, is the matrix W transposed? Moreover, it is a rectangular matrix. e1 is W11Xvl ten w2, xV
2+w,,xV3. To perform this operation, the fifth
In the diagram (H), in the time period T1, the product of WII and Vl is calculated in the first unit l- (DSP). This is inserted into e1 which is O. Then, when the cyclic shift is performed, the process moves to T2, but e1 is not subject to calculation at time T2. Then, at T3, the third unit becomes the calculation target.

すなわちW3,にv3を掛けた値が前の値に足し込まれ
るため、W,,Xv.に足し込まれる。そのため時間区
域T3においては、e,の結果はW.×V 1 +W3
1 X V 3となる。そしてT4に移ると、e.は巡
回シフトとして、第2番目のユニットで演算対象となる
。ここで、e,にはW2,Xv2が加えられるため、0
■式の行列の第1行目とベクトルVとの内積演算が実行
され、その演算結果がe,に格納されることになる。
That is, since the value obtained by multiplying W3, by v3 is added to the previous value, W,,Xv. It is added to. Therefore, in time area T3, the result of e, is W. ×V 1 +W3
1 X V 3. Then, moving to T4, e. is a cyclic shift and is the object of calculation in the second unit. Here, since W2 and Xv2 are added to e, 0
The inner product operation of the first row of the matrix of equation (2) and the vector V is executed, and the result of the operation is stored in e.

同様に第2行目とベクトルとの積はe2を追えばよい。Similarly, the product of the second row and the vector can be obtained by following e2.

T,時刻にはW2■XV2 、T2にはWl2?v, 
、T3では、e2が遊びになり、T4でW3■Xv3の
積が求まれ、各々の積の和として計算される。WTの第
3行目とベクトルVとの積はe3を追えばよい。T,に
おいてはWI3X v:l 、TzにおいてはそれにW
23×v2が足し込まれ、T3において、更にW,3x
y,が足し込まれる。T4はe4は遊びとなる。W7の
第4行目とベクトルVとの積はe4を追えばよい。T1
時刻ではe4は遊びである。T2ではW34×v3 、
T3ではW24XV2が足し込まれ、T4において更に
W,.Xv,が足し込まれて、計算ができる。このよう
に本発明では、Wの部分ベクトルW t ’″は前と同
様PE−tのローカル目上にWiiが先頭になるように
スキューされて格納されている。前と入れ替わるのはe
iとViである。つまり、eiはトレイ上を反時計回り
に循環しながら累積され、ViはPE−1内部に常駐す
る。
T, time is W2■XV2, T2 is Wl2? v,
, T3, e2 becomes idle, and at T4, the product of W3×Xv3 is determined and calculated as the sum of each product. The product of the third row of WT and the vector V can be obtained by following e3. WI3X v:l at T, and W to it at Tz
23×v2 is added, and at T3, further W,3x
y, is added. For T4, e4 is a play. The product of the fourth row of W7 and the vector V can be obtained by following e4. T1
At time, e4 is idle. In T2, W34×v3,
At T3, W24XV2 is added, and at T4, W, . Xv, is added and the calculation can be done. In this way, in the present invention, the partial vector W t ''' of W is stored in the local position of PE-t in a skewed manner so that Wii is at the beginning.
They are i and Vi. That is, ei is accumulated while circulating counterclockwise on the tray, and Vi resides inside PE-1.

左端の状態でe j=oからスタートする。PE−iは
ViとWijとを掛け合わせ、その結果を自分の目の前
にあるejに加え込む。同時にこの更新されたejは隣
のトレイに転送される(リング上を反時計回りに循環す
る)。これを4回繰り返すと全てのejが同時に求まる
Start from e j=o in the leftmost state. PE-i multiplies Vi and Wij and adds the result to ej in front of him. At the same time, this updated ej is transferred to the adjacent tray (circulating counterclockwise on the ring). By repeating this four times, all ej can be found at the same time.

このように本発明のニューロコンピュータは層が何層で
あっても実現でき、学習アルゴリズムの自由度が高いと
いう柔軟性を持つばかりでなく、DSPの速度そのまま
を利用でき、しかもそのDSPの演算においてオーバヘ
ッドがなく、高速性があり、しかもDSPによるSIM
Dが実行できる。
In this way, the neurocomputer of the present invention can be realized with any number of layers, and not only has the flexibility of having a high degree of freedom in the learning algorithm, but also can utilize the speed of the DSP as it is, and moreover, in the calculation of the DSP. No overhead, high speed, and DSP-based SIM
D can be executed.

第6図は本発明の第5の実施例説明図であり、アナログ
データによる行列の積を求めるものである。図中、第2
図で示したものと同一のものは同一の記号で示してあり
、1dはデータ処理ユニット1の処理装置であり、例え
ばアナログ乗算器1eと積分器ifで構威され、2dは
トレイ2のデータ保持回路であり、例えばサンプル/ホ
ールド回路2fで構成され、2eはトレイ2のデータ転
送回路であり、例えばアナログスイッチ2gとハッファ
アンプ2hで構成され、6はトレイ2にデ−タを設定す
る手段であり、例えばアナログスイッチ6dで構威され
る。
FIG. 6 is an explanatory diagram of a fifth embodiment of the present invention, which calculates the product of matrices using analog data. In the figure, the second
Components that are the same as those shown in the figure are indicated by the same symbols, and 1d is a processing device of the data processing unit 1, which is composed of, for example, an analog multiplier 1e and an integrator if, and 2d is the data processing unit for tray 2. A holding circuit, for example, is composed of a sample/hold circuit 2f, 2e is a data transfer circuit for the tray 2, which is composed of, for example, an analog switch 2g and a huffer amplifier 2h, and 6 is a means for setting data in the tray 2. For example, an analog switch 6d may be used.

本実施例の動作は本発明の原理図(第1図)で説明した
動作と同しである。
The operation of this embodiment is the same as that described in the principle diagram of the present invention (FIG. 1).

第7図は本発明の第6の実施例説明図であり、帯行列と
ベクトルとの乗算を示している。図中、第2図で示した
ものと同一のものは同一の記号で示してある。
FIG. 7 is an explanatory diagram of a sixth embodiment of the present invention, showing the multiplication of a band matrix and a vector. In the figure, the same parts as those shown in FIG. 2 are indicated by the same symbols.

本実施例の動作を第7図(B)を参照しつつ説明する。The operation of this embodiment will be explained with reference to FIG. 7(B).

本発明では、mXn (n≧m≧1)で巾kの帯行列A
と要素数nのベクトルXとの乗算結果(要素数mのベク
トルy)を求める場合においで、第7図(A)の如く、
各々2つの入力を持ち乗算機能と概乗算結果の累積機能
を有するm個のデータ処理ユニット1と、n個のトレイ
2と、前記各データ処理ユニット1にせとぞくされた入
力データ供給手段とから或る構戒に於いて、第7図(B
)に示す手順で、第7図(C)及び第7図(D)のよう
な時系列で処理をするようにしている。従って、巾kの
帯行列とベクトルとの乗算がkに比例する処理時間で実
行できる。
In the present invention, a band matrix A of width k with mXn (n≧m≧1)
When calculating the multiplication result (vector y of m elements) by vector X with n elements, as shown in FIG. 7(A),
m data processing units 1 each having two inputs and having a multiplication function and an approximate multiplication result accumulation function, n trays 2, and input data supply means for each of the data processing units 1; In a certain precept, Figure 7 (B
), the processing is performed in chronological order as shown in FIGS. 7(C) and 7(D). Therefore, multiplication of a band matrix of width k by a vector can be performed in a processing time proportional to k.

本実施例に於いて重要な事は、ベクトルXを1回転させ
ない事、及びベクトルXをシフトレジスタ3上にセット
する際に、第1の実施例等と異なり、頂度帯が始まる位
置にずらしておくことである。すなわち、帯の開始位置
から処理を開始する場合、ある方向にずらしながら積和
演算を行えばkに比例する時間で処理が終了する。しか
し、図示しないが何らかの事情で帯の途中に配置した状
態から処理を開始する場合は、始めにベクトルXを一端
までずらせばよいことは明らかであり、その場合、シフ
トレジスタ3が双方向にシフト可能であることが意味を
持つのである。
What is important in this embodiment is that the vector X is not rotated once, and that when setting the vector It is a good idea to keep it. That is, when starting the process from the start position of the band, if the product-sum operation is performed while shifting in a certain direction, the process will be completed in a time proportional to k. However, if for some reason (not shown) you start processing from a state where the vector is placed in the middle of the band, it is obvious that the vector It is meaningful that it is possible.

即ち、例えば帯の中央から処理を開始する場合は、初め
に右にk/2(小数点以下切り捨て)だけずらし、以後
逆方向(この場合左)にずらしながら積和演算を行えば
、合計3/2kに比例する時間で処理が終了する。
That is, for example, when starting processing from the center of the band, first shift it to the right by k/2 (round down to the decimal point), then perform the product-sum operation while shifting it in the opposite direction (in this case, to the left), resulting in a total of 3/2. The process ends in a time proportional to 2k.

もし、シフトレジスタ3が双方向にシフト可能でなけれ
ば、ベクトルXを1回転させねばならないため、帯行列
の巾kではなくその大きさnに比例する時間が必要にな
る。大規模な帯行列の於いては、この差は非常に大きく
、帯行列とヘクトルとの乗算が帯行列の巾kに比例する
処理時間で実行可能となることは本発明の方式の利点で
ある。
If the shift register 3 is not capable of shifting in both directions, the vector X must be rotated once, which requires a time proportional to the size n of the banded matrix rather than the width k. For large-scale banded matrices, this difference is very large, and the advantage of the method of the present invention is that the multiplication of a banded matrix by a hector can be performed in a processing time proportional to the width k of the banded matrix. .

第8図はトレイの構造を具体的に示す。FIG. 8 specifically shows the structure of the tray.

トレイは基本的には単なる1語のラッチであるが、DS
Pからのアクセスと、隣のトレイへの転送を1サイクル
で実行できる(ポストシフト)。
Tray is basically just a one word latch, but DS
Access from P and transfer to the adjacent tray can be executed in one cycle (post shift).

機能の切り替えは、アドレス線の下位ビットにより、デ
ータのアクセスと同時に行い、速度を向上させている。
Function switching is performed simultaneously with data access using the lower bits of the address line, improving speed.

一つのトレイはゲートアレイで約1 2 0 0Bas
icセルの規模であり、1チップに2〜4個入れること
も可能である。
One tray is about 1200Bas with gate array
It is on the scale of an IC cell, and it is possible to put 2 to 4 on one chip.

また、トレイ中にワークレジスタを数ワード内蔵するこ
とも可能である。
It is also possible to incorporate several words of work registers in the tray.

第9図は本発明の実施例を用いて、実際に構威されたニ
ューロコンピュータのブロック図である。
FIG. 9 is a block diagram of a neurocomputer actually constructed using an embodiment of the present invention.

Sandyの基本構成はDSPの一次元トーラス(リン
グ)結合によるSTMD型マルチプロセッサである。
The basic configuration of Sandy is an STMD type multiprocessor using a one-dimensional torus (ring) combination of DSPs.

特徴的なのは、結合トボロジーや動作は1次元シストリ
ックアレイと類似しているにも関わらず、SIMDとし
て動作する事である。
A distinctive feature is that it operates as a SIMD, even though its coupling topology and operation are similar to a one-dimensional systolic array.

各DSPと双方向バスで接続されている゜゜トレイ′゛
は、転送機能を有するラッチであり、相互にリング状に
接続され、全体でサイクリックシフトレジスタを構威し
ている。以後このシフトレジスタをリングと呼ぶ。
The ゜゜tray'゛ connected to each DSP by a bidirectional bus is a latch having a transfer function, and is connected to each other in a ring shape, forming a cyclic shift register as a whole. Hereinafter, this shift register will be referred to as a ring.

各DSPは2K語の内部メモリと64語の外付けRAM
を持ち、内部メモリは1サイクルで、外部メモリは1〜
2サイクルでアクセスできる。
Each DSP has 2K words of internal memory and 64 words of external RAM
, the internal memory is 1 cycle, and the external memory is 1 to 1 cycle.
It can be accessed in 2 cycles.

外付けRAMは、プログラムやデータの初期ロード用に
、共通ハスでホストコンピュータのVMEWハスに接続
される。外部入力もハソファメモリを介してホストコン
ピュータに接続されている。
The external RAM is connected to the host computer's VMEW bus via a common bus for initial loading of programs and data. External inputs are also connected to the host computer via HaSofa memory.

第10図は本発明の実施例における学習時の時間空間チ
ャートであり、縦方向はプロセッサの数を示し、横方向
は時間を示す。■は入力層のプロセッサの数、Hは隠れ
層のプロセッサの数、■はプロセッサの積和演算の時間
に対応する。
FIG. 10 is a time-space chart during learning in the embodiment of the present invention, where the vertical direction shows the number of processors and the horizontal direction shows time. 2 corresponds to the number of processors in the input layer, H corresponds to the number of processors in the hidden layer, and 2 corresponds to the time for the product-sum operation of the processors.

入力信号が隠れ層の前向き積和に要する時間は、入力層
のプロセッサの数Iと1つのプロセッサの積和に対応す
る時間Iとの積に比例する。次に、シグモイドの計算が
行われる。出力層においても出力層の前向き積和(2H
I)とシグモイドが行われる。ここで、出力層のプロセ
ッサの数が隠れ層のプロセッサの数より少ないので、リ
ングの大きさ自体も小さくなる。次ぎに教師信号入力と
受信し、誤差計算を行い、誤差のバック・プロパゲーシ
ョンを行う。なお、この誤差計算は出力層のシグモイド
における誤差計算も服務出力層の後向き積和を行い、出
力層の重み更新を勾配ベクトル計算とローバスフィルタ
を介して行う。そして、隠れ層のシグモイドによる誤差
計算を経て、隠れ層においては、後向き積和は行わず隠
れ層の重み更新のみを行う。
The time required for the input signal to perform the forward sum of products in the hidden layer is proportional to the product of the number I of processors in the input layer and the time I corresponding to the sum of products of one processor. Next, a sigmoid calculation is performed. Also in the output layer, the output layer's forward sum of products (2H
I) and sigmoid are performed. Here, since the number of processors in the output layer is smaller than the number of processors in the hidden layer, the size of the ring itself is also smaller. Next, it receives the teacher signal input, calculates the error, and performs back propagation of the error. In this error calculation, the error calculation in the sigmoid of the output layer is also performed by performing backward product sum of the service output layer, and the weight update of the output layer is performed via gradient vector calculation and a low-pass filter. Then, after calculating the error using the sigmoid in the hidden layer, only the weights of the hidden layer are updated without performing the backward sum of products.

〔発明の効果〕〔Effect of the invention〕

以上説明した様に、本発明によれば従来の方法より広い
範囲の処理に対して、データ処理に伴うデータ転送によ
るオーバヘンド無しにデータを並列に処理出来る効果を
奏し、データ処理ユニットの台数に比例した高速なデー
タ処理が実現出来ることにより、行列演算あるいはニュ
ーロコンピュータ演算をアナログ信号について行うデー
タ処理装置の性能向上に寄与するところが大きい。
As explained above, the present invention has the effect of being able to process data in parallel over a wider range of processing than conventional methods without any overhead due to data transfer associated with data processing, and is proportional to the number of data processing units. The ability to realize high-speed data processing greatly contributes to improving the performance of data processing devices that perform matrix operations or neurocomputer operations on analog signals.

【図面の簡単な説明】[Brief explanation of drawings]

第1図(A)は、本発明の原理構成図、第1図(B)は
、本発明の動作フローチャート、第1図(C)は、本発
明の動作概要図、第1図(D)は、本発明の動作タイム
チャート、第2図(A)は、第1の実施例の構成図、第
2図(B)は、第1の実施例の動作フローチャート、 第2図(C)は、第1の実施例の動作概要図、第2図(
D)は、第1の実施例の動作タイムチャート、 第3図(A)は、第2の実施例の構成図、第3図(B)
は、第2の実施例の動作フローチャート、 第3図(C)は、第2の実施例の動作概要図、第3図(
D)は、第2の実施例の動作タイムチャート、 第4図(A)は、第3の実施例の構成図、第4図(B)
は、第3の実施例の動作フローチャート、 第4図(C)は、第3の実施例の動作概要図、第4図(
D)は、第3の実施例の動作タイムチャート、 第4図(E)は、第3の実施例の詳細動作フローチャー
ト、 第5図(A)は、第4の実施例の構成図、第5図(B)
は、第4の実施例のニューロンモデル、 第5図(C)は、第4の実施例のネットワーク、第5図
(D)は、第4の実施例の前向き処理フローチャート、 第5図(E)は、第4の実施例の学習処理フローチャー
ト、 第5図(F)は、Sandyでエラーバックプロパゲー
ション学習を行うときの処理フローチャート、第5図(
G)は、Sandyで行列ベクトル積U一Wxを計算す
るときのタイムチャート、第5図(H)は、転置行列で
の行列ベクトル積e=W”vを計算するときのタイムチ
ャート、第6図(A)は、第5の実施例の構戒図、第6
図(B)は、第5の実施例の動作フローチャート、 第6図(C)は、第5の実施例の動作概要図、第6図(
D)は、第5の実施例の動作タイムチャート、 第7図(A)は、第6の実施例の構成図、第7図(B)
は、第6の実施例の動作フローチャート、 第7図(C)は、第6の実施例の動作概要図、第7図(
D)は、第6の実施例の動作タイムチャート、 第8図は、トレイの構造を具体的に示す図、第9図は、
本発明の実施例を用いて実際に構成されたニューロコン
ピュータのブロック図、第10図は、本発明の実施例に
おける学習時の時間空間チャート、 第11図(A)は、共通バスS IMD方式の原理構成
図、 第11図(B)は、共通バスSMD方式による行列ベク
トル積の動作フローチャート、第12図(A)及び第1
2図(B)は、リングシストリノク方式による行列ベク
トル積の動作原理図、 第12(C)は、リングシストリック方式による行列ベ
クトル積の動作原理図である。 1・・・データ処理ユニット、 2・ ・ ・トレイ、 3・・・シフトレジスタ、 4・・・記憶装置、 5・・・同期手段、 6 7 11 12 2工 22 23 24 82 83 84 85 91 92 93 ・データ設定手段、 ・長さ変更手段、 ・データ処理ユニット1の入力、 ・データ処理ユニット1の第2の入力、・トレイ2の第
1の入力、 ・トレイニの第1の出力、 ・トレイ2の第2の出力、 ・トレイ2の第2の入力、 ・PE9 1の第1の入力、 ・PE9 1の第1の出力、 ・PE9 1の第2の入力、 ・PE9 1の第2の出力、 ・PE, ・PE9 1の入出力、 ・共通バス.
FIG. 1(A) is a principle block diagram of the present invention, FIG. 1(B) is an operation flowchart of the present invention, FIG. 1(C) is a schematic diagram of the operation of the present invention, and FIG. 1(D) is an operation time chart of the present invention, FIG. 2(A) is a configuration diagram of the first embodiment, FIG. 2(B) is an operation flowchart of the first embodiment, and FIG. 2(C) is an operation flowchart of the first embodiment. , a schematic diagram of the operation of the first embodiment, FIG.
D) is an operation time chart of the first embodiment, FIG. 3(A) is a configuration diagram of the second embodiment, FIG. 3(B)
is an operation flowchart of the second embodiment, FIG. 3(C) is an operation overview diagram of the second embodiment, and FIG.
D) is an operation time chart of the second embodiment, FIG. 4(A) is a configuration diagram of the third embodiment, FIG. 4(B)
is an operation flowchart of the third embodiment, FIG. 4(C) is an operation overview diagram of the third embodiment, and FIG.
D) is an operation time chart of the third embodiment, FIG. 4E is a detailed operation flowchart of the third embodiment, and FIG. 5A is a configuration diagram of the fourth embodiment. Figure 5 (B)
is a neuron model of the fourth embodiment, FIG. 5(C) is a network of the fourth embodiment, FIG. 5(D) is a forward processing flowchart of the fourth embodiment, and FIG. ) is a learning process flowchart of the fourth embodiment, FIG. 5(F) is a process flowchart when error back propagation learning is performed on Sandy, and FIG.
G) is a time chart when calculating the matrix-vector product U - Wx in Sandy, FIG. 5 (H) is a time chart when calculating the matrix-vector product e=W''v in a transposed matrix, and Figure (A) is a composition diagram of the fifth embodiment;
FIG. 6(B) is an operation flowchart of the fifth embodiment, FIG. 6(C) is a schematic diagram of the operation of the fifth embodiment, and FIG.
D) is an operation time chart of the fifth embodiment, FIG. 7(A) is a configuration diagram of the sixth embodiment, FIG. 7(B)
is an operation flowchart of the sixth embodiment, FIG. 7(C) is an operation overview diagram of the sixth embodiment, and FIG.
D) is an operation time chart of the sixth embodiment, FIG. 8 is a diagram specifically showing the structure of the tray, and FIG. 9 is:
A block diagram of a neurocomputer actually constructed using an embodiment of the present invention, FIG. 10 is a time-space chart during learning in an embodiment of the present invention, and FIG. 11(A) is a common bus SIMD system. 11(B) is an operational flowchart of matrix-vector product using the common bus SMD method, FIG. 12(A) and 1.
FIG. 2(B) is a diagram showing the principle of operation of matrix-vector product using the ring-systolic method, and FIG. 12(C) is a diagram showing the principle of operation of matrix-vector product using the ring-systolic method. 1... Data processing unit, 2... Tray, 3... Shift register, 4... Storage device, 5... Synchronization means, 6 7 11 12 2nd grade 22 23 24 82 83 84 85 91 92 93 - data setting means, - length changing means, - input of data processing unit 1, - second input of data processing unit 1, - first input of tray 2, - first output of traini, - tray 2nd output of PE9 1, ・2nd input of tray 2, ・1st input of PE9 1, ・1st output of PE9 1, ・2nd input of PE9 1, ・2nd input of PE9 1 Output, ・PE, ・PE9 1 input/output, ・Common bus.

Claims (1)

【特許請求の範囲】 1)各々少なくとも一つの入力(11)を持つ複数個の
データ処理ユニット(1)と、 各々第1の入力(21)及び出力(22)を持ちかつ各
々データ保持及びデータ転送を行う複数個のトレイ(2
)であって、前記トレイ(2)の全部又はその一部が各
々前記データ処理ユニット(1)の第1の入力(11)
に接続された第2の出力(23)を有するものと、 前記接続するトレイ(2)の第1の入力(21)及び出
力(22)が接続されて成るシフト手段(3)とを具備
し、 前記シフト手段(3)上のデータ転送と、前記トレイ(
2)と前記データ処理ユニット(1)間のデータ転送と
、前記データ処理ユニット(1)によるデータ処理とを
同期して行うことにより、行列演算あるいはニューロコ
ンピュータ演算をアナログ信号について行うことを特徴
とする並列データ処理方式。 2)前記シフト手段(3)はサイクリックシフトレジス
タであることを特徴とする特許請求の範囲第1項記載の
並列データ処理方式。 3)前記シフト手段(3)の長さを変更する手段を有す
ことを特徴とする特許請求の範囲第1項又は第2項に記
載の並列データ処理方式。 4)前記シフト手段(3)の長さを変更する手段は、入
力切り換え手段であることを特徴とする特許請求の範囲
第3項記載の並列データ処理方式。 5)前記シフト手段(3)の長さを変更する手段は、外
部のデータ供給手段と、入力選択手段とからなることを
特徴とする特許請求の範囲第3項記載の並列データ処理
方式。 6)前記データ処理ユニット(1)が第1の出力(21
)を持ち、前記トレイ(2)が該第1の出力(21)に
接続された第2の入力(24)を持ち、前記データ処理
ユニット(1)から前記トレイ(2)にデータを書き込
む手段を有することを特徴とする特許請求の範囲第1項
乃至第5項のいずれかに記載の並列データ処理方式。 7)前記データ処理ユニット(1)と前記トレイ(2)
間のデータ転送路は入力と出力で共通に利用するバスで
あることを特徴とする特許請求の範囲第6項記載の並列
データ処理方式。 8)データの処理結果を更に処理するに際し、前記処理
結果を前記書き込み手段を用いて前記トレイ(2)に転
送することを特徴とする特許請求の範囲第6項又は第7
項に記載の並列データ処理方式。 9)前記トレイ(2)が各々相互に接続された第3の入
力(25)及び出力(26)を備え、前記シフト手段(
3)は双方向シフトレジスタであることを特徴とする特
許請求の範囲第1項乃至第8項のいずれかに記載の並列
データ処理方式。 10)前記双方向シフトレジスタを構成する前記各トレ
イ(2)間のデータ転送路は入力と出力で共通に利用さ
れるバスであることを特徴とする特許請求の範囲第9項
記載の並列データ処理方式。 11)前記双方向シフトレジスタ上をデータを双方向に
転送することを特徴とする特許請求の範囲第9項又は第
10項に記載の並列データ処理方式。
[Claims] 1) a plurality of data processing units (1) each having at least one input (11), each having a first input (21) and an output (22) and each having a data storage and a data processing unit; Multiple trays (2
), wherein all or part of said trays (2) are each connected to a first input (11) of said data processing unit (1).
a second output (23) connected to the tray; and shifting means (3) comprising a first input (21) and an output (22) of the connecting tray (2). , data transfer on said shifting means (3) and said tray (
2) and the data processing unit (1) and data processing by the data processing unit (1) are performed synchronously, thereby performing matrix operations or neurocomputer operations on analog signals. A parallel data processing method. 2) The parallel data processing system according to claim 1, wherein the shift means (3) is a cyclic shift register. 3) The parallel data processing system according to claim 1 or 2, further comprising means for changing the length of the shift means (3). 4) The parallel data processing system according to claim 3, wherein the means for changing the length of the shift means (3) is input switching means. 5) The parallel data processing system according to claim 3, wherein the means for changing the length of the shift means (3) comprises external data supply means and input selection means. 6) said data processing unit (1) outputs a first output (21);
), said tray (2) having a second input (24) connected to said first output (21), means for writing data from said data processing unit (1) to said tray (2). A parallel data processing method according to any one of claims 1 to 5, characterized in that it has the following. 7) The data processing unit (1) and the tray (2)
7. The parallel data processing system according to claim 6, wherein the data transfer path between the two is a bus commonly used for input and output. 8) When further processing the data processing result, the processing result is transferred to the tray (2) using the writing means.
Parallel data processing method described in Section. 9) said tray (2) is provided with a third input (25) and an output (26) each interconnected, said shifting means (
9. The parallel data processing system according to claim 1, wherein 3) is a bidirectional shift register. 10) Parallel data according to claim 9, characterized in that the data transfer path between the trays (2) constituting the bidirectional shift register is a bus commonly used for input and output. Processing method. 11) The parallel data processing method according to claim 9 or 10, wherein data is transferred bidirectionally on the bidirectional shift register.
JP1243969A 1989-09-20 1989-09-20 Parallel data processing system Pending JPH03105581A (en)

Priority Applications (5)

Application Number Priority Date Filing Date Title
JP1243969A JPH03105581A (en) 1989-09-20 1989-09-20 Parallel data processing system
AU63030/90A AU641418B2 (en) 1989-09-20 1990-09-20 A parallel data processing system for processing and transmitting data concurrently
DE69032259T DE69032259T2 (en) 1989-09-20 1990-09-20 Parallel data processing system
EP90310302A EP0421639B1 (en) 1989-09-20 1990-09-20 Parallel data processing system
US08/227,472 US5600843A (en) 1989-09-20 1994-04-14 Ring systolic array system for synchronously performing matrix/neuron computation using data transferred through cyclic shift register connected in cascade of trays

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1243969A JPH03105581A (en) 1989-09-20 1989-09-20 Parallel data processing system

Publications (1)

Publication Number Publication Date
JPH03105581A true JPH03105581A (en) 1991-05-02

Family

ID=17111744

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1243969A Pending JPH03105581A (en) 1989-09-20 1989-09-20 Parallel data processing system

Country Status (1)

Country Link
JP (1) JPH03105581A (en)

Similar Documents

Publication Publication Date Title
US5600843A (en) Ring systolic array system for synchronously performing matrix/neuron computation using data transferred through cyclic shift register connected in cascade of trays
US5506998A (en) Parallel data processing system using a plurality of processing elements to process data and a plurality of trays connected to some of the processing elements to store and transfer data
JPH04290155A (en) Parallel data processing system
US5542026A (en) Triangular scalable neural array processor
US5146543A (en) Scalable neural array processor
US5148515A (en) Scalable neural array processor and method
CN110580519B (en) Convolution operation device and method thereof
US5065339A (en) Orthogonal row-column neural processor
CN110826710A (en) Hardware acceleration implementation system and method of RNN forward propagation model based on transverse pulse array
US5422836A (en) Circuit arrangement for calculating matrix operations in signal processing
US5243688A (en) Virtual neurocomputer architectures for neural networks
CN111985626B (en) System, method and storage medium for accelerating RNN (radio network node)
JPH05346914A (en) Neuro processor
US5627944A (en) Parallel data processing system
JPH03105584A (en) Parallel data processing system
US5146420A (en) Communicating adder tree system for neural array processor
JPH03105581A (en) Parallel data processing system
CN110673824A (en) Matrix vector multiplication circuit and circular neural network hardware accelerator
JPH03105582A (en) Parallel data processing system
JPH03105583A (en) Parallel data processing system
Ayoubi et al. Efficient mapping algorithm of multilayer neural network on torus architecture
JPH04233062A (en) Vector processing method and circuit thereof
US5251287A (en) Apparatus and method for neural processing
Al-Dabass et al. Parallelism in neural nets
Paschke et al. Simulation of sparse random networks on a CNAPS SIMD neurocomputer