JPH0670590B2 - Color order determination method - Google Patents

Color order determination method

Info

Publication number
JPH0670590B2
JPH0670590B2 JP63227184A JP22718488A JPH0670590B2 JP H0670590 B2 JPH0670590 B2 JP H0670590B2 JP 63227184 A JP63227184 A JP 63227184A JP 22718488 A JP22718488 A JP 22718488A JP H0670590 B2 JPH0670590 B2 JP H0670590B2
Authority
JP
Japan
Prior art keywords
color
hue
hue angle
length
order
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.)
Expired - Lifetime
Application number
JP63227184A
Other languages
Japanese (ja)
Other versions
JPH0274832A (en
Inventor
精一 沼田
仁夫 高田
賢一 福永
正行 ▲高▼橋
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.)
Kurashiki Spinning Co Ltd
Original Assignee
Kurashiki Spinning Co 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 Kurashiki Spinning Co Ltd filed Critical Kurashiki Spinning Co Ltd
Priority to JP63227184A priority Critical patent/JPH0670590B2/en
Publication of JPH0274832A publication Critical patent/JPH0274832A/en
Publication of JPH0670590B2 publication Critical patent/JPH0670590B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Spectrometry And Color Measurement (AREA)

Description

【発明の詳細な説明】Detailed Description of the Invention

(産業上の利用分野) 本発明は、色の配列順を判別することのできる色順判定
方式に関する。 (従来技術とその課題) 従来より、コンピュータ等の電子機器の内部配線に用い
られるコネクタには、所定本数のワイヤハーネスを所定
の色順で接続されるようにしているが、色順が誤って接
続された場合には、誤配線の原因となる。 従来においては、コネクタのワイヤハーネスの色順をい
ちいち目視により検査しているため、多くの人手と時間
を要する問題があった。 このため、特開昭62−9236号公報においては、 「カラーセンサ制御装置を用いて、検査マスターと被検
査物との差に基づき色順の正誤を判定する方法にして,
カラーセンサー制御装置に検査マスター値入力により,
赤,緑,青の3原色のセンサー入力をとり込み,サンプ
ル数を増せば,その平均値をとり,今,この値を とし,次に被検査物用データを入力し,この時サンプル
の値を とし,このデータを基にして,色順を判定する方法とし
て, を計算し,l1nの最小になる色nを決定し, これをR11,G11,B11〜Rn1,Gn1,Bn1まで処理を行ない をくり返し、この結果 となれば合格とするカラーセンサー制御装置による演算
処理を行うことを特徴とする複数の色彩を備えた被検査
物の色順判定法。」 が提案されている。 しかしながら、この方式を用いて上記ワイヤハーネスの
検査を行うことは、実際上不可能であった。 その原因としては、種々考えられるが、第1には、上記
のようにR,G,Bの3原色を用いて比較を行う方法では,
光源の変化や距離の変動に弱く、例えば、赤と茶といっ
た同系色を確実に検出することができず、実用に適して
いないことである。第2に、上記の特開昭62−9236号公
報においても、コネクタの電線の色順の判別を行う実施
例が開示されているが、電線は普通、円柱形状をしてお
り、光を照射して、その反射光を受光する際に、光の照
射位置を確定するのが困難であり、また、電線が隣同士
接しているような場合には、隣の電線からの反射光をも
受光してしまい、そのために、正確な3原色の読み取り
ができないが、これらの問題に対する対策はなんら触れ
られていない。さらには、1つのコネクタ中に同じ色の
電線が存在する場合には、上述の演算方法では検出が不
可能である。 また、近年、現在用いられているバーコードの情報量を
アップさせるために、バーコードのカラー化の計画があ
り、そのようなカラーバーコードを正確に読み取ること
のできるバーコードリーダーの要望が高まっているが、
特開昭62-9236号公報によるものでは、そのカラーバー
コードリーダーに応用できない。 本発明の目的は、上記の問題点を解決するために、色彩
工学上の手法を有効に利用し、人間の視覚による判断と
同様に、色の判別を色相、色調に基づいて行って、正確
な色順の判定を行うことのできる色順判定方式を提供す
ることである。 (課題を解決するための手段) そのため、本発明に係る色順判定方式は、 複数の色が所定の順序で配列された色配列の色順を検出
する色順判定方式であって、 基準となる色配列の各色について、配列された個々の色
をR,G,Bに分解して読み取り、その読取値からL*a*b*
色系における明度指数L*及びクロマチックネス指数a*,b
*をそれぞれ求め、式 によって定義される色相角H°と、式 T°=tan-1{L*/(a*2+b*2)1/2} によって定義される色調角T°と、式 TR=(L*2+a*2+b*2)1/2 によって定義される色調長TRとを、予め計算して、テー
ブルに記憶し、上記複数の色の各色について、配列され
た個々の色をR,G,Bに分解して読み取り、その読取値か
ら上記色相角H°、色調角T°および色調長TRを計算し
て、上記テーブルに記憶された上記基準となる色配列の
各色の色相角、色調角および色調長とそれぞれ比較する
ことによって色順を判定することを特徴とする。 (作用) 基準となる色順と判定させる色順の各色に対する色相
角、色調角、色調長をそれぞれ比較して、色順を判定す
る。 (実施例) 以下、添付の図面を参照しながら、本発明の実施例を説
明する。 第3図に、本発明を適用した色順判定装置のシステム構
成を示すように、本色順判定装置は、センサヘッド1
と、このセンサヘッド1に信号ケーブル群2を介して接
続されたコントローラ3によって基本的に構成される。 センサヘッド1は、例えばダイクロイックミラー付ハロ
ゲンランプで構成した照明光源4と、入射角45°で照明
光源によって照射された被測定物5の表面からの散乱光
を集光レンズ6を介して受光するR,G,B3色のカラーセン
サ7と、カラーセンサ7のR,G,B各検出部から出力され
るR,G,B信号を増幅するR,G,B信号増幅用アンプ8,9,10と
を備えて構成される。 また、上記コントローラ3は、増幅されたR,G,B信号を
順次にスキャンするマルチプレクサ12と、マルチプレク
サ12から順次に出力されるR,G,B信号をA/D変換器13
を介して読み込み、色判別を行うマイクロコンピュータ
14とで基本的に構成されている。 マイクロコンピュータ14は、機能的に大別した場合、キ
ーボード15から入力される指令にしたがって色順判定演
算に必要な制御を実行する制御部14Aと、色順判定に必
要な各種データを格納したデータ格納部14Bと、制御部1
4Aからの制御信号に従って色順判定演算のために予め組
み込まれた演算プログラムを実行する演算部14Cと、演
算結果を表示信号に変換して、液晶ディスプレイ16に演
算結果を表示するための表示部14Dと、演算結果を出力
端子14Fにデジタル信号として出力するためのデジタル
出力部14Eとに分けることができる。 第8図には、本発明に係る色順判定方式を用いてワイヤ
ハーネスの色順判定を行うための装置を示す。第8図に
示すように、基台25には、その中央部にコネクタホルダ
ー100,100,…を外周部に等角度ピッチで設けた回転台10
1が回転軸102によって等速度で一方向に回転するように
支持されている。上記各コネクタホルダー100には、所
定本数のワイヤハーネスを接続したコネクタ5が吊下げ
支持され、回転台101の回転に伴って、支持台103上に支
持されたセンサヘッド1の前方を通過する。センサヘッ
ド1によって読み取られたワイヤハーネスの色データ
は、ケーブル2を介して、支持フレーム104に支持され
たコントローラ3に送られ、コントローラ3のディスプ
レイ16上に判定結果が表示されるようになっている。ま
た、各コネクタホルダー100,100…の上面には、ワイヤ
ハーネスと同ピッチのストライプパターン101aが付けら
れており、光電センサ50が、センサヘッド1に対向する
コネクタホルダー100のストライプパターン101aを検知
可能な位置に固定される。この光電センサ50は、個々の
ストライプを読み取って、ワイヤハーネス1本毎の位置
情報を与えるものであって、この位置情報(同期信号)
の存在時に、R,G,Bデータのピーク値が存在するか否か
により、黒色を判定するものである。位置情報の存在に
もかかわらず、R,G,Bデータのピークが存在しない場合
には黒色ハーネスと判断する。 なお、ワイヤハーネスが欠落している場合にも、ハーネ
スの同期信号があるにもかかわらず、ピーク値が検出で
きないために黒色ハーネスと判断されてしまうが、これ
を防ぐために、図示は省略するが、別の光電センサ等を
用いて、センサヘッドに対向するコネクタホルダー100
に支持されているワイヤハーネスを同期信号に同期させ
てその存在を検知させたり、ワイヤハーネスの数を回転
台101の回転に伴ってカウントして所定のハーネス数よ
り少ないときは、ワイヤハーネスが欠落していると判断
させてもよい。 第1図及び第2図に色順判定のためのアルゴリズムをフ
ローチャートで示す。 このアルゴリズムは、基本的には、判定する色の配列
(色順)をデータ格納部14BのRAM(図示せず)にティー
チングテーブルとして必要なデータを格納する色順の登
録処理(ティーチング)と、被検査物の色測定を行い、
その結果を分析して、最終的に色順を判定する色順判定
処理の2つの処理に大別される。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a color order determination method capable of determining a color arrangement order. (Prior art and its problem) Conventionally, a connector used for internal wiring of an electronic device such as a computer is connected with a predetermined number of wire harnesses in a predetermined color order, but the color order is incorrect. If it is connected, it may cause incorrect wiring. Conventionally, since the color order of the wire harness of the connector is visually inspected one by one, there is a problem that it requires a lot of manpower and time. For this reason, in Japanese Patent Laid-Open No. 62-9236, "a method for determining whether a color order is correct or incorrect based on a difference between an inspection master and an object to be inspected by using a color sensor control device,
By inputting the inspection master value to the color sensor controller,
Take in the sensor inputs of the three primary colors of red, green, and blue, increase the number of samples, take the average value, and now take this value. Then, input the data for the inspected object, and at this time, the value of the sample And as a method to judge the color order based on this data, Is calculated and the color n that minimizes l 1n is determined, and this is processed from R 11 , G 11 , B 11 to R n1 , G n1 , B n1. Repeat this result If so, a color order determination method for an object to be inspected having a plurality of colors, which is characterized by performing arithmetic processing by a color sensor control device that passes. Is proposed. However, it is practically impossible to inspect the wire harness using this method. There are various possible causes for this, but first, in the method of performing comparison using the three primary colors of R, G, and B as described above,
It is not suitable for practical use because it is not sensitive to changes in the light source and changes in distance and cannot reliably detect similar colors such as red and brown. Secondly, the above-mentioned Japanese Patent Laid-Open No. 62-9236 also discloses an embodiment for determining the color order of the electric wires of the connector, but the electric wires are usually in the shape of a cylinder and are irradiated with light. Then, when receiving the reflected light, it is difficult to determine the irradiation position of the light, and when the wires are adjacent to each other, the reflected light from the adjacent wire is also received. As a result, accurate reading of the three primary colors cannot be performed, but no countermeasures against these problems are mentioned. Furthermore, if there is an electric wire of the same color in one connector, it cannot be detected by the above-described calculation method. In addition, in recent years, there are plans to colorize barcodes in order to increase the amount of information on barcodes currently used, and there is an increasing demand for barcode readers that can accurately read such color barcodes. However,
The one disclosed in JP-A-62-9236 cannot be applied to the color barcode reader. An object of the present invention is to effectively use a color engineering method in order to solve the above-mentioned problems, and similarly to human visual judgment, color discrimination is performed based on hue and tone, and accurate It is an object of the present invention to provide a color order determination method capable of determining a different color order. (Means for Solving the Problem) Therefore, the color order determination method according to the present invention is a color order determination method for detecting the color order of a color array in which a plurality of colors are arranged in a predetermined order, and For each color of the color array, the individual colors arranged are read out by separating them into R, G, B, and from the read value, the lightness index L * and chromaticness index a * in the L * a * b * color system are read. b
Calculate each * and formula And the hue angle H ° defined by the formula T ° = tan −1 {L * / (a * 2 + b * 2 ) 1/2 } and the formula TR = (L * 2 + a * 2 + b * 2 ) 1/2 , and the tone length TR defined by 1/2 is calculated in advance and stored in a table, and for each color of the above plurality of colors, the individual colors arranged are R, G and B are separated and read, and the hue angle H °, the hue angle T ° and the hue length TR are calculated from the read values, and the hue angle of each color of the reference color array stored in the table, It is characterized in that the color order is determined by comparing with the color tone angle and the color tone length, respectively. (Operation) The hue order, the hue angle, and the hue length for each color in the color order to be determined as the reference color order are compared to determine the color order. (Examples) Examples of the present invention will be described below with reference to the accompanying drawings. As shown in FIG. 3 showing the system configuration of the color order determination apparatus to which the present invention is applied, the color order determination apparatus includes the sensor head 1
And a controller 3 that is connected to the sensor head 1 via a signal cable group 2. The sensor head 1 receives, via a condensing lens 6, an illumination light source 4 composed of, for example, a halogen lamp with a dichroic mirror, and scattered light from the surface of the DUT 5 illuminated by the illumination light source at an incident angle of 45 °. R, G, B three-color sensor 7, and R, G, B signal amplification amplifiers 8, 9, for amplifying R, G, B signals output from the R, G, B detection units of the color sensor 7. Comprised of 10 and. Further, the controller 3 includes a multiplexer 12 for sequentially scanning the amplified R, G, B signals, and an A / D converter 13 for the R, G, B signals sequentially output from the multiplexer 12.
A microcomputer that reads in via color and performs color discrimination
It is basically composed of 14 and. The microcomputer 14 is, when functionally divided, a control unit 14A that executes control necessary for color order determination calculation according to a command input from the keyboard 15, and data that stores various data required for color order determination. Storage unit 14B and control unit 1
An arithmetic unit 14C that executes an arithmetic program incorporated in advance for color order determination arithmetic according to a control signal from 4A, and a display unit that converts the arithmetic result into a display signal and displays the arithmetic result on the liquid crystal display 16. 14D and a digital output section 14E for outputting the calculation result as a digital signal to the output terminal 14F. FIG. 8 shows an apparatus for performing color order determination of a wire harness using the color order determination method according to the present invention. As shown in FIG. 8, the base 25 has a rotary base 10 having connector holders 100, 100, ...
1 is supported by a rotating shaft 102 so as to rotate in one direction at a constant speed. A connector 5 to which a predetermined number of wire harnesses are connected is suspended and supported by each of the connector holders 100, and as the rotary table 101 rotates, it passes in front of the sensor head 1 supported on the support table 103. The color data of the wire harness read by the sensor head 1 is sent to the controller 3 supported by the support frame 104 via the cable 2, and the determination result is displayed on the display 16 of the controller 3. There is. Further, a stripe pattern 101a having the same pitch as that of the wire harness is provided on the upper surface of each connector holder 100, 100 ... At a position where the photoelectric sensor 50 can detect the stripe pattern 101a of the connector holder 100 facing the sensor head 1. Fixed to. The photoelectric sensor 50 reads each stripe and gives position information for each wire harness. This position information (synchronization signal)
When there is, the black color is judged by whether or not there is a peak value of R, G, B data. If the R, G, B data peaks do not exist despite the presence of the position information, it is determined to be a black harness. Even if the wire harness is missing, the peak value cannot be detected even though there is a harness synchronization signal, so the wire harness is determined to be a black harness. , Using another photoelectric sensor, etc., connector holder 100 facing the sensor head
If the number of wire harnesses is less than a predetermined number by counting the number of wire harnesses as the turntable 101 rotates, the wire harnesses are missing. You may decide that you are doing. FIGS. 1 and 2 are flowcharts showing an algorithm for determining the color order. This algorithm is basically a color order registration process (teaching) for storing the necessary data as a teaching table in the RAM (not shown) of the data storage unit 14B for the array of colors to be judged (color order), Measure the color of the object to be inspected,
The result is analyzed and the color order is finally classified into two processes, that is, a color order determination process.

【諸量の定義】[Definition of various quantities]

第1図及び第2図を説明する前に、本発明の実施例に用
いる諸量の定義を行う。 (A)XYZ表色系 RGB表色系における三刺激値R,G,Bが与えられたとき、XY
Z表色系における三刺激値X,Y,Zは、色彩工学上よく知ら
れているように、 X=2.7689R+1.7517G+1.1302B Y=1.0000R+4.5907G+0.0601B Z=0.0560G+5.5943B で与えられる。 (B)L*a*b*表色系 このL*a*b*表色系は、上記三刺激値X,Y,Zを用いて、明
度指数L*、クロマチックネス指数a*,b*がそれぞれ以下
の式で与えられる表色系である。 L*=116(Y/Y0)1/3−16 a*=500{(X/X0)1/3−(Y/Y0)1/3} b*=200{(Y/Y0)1/3−(Z/Z0)1/3} ただし、X0,Y0,Z0は照明光源の三刺激値である。 なお、第4図には、参考のため、L*a*b*表色系立体を示
す。 ◎色差 2色間の物理的な測定の数値的評価の差を色差ΔEと呼
び、L*a*b*表色系では、次の式で定義される。 ΔE={(ΔL+(Δa+(Δb
1/2 (C)色ベクトル いま、第5図に示すような色相面を考える。この色相面
は、第4図のL*a*b*表色系立体を明度L軸に直交する
任意の横断面に相当する。 この色相面上で、2つの指数a*,b*で与えられる色相ベ
クトル を考え、以下のごとく色相角H°と色相ベクトル長(=
彩度)C*を定義する。 ◎色相角(H°) ◎色相ベクトル長(=彩度)(C*) C*=(a*2+b*2)1/2 (D)色調ベクトル いま、第6図に示すように、彩度C*を横軸、明度L*を縦
軸とした色調面を考え、この色調面上で色調ベクトル▲
▼を以下の通り定義する。 ◎色調角(T°) T°=tan-1(L*/C*) ◎色調ベクトル長(TR) TR=(L*2+C*2)1/2 こうして色調面を考え、色調ベクトル▲▼がどの領
域を指すかによって、第6図に細線で領域を囲って示す
ように、“うすい(P領域)”、“浅い(LT領域)”、
“明るい(B領域)”、“さえた(V領域)”、“濃い
(DP領域)”“暗い(DK領域)”といった計6個の領域
に、色を色調化することができ、人間が実際に見た感覚
にあったものとすることができる。
Before describing FIGS. 1 and 2, various quantities used in the embodiment of the present invention will be defined. (A) XYZ color system When the tristimulus values R, G, B in the RGB color system are given, XY
The tristimulus values X, Y, Z in the Z color system are given by X = 2.7689R + 1.7517G + 1.1302B Y = 1.0000R + 4.5907G + 0.0601B Z = 0.0560G + 5.5943B, as is well known in color engineering. To be (B) L * a * b * color system This L * a * b * color system uses the above tristimulus values X, Y, and Z to obtain a lightness index L * and a chromaticness index a * , b *. Is a color system given by the following equations, respectively. L * = 116 (Y / Y 0) 1/3 -16 a * = 500 {(X / X 0) 1/3 - (Y / Y 0) 1/3} b * = 200 {(Y / Y 0 ) 1 / 3- (Z / Z 0 ) 1/3 } where X 0 , Y 0 and Z 0 are tristimulus values of the illumination light source. For reference, FIG. 4 shows an L * a * b * color system solid. Color difference The difference in the numerical evaluation of the physical measurement between the two colors is called the color difference ΔE, and is defined by the following formula in the L * a * b * color system. ΔE = {(ΔL * ) 2 + (Δa * ) 2 + (Δb * ) 2 }
1/2 (C) Color vector Now, consider a hue plane as shown in FIG. This hue plane corresponds to an arbitrary cross section of the L * a * b * color system solid body in FIG. 4 orthogonal to the lightness L * axis. On this hue plane, the hue vector given by the two indices a * and b * , The hue angle H ° and the hue vector length (=
Saturation) C * is defined. ◎ Hue angle (H °) ◎ Hue vector length (= saturation) (C * ) C * = (a * 2 + b * 2 ) 1/2 (D) Hue vector Now, as shown in Fig. 6, the saturation C * is the horizontal axis. , Consider the tone plane with the lightness L * as the vertical axis, and on this tone plane, the tone vector ▲
▼ is defined as follows. ◎ Tone angle (T °) T ° = tan -1 (L * / C * ) ◎ Tone vector length (TR) TR = (L * 2 + C * 2 ) 1/2 Depending on which region the ▼ indicates, as shown by enclosing the region with a thin line in FIG. 6, “thin (P region)”, “shallow (LT region)”,
The color can be toned into 6 areas, which are "bright (B area)", "saturated (V area)", "dark (DP area)" and "dark (DK area)". It can be the one that actually matches the feeling.

【色順判定】[Color order judgment]

(A)登録処理(ティーチングテーブルの作成) 第1図に、本発明の一実施例であるワイヤハーネスの色
順判定のための登録処理(ティーチング)の概略フロー
チャートを示す。 以下に、第1図のフローチャートの説明を行う。 まず、センサヘッド1を通して、ワイヤハーネスの色を
入力し、かつ、センサ50から同期信号を入力してメモリ
にストアする(ステップS2,S4、以下ステップを略す
る)。これはワイヤハーネスの数だけ繰り返して行われ
る。 次に、メモリにストアされたデータより、ハーネス1本
毎の代表となるデータ、即ち、R,G,B信号のピーク値を
検出する演算処理を行う(S6)。第7図に、例として色
順が橙、赤、茶、黒、白、灰、紫、青、緑、黄、橙、
赤、茶の13本のハーネスを有するコネクタの入力データ
と、それと同時にコネクタホルダー100に設けられたハ
ーネスと同ピッチのパターンを検出して、その検出に同
期して出力される同期信号を示す。この同期信号の出力
期間内における各ハーネスに対応するR,G,Bの信号のピ
ークを検出して、そのピーク値を代表データとすること
も可能である。このように非接触測定とすることによっ
て、円柱状のワイヤハーネスだけでなく、移動物体及
び、表面が凹凸のものの表面色の場合にも、測定のため
の位置決めが同時に容易に行え、測定も正確になる。 続いて、黒色ハーネス以外は同期信号の存在時に上記の
ピーク値が存在するので(S8でYES)、ハーネス1本毎
の代表データより色相角H°、色調角T°、色調長TR、
彩度C*をそれぞれ算出する(S10)。 そして、彩度C*が所定の閾値よりも大きければ(S12でY
ES)、有彩色であると判断されるので、無彩色フラグを
0にする(S14)。一方、彩度C*が所定の閾値よりも小
さければ(S12でNO)、無彩色と判断され、無彩色フラ
グを1として、色相角H°、色調角T°をともに0にす
る(S16)。 また、S8で同期信号の存在時にピーク信号が不在のとき
(NO)、ハーネスが存在していれば(ハーネスの存否は
図示しない光電管等で検出される)、(S18でYES)、そ
のハーネスを黒色と判断し、無彩色フラグを1、色相角
H°、色調角T°、色調長TR、彩度C*をそれぞれ0とす
る(S20)。ハーネスが存在していなければ(S18でN
O)、ハーネスの欠落等のなんらかのエラーであるの
で、エラー情報として色番号を−1としておき(S2
4)、S26に移る。 S14,S16,S20のうちの1つの処理を終えると、S22に移
る。S22では、ハーネスの整列順番号、色相角H°、色
調角T°、色調長TR、無彩色フラグ、色番号(この時点
では整列順番号と同じ)をそれぞれティーチングテーブ
ルにストアする。 なお、S8からS24までの処理は、ハーネスの数だけ繰り
返して行われる。 そして、S26でティーチングテーブル内に同色のハーネ
スを探して、みつかれば色番号を付け直して終了する。
同色か否かは、前述の色差ΔEによって判断され、色差
ΔEが所定の閾値以下であれば、同色とみなすようにす
る。 (B)色順判定処理 第2図に、色順判定のためのルーチンを示す。 まず、色順判定を行わせるワイヤハーネスの色データ及
び同期信号を入力し(S100)、メモリする(S102)。こ
れは、ハーネスの数だけ繰り返して行われる。 次に、ティーチングテーブルの作成のときと同様に、メ
モリにストアされたデータより、ピークを検出してハー
ネス1本毎の代表となるデータを選ぶ演算を行う(S10
4)。 ピークが検出されれば(S106でYES)、ハーネス1本毎
の代表データより、色相角H°、色調角T°、色調長T
R、彩度C*をそれぞれ算出する(S108)。 そして、求められた彩度C*が所定の閾値より大きければ
(S120でYES)、有彩色と判断して、無彩色フラグを0
とし(S122)、S124に移る。 次に、ティーチングテーブル内の同じ整列順において、
S108で求められた色相角H°、色調角T°及び色調長TR
が所定の許容範囲内であれば(S124,S126,S128でYE
S)、TRをメモリした後(S130)、色番号をランテーブ
ルにストアする(S140)。 なお、この許容範囲は比較的あらめに設定することで、
光量や測定距離等の変動に対して強くなる。 一方、S120で、彩度C*が所定の閾値よりも小さければ
(NO)、無彩色フラグを1とし、色相角H°、色調角T
°をそれぞれ0として(S134)、ティーチングテーブル
内の同じ整列順において、無彩色フラグが1であるかを
調べて(S136)、1であれば(YES)、S128に移り、色
調長TRについて許容範囲内にあるか否かを調べる。 S124,S126,S128において、色相角H°、色調角T°、色
調長TRのそれぞれが、同じ整列順で許容範囲内でなかっ
たり、S136で同じ整列順で無彩色フラグが0であったり
(NO)すれば、色番号を0として(S132,S138)、色が
一致しなかったことを示す。 また一方、S106で同期信号が存在するにもかかわらず、
ピーク値が存在しなければ(NO)、ハーネスの存在をチ
ェックして(S110)、存在していれば(YES)、そのハ
ーネスの色は黒と判断して、無彩色フラグを1、色相角
H°、色調角T°、色調長TR、彩度C*のそれぞれを0と
した(S112)後、S140に移る。また、存在していなけれ
ば(S110でNO)、エラー情報としてS114で色番号を−1
としてS140に移る。 上記のS106〜S140の処理は、ハーネスの本数だけ繰り返
して行われる。 ハーネスの本数分の処理が行われると、S142では、ラン
テーブル内のハーネスの色調長TRの最小値を基準とし
て、各ハーネスの色調長TRを相対的に見直して、色番号
を最終決定する(S142)。これは、色相角H°や色調角
T°は光源の光量変動に対して基準化された値であるの
に対し、色調長TRは、光源の光量変動を反映してしまう
ので、光量変動があった場合は、色調長TRの値は絶対的
な値とはみなすことができない。従って、色調長TRの最
小値を基準として、相対的な差を考慮して、各色番号を
見直して、最終決定するようにする。 (C)色順判定の具体例 以下に、上記の第1図、第2図のフローによる色順判定
の実例を示す。 第1表は、第7図のR,G,Bのデータから第1図のフロー
によって、色相角、色調角、色調長を算出し、これらを
登録して、作成したティーチングテーブルの一例であ
る。 また、ランテーブルは、第2図のフローによって、第1
表と同様に作成され、ティーチングテーブルの色番号の
一致、不一致を調べて、色順判定を行う。 ランテーブルの作成時には、第1図、第2図のフローの
ところで述べたように、ティーチングテーブルの色相
角、色調角、色調長のそれぞれには、許容範囲を予め設
定しておき(例えば色相角及び色調角は±15、色調長は
±13程度)、全てこの範囲内であれば、ランテーブルと
ティーチングテーブルの色番号が等しいものとする。第
2表にランテーブルの1例を示す。 この第2表の例では、下線を付して示すように、色番号
が、本来「9」の緑であるところが「0」となってい
る。これは、同じく下線によって示されている色相角H
°の値が142となっており、第1表のティーチングテー
ブルとは、その差が26(=168−142)となっており、上
記の許容範囲である±15を大幅に越えているため、第2
図のフローのS124でNOとなり、S132において色番号が0
とされたためである。従って、第1表のティーチングテ
ーブルと第2表のランテーブルの色番号が全て一致して
いないために、上記のランテーブルの作成に用いたワイ
ヤハーネスは、色順が基準のワイヤハーネスと一致して
いないと判定される。 本発明は、上記の実施例にとらわれるものではなく、色
配列順序が問題となるような種々の対象に適用すること
ができることはいうまでもない。 (効果) 本発明は、色彩工学上の手法を有効に利用して、人間の
視覚による判断に近い、色相角、色調角、色調長を用い
て、従来のR,G,Bの光量比のみによる色順判定では、達
成できなかった数多くの色からなる色順の正確な判定が
可能である。
(A) Registration Process (Creation of Teaching Table) FIG. 1 shows a schematic flowchart of the registration process (teaching) for determining the color order of the wire harness according to an embodiment of the present invention. The flowchart of FIG. 1 will be described below. First, the color of the wire harness is input through the sensor head 1, and the synchronization signal is input from the sensor 50 and stored in the memory (steps S2 and S4, the following steps are omitted). This is repeated by the number of wire harnesses. Next, from the data stored in the memory, arithmetic processing for detecting representative data for each harness, that is, peak values of R, G, B signals is performed (S6). In FIG. 7, as an example, the color order is orange, red, brown, black, white, gray, purple, blue, green, yellow, orange,
The input data of a connector having 13 harnesses of red and brown, and at the same time, a pattern of the same pitch as the harness provided on the connector holder 100 is detected, and a synchronization signal output in synchronization with the detection is shown. It is also possible to detect the peak of the R, G, B signals corresponding to each harness within the output period of the synchronization signal and use the peak value as the representative data. By performing non-contact measurement in this way, positioning can be easily performed at the same time not only for a cylindrical wire harness but also for a moving object and the surface color of an uneven surface. become. Then, except for the black harness, the above peak value exists when the sync signal exists (YES in S8), so the hue angle H °, the hue angle T °, the hue length TR, from the representative data for each harness,
The saturation C * is calculated (S10). If the saturation C * is larger than the predetermined threshold (Y in S12
ES), it is determined that the color is chromatic, so the achromatic color flag is set to 0 (S14). On the other hand, if the saturation C * is smaller than the predetermined threshold value (NO in S12), it is determined as an achromatic color, the achromatic color flag is set to 1, and both the hue angle H ° and the hue angle T ° are set to 0 (S16). . If the peak signal is absent when the sync signal is present in S8 (NO), and if the harness is present (whether or not the harness is detected by a photoelectric tube or the like not shown) (YES in S18), the harness is set. It is judged to be black, and the achromatic flag is set to 1, the hue angle H °, the hue angle T °, the hue length TR, and the saturation C * are set to 0 (S20). If the harness does not exist (N in S18
O), some error such as missing harness, so the color number is set to -1 as error information (S2
4) 、 Go to S26. When the processing of one of S14, S16, and S20 is completed, the process proceeds to S22. In S22, the harness alignment order number, hue angle H °, color tone angle T °, color tone length TR, achromatic color flag, and color number (the same as the alignment order number at this point) are stored in the teaching table. The processing from S8 to S24 is repeated for the number of harnesses. Then, in S26, a harness of the same color is searched for in the teaching table, and if found, the color number is re-assigned and the process ends.
Whether or not they are the same color is judged by the above-mentioned color difference ΔE, and if the color difference ΔE is equal to or less than a predetermined threshold value, it is regarded as the same color. (B) Color order determination processing FIG. 2 shows a routine for color order determination. First, the color data of the wire harness and the synchronization signal for performing the color order determination are input (S100) and stored (S102). This is repeated as many times as there are harnesses. Next, as in the case of creating the teaching table, a calculation is performed to detect peaks from the data stored in the memory and select representative data for each harness (S10).
Four). If the peak is detected (YES in S106), the hue angle H °, the hue angle T °, and the hue length T are calculated from the representative data for each harness.
R and saturation C * are calculated (S108). If the obtained saturation C * is larger than the predetermined threshold value (YES in S120), it is determined that the color is chromatic and the achromatic flag is set to 0.
And (S122), the process proceeds to S124. Next, in the same sort order in the teaching table,
Hue angle H °, hue angle T ° and hue length TR determined in S108
Is within the predetermined allowable range (YE in S124, S126, S128)
S), after storing TR (S130), store the color number in the run table (S140). In addition, by setting this tolerance range relatively relatively,
It becomes stronger against fluctuations in light quantity and measurement distance. On the other hand, in S120, if the saturation C * is smaller than the predetermined threshold value (NO), the achromatic color flag is set to 1, and the hue angle H ° and the hue adjustment angle T are set.
Each degree is set to 0 (S134), and it is checked whether the achromatic color flag is 1 in the same alignment order in the teaching table (S136), and if 1 (YES), the process proceeds to S128 and the tone length TR is allowed. Check whether it is within the range. In S124, S126, and S128, the hue angle H °, the hue angle T °, and the hue length TR are not within the allowable range in the same alignment order, or the achromatic flag is 0 in the same alignment order in S136 ( If NO, the color number is set to 0 (S132, S138), indicating that the colors do not match. On the other hand, despite the presence of the sync signal in S106,
If the peak value does not exist (NO), the existence of the harness is checked (S110), and if it exists (YES), the color of the harness is determined to be black, the achromatic color flag is set to 1, and the hue angle is determined. After each of H °, color tone angle T °, color tone length TR, and saturation C * is set to 0 (S112), the process proceeds to S140. If it does not exist (NO in S110), the color number is -1 in S114 as error information.
And move to S140. The above-described processing of S106 to S140 is repeated by the number of harnesses. When the processing for the number of harnesses is performed, in S142, the color tone length TR of each harness is relatively reviewed based on the minimum value of the color tone length TR of the harness in the run table, and the color number is finally determined ( S142). This is because the hue angle H ° and the hue angle T ° are standardized values for the light amount variation of the light source, whereas the hue length TR reflects the light amount variation of the light source, so that the light amount variation is If there is, the value of tone length TR cannot be regarded as an absolute value. Therefore, with the minimum value of the color tone length TR as a reference, the relative difference is taken into consideration and each color number is reviewed and finally determined. (C) Specific Example of Color Order Determination Below, an actual example of color order determination according to the flow of FIGS. 1 and 2 will be shown. Table 1 is an example of a teaching table created by calculating the hue angle, hue angle, and hue length from the R, G, B data of FIG. 7 according to the flow of FIG. 1 and registering them. . In addition, the run table is the first table according to the flow of FIG.
It is created in the same manner as the table, and the color order is determined by checking whether the color numbers in the teaching table match or not. At the time of creating the run table, as described in the flow of FIGS. 1 and 2, an allowable range is set in advance for each of the hue angle, the hue angle, and the hue length of the teaching table (for example, the hue angle). And the color tone angle is ± 15, and the color tone length is about ± 13). If all are within this range, the run table and teaching table have the same color number. Table 2 shows an example of the run table. In the example of Table 2, as indicated by underlining, the color number is originally "9", which is green, and is "0". This is the hue angle H, also shown by the underline
The value of ° is 142, and the difference from the teaching table in Table 1 is 26 (= 168-142), which greatly exceeds the allowable range of ± 15. Second
NO is obtained in S124 of the flow in the figure, and the color number is 0 in S132.
Because it was said. Therefore, since the color numbers of the teaching table in Table 1 and the run table in Table 2 do not all match, the wire harness used to create the run table above matches the wire harness whose color order is the reference. It is determined that it is not. It is needless to say that the present invention is not limited to the above-described embodiments and can be applied to various objects in which the color arrangement order is a problem. (Effects) The present invention effectively uses a color engineering technique and uses hue angle, hue angle, and hue length, which are close to human visual judgments, and uses only the conventional R, G, B light quantity ratios. In the color order determination by, it is possible to accurately determine the color order of many colors that could not be achieved.

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

第1図は、登録処理の概略フローチャートである。 第2図は、色順判定処理の概略フローチャートである。 第3図は、色順判定装置のシステム構成を示すブロック
図である。 第4図は、L*a*b*表色系の立体説明図である。 第5図は、色相ベクトルを示す平面説明図である。 第6図は、色調ベクトルを示す平面説明図である。 第7図は、入力されるR,G,Bデータの一例を示す図であ
る。 第8図は、本発明を応用した色順判定装置の一実施例の
形態を示す外観図である。 1……センサヘッド、3……コントローラ、 7……カラーセンサ、 14A……制御部、14B……データ格納部、 14C……演算部。
FIG. 1 is a schematic flowchart of the registration process. FIG. 2 is a schematic flowchart of the color order determination process. FIG. 3 is a block diagram showing the system configuration of the color order determination apparatus. FIG. 4 is a three-dimensional explanatory diagram of the L * a * b * color system. FIG. 5 is an explanatory plan view showing the hue vector. FIG. 6 is an explanatory plan view showing a color tone vector. FIG. 7 is a diagram showing an example of input R, G, B data. FIG. 8 is an external view showing an embodiment of a color order determination device to which the present invention is applied. 1 ... Sensor head, 3 ... Controller, 7 ... Color sensor, 14A ... Control section, 14B ... Data storage section, 14C ... Calculation section.

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】複数の色が所定の順序で配列された色配列
の色順を検出する色順判定方式であって、 基準となる色配列の各色について、配列された個々の色
をR,G,Bに分解して読み取り、その読取値からL*a*b*
色系における明度指数L*及びクロマチックネス指数a*,b
*をそれぞれ求め、式 によって定義される色相角H°と、式 T°=tan-1{L*/(a*2+b*2)1/2} によって定義される色調角T°と、式 TR=(L*2+a*2+b*2)1/2 によって定義される色調長TRとを、予め計算して、テー
ブルに記憶し、上記複数の色の各色について、配列され
た個々の色をR,G,Bに分解して読み取り、その読取値か
ら上記色相角H°、色調角T°および色調長TRを計算し
て、上記テーブルに記憶された上記基準となる色配列の
各色の色相角、色調角および色調長とそれぞれ比較する
ことによって色順を判定することを特徴とする色順判定
方式。
1. A color order determination method for detecting a color order of a color array in which a plurality of colors are arranged in a predetermined order, wherein each of the arranged individual colors is R, It is separated into G and B and read, and from the read value, the lightness index L * and chromaticness index a * , b in the L * a * b * color system.
Calculate each * and formula And the hue angle H ° defined by the formula T ° = tan −1 {L * / (a * 2 + b * 2 ) 1/2 } and the formula TR = (L * 2 + a * 2 + b * 2 ) 1/2 , and the tone length TR defined by 1/2 is calculated in advance and stored in a table, and for each color of the above plurality of colors, the individual colors arranged are R, G and B are separated and read, and the hue angle H °, the hue angle T ° and the hue length TR are calculated from the read values, and the hue angle of each color of the reference color array stored in the table, A color order determination method characterized by determining a color order by comparing with a color tone angle and a color tone length, respectively.
【請求項2】複数の色が所定の順序で配列された色配列
の色順を検出する色順判定方式であって、 基準となる色配列の各色について、配列された個々の色
をR,G,Bに分解して読み取り、その読取値からL*a*b*
色系における明度指数L*及びクロマチックネス指数a*,b
*をそれぞれ求め、式 によって定義される色相角H°と、式 T°=tan-1{L*/(a*2+b*2)1/2} によって定義される色調角T°と、式 TR=(L*2+a*2+b*2)1/2 によって定義される色調長TRとを、予め計算して、読み
取った各色のうち黒色の場合は、色相角H°、色調角T
°、色調長TRをそれぞれ0としてテーブルに記憶し、 上記複数の色の各色について、配列された個々の色をR,
G,Bに分解して読み取り、その読取値から上記色相角H
°、色調角T°および色調長TRを計算して、黒色の場合
は色相角H°、色調角T°、色調長TRをそれぞれ0とし
て、上記テーブルに記憶された上記基準となる色配列の
各色の色相角、色調角および色調長とそれぞれ比較する
ことによって色順を判定することを特徴とする色順判定
方式。
2. A color order determination method for detecting a color order of a color array in which a plurality of colors are arranged in a predetermined order, wherein each of the arranged individual colors is R, It is separated into G and B and read, and from the read value, the lightness index L * and chromaticness index a * , b in the L * a * b * color system.
Calculate each * and formula And the hue angle H ° defined by the formula T ° = tan −1 {L * / (a * 2 + b * 2 ) 1/2 } and the formula TR = (L * 2 + a * 2 + b * 2 ) 1/2 and the hue length TR defined by 1/2 are calculated in advance, and if the read color is black, the hue angle H ° and the hue angle T
°, and store the tone length TR in the table as 0 respectively, and for each color of the above multiple colors, the arranged individual colors are R,
G and B are separated and read, and from the read value, the hue angle H
°, the hue angle T ° and the hue length TR are calculated, and in the case of black, the hue angle H °, the hue angle T ° and the hue length TR are each set to 0, and the reference color array stored in the table is stored. A color order determination method characterized in that the color order is determined by comparing the hue angle, the hue angle, and the hue length of each color.
JP63227184A 1988-09-10 1988-09-10 Color order determination method Expired - Lifetime JPH0670590B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP63227184A JPH0670590B2 (en) 1988-09-10 1988-09-10 Color order determination method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP63227184A JPH0670590B2 (en) 1988-09-10 1988-09-10 Color order determination method

Publications (2)

Publication Number Publication Date
JPH0274832A JPH0274832A (en) 1990-03-14
JPH0670590B2 true JPH0670590B2 (en) 1994-09-07

Family

ID=16856806

Family Applications (1)

Application Number Title Priority Date Filing Date
JP63227184A Expired - Lifetime JPH0670590B2 (en) 1988-09-10 1988-09-10 Color order determination method

Country Status (1)

Country Link
JP (1) JPH0670590B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0792401B2 (en) * 1992-02-04 1995-10-09 倉敷紡績株式会社 Color image extraction device
DE4345106C2 (en) * 1993-12-28 1995-11-23 Reemtsma H F & Ph Process for the optical sorting of bulk goods
GB201510652D0 (en) * 2015-06-17 2015-07-29 Beers Uk De Ltd Colour measurement of gemstones

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58112326A (en) * 1981-12-26 1983-07-04 Fujitsu Ltd Rrocess of annealing by compound beams
JPS6092607A (en) * 1983-10-27 1985-05-24 Agency Of Ind Science & Technol Electron beam annealing device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58112326A (en) * 1981-12-26 1983-07-04 Fujitsu Ltd Rrocess of annealing by compound beams
JPS6092607A (en) * 1983-10-27 1985-05-24 Agency Of Ind Science & Technol Electron beam annealing device

Also Published As

Publication number Publication date
JPH0274832A (en) 1990-03-14

Similar Documents

Publication Publication Date Title
US5703960A (en) Lumber defect scanning including multi-dimensional pattern recognition
US7304663B2 (en) Image test target for visual determination of digital image resolution
US7462827B2 (en) Non-destructive inspection method and apparatus therefor
US7215807B2 (en) Nondestructive inspection method and apparatus
US4812904A (en) Optical color analysis process
CN102422328B (en) Method for a banknote detector device, and a banknote detector device
US6064478A (en) Method of and apparatus for automatic detection of three-dimensional defects in moving surfaces by means of color vision systems
JPH05232030A (en) Apparatus and method for non-contact type survey and inspection for color label
CN113109240B (en) Method and system for determining imperfect grains of grains implemented by computer
JPH0670590B2 (en) Color order determination method
CN117152461A (en) Cigarette packaging material color difference detection method based on digital image
US7732217B2 (en) Apparatus and method for reading fluorescence from bead arrays
JPS63163150A (en) Printed circuit board inspecting device
JP2000121499A (en) Method and apparatus for measuring internal refractive index distribution of optical fiber base material
US6826307B1 (en) Contrast determining apparatus and methods
JPH09329495A (en) Color evaluation method and device therefor
JP2841200B2 (en) Array pattern inspection device
CA1196725A (en) Image measuring system
JPH0781962B2 (en) Foreign object detection method
JP2001194316A (en) Method and device for non-destructive inspection
JPH0334801B2 (en)
JPH069283Y2 (en) Display element segment position deviation detection device
KR100436294B1 (en) A search method of pattern block in machine vision
JPH07239309A (en) Device for detecting abnormal part of parallel line pattern
JPH0949715A (en) Method and apparatus for visual inspection of semiconductor package

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070907

Year of fee payment: 13

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080907

Year of fee payment: 14

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080907

Year of fee payment: 14

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090907

Year of fee payment: 15

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090907

Year of fee payment: 15