JP5029545B2 - Image processing method and apparatus - Google Patents
Image processing method and apparatus Download PDFInfo
- Publication number
- JP5029545B2 JP5029545B2 JP2008231772A JP2008231772A JP5029545B2 JP 5029545 B2 JP5029545 B2 JP 5029545B2 JP 2008231772 A JP2008231772 A JP 2008231772A JP 2008231772 A JP2008231772 A JP 2008231772A JP 5029545 B2 JP5029545 B2 JP 5029545B2
- Authority
- JP
- Japan
- Prior art keywords
- image
- face
- skin
- pixels
- size
- 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 - Fee Related
Links
- 238000003672 processing method Methods 0.000 title claims description 13
- 238000012545 processing Methods 0.000 claims description 46
- 239000011159 matrix material Substances 0.000 claims description 36
- 238000000034 method Methods 0.000 claims description 35
- 238000001914 filtration Methods 0.000 claims description 24
- 238000004364 calculation method Methods 0.000 claims description 20
- 238000009499 grossing Methods 0.000 claims description 16
- 238000000605 extraction Methods 0.000 claims description 6
- 239000004575 stone Substances 0.000 claims description 6
- 230000010354 integration Effects 0.000 claims description 4
- 239000000284 extract Substances 0.000 claims 1
- 238000004513 sizing Methods 0.000 claims 1
- 238000010586 diagram Methods 0.000 description 12
- 230000000694 effects Effects 0.000 description 11
- 238000001514 detection method Methods 0.000 description 10
- 238000013500 data storage Methods 0.000 description 6
- 230000006870 function Effects 0.000 description 5
- 230000037303 wrinkles Effects 0.000 description 5
- 230000006866 deterioration Effects 0.000 description 2
- 230000003252 repetitive effect Effects 0.000 description 2
- 230000000007 visual effect Effects 0.000 description 2
- 238000012935 Averaging Methods 0.000 description 1
- 230000015556 catabolic process Effects 0.000 description 1
- 238000006731 degradation reaction Methods 0.000 description 1
- 238000002474 experimental method Methods 0.000 description 1
- 238000003384 imaging method Methods 0.000 description 1
- 238000012905 input function Methods 0.000 description 1
- 210000000088 lip Anatomy 0.000 description 1
- 238000003909 pattern recognition Methods 0.000 description 1
- 230000036548 skin texture Effects 0.000 description 1
Images
Description
本発明は、コンピュータを用いた画像処理技術に関し、特に人物の顔画像の肌部分に現れるシワやシミを目立たなくなるよう補正する、いわゆる「美肌」効果を目的とする画像処理技術に関する。 The present invention relates to an image processing technique using a computer, and more particularly, to an image processing technique aiming at a so-called “skin-beautifying” effect that corrects wrinkles and spots appearing on a skin portion of a human face image so as to be inconspicuous.
写真画像をデジタルデータとしてコンピュータに取り込み、コンピュータ上で画像に対する種々の加工処理を施すフォトレタッチ技術は、様々な分野で利用されている。中でも、人物の顔画像の肌の質感向上への要求は大きく、シワ、シミ等の「美観を損なう」不要部分を除去あるいは軽減する試みは、静止画から動画に至るまで従来から広く行なわれている。最近では、コンピュータの性能向上に伴い、個人レベルでも、パソコンを用いて写真画像に対する種々のレタッチ処理を施すことができるようになっている。 A photo retouch technique that takes a photographic image as digital data into a computer and performs various processing on the image on the computer is used in various fields. In particular, there is a great demand for improving the skin texture of human face images, and attempts to remove or reduce unnecessary parts such as wrinkles and spots that impair the aesthetics have been widely conducted from still images to movies. Yes. Recently, along with the improvement in computer performance, various retouch processes can be applied to photographic images using a personal computer even at an individual level.
このような不要部分を効果的に軽減、除去する、いわゆるスムージング処理のための画像処理手法として、ε-フィルタやMTMフィルタなどが知られている。
これらのフィルタは、平均値フィルタの一種であり、本来は小振幅の高周波雑音成分の除去を目的としたものであるが、顔画像のような画像信号に適用した場合は、エッジなどの境界情報を保存しながらシワなどの不要部分(小振幅信号)を除去できるため、特に、仕上がり品質が重視される証明写真のような用途には好適である。
例えば、特許文献1には、大小異なる閾値を用いたε-フィルタによる「肌つる」化に関する技術を開示し、特許文献2では、画像データのノイズ除去法として、信号処理の観点からMTMフィルタを含む各種二次元フィルタの特性を論じている。
These filters are a kind of average value filter and originally intended to remove high-frequency noise components with small amplitudes, but when applied to image signals such as face images, boundary information such as edges Since unnecessary portions (small amplitude signals) such as wrinkles can be removed while preserving the image, it is particularly suitable for applications such as ID photos where the finished quality is important.
For example,
また、顔画像のスムージング処理にあたっては、目、口唇や頭髪のディテールが損なわれないよう、肌部分のみにスムージング処理を施すことが望ましく、顔の肌部分であることを示す肌領域マスクに従い、肌部分のみに処理が施される例が多い。このように顔画像の中から肌色の領域を認識し肌領域マスクを生成する手法は、例えば、本発明と同一の出願人による特許文献3に開示されている。
しかしながら、このような「美肌」機能を実用しようとした場合、以下に述べるような問題が生じる。
例えば、証明写真に適用すると、証明写真の仕上がりサイズは用途により大きく変わるため、画像データのサイズも大きく変化することになる。加えて、フレーム内での顔サイズも撮影距離等で変化するため、画像データ上での顔画像のサイズは大きな変動幅を持つことになる。
このようにサイズの範囲が広い顔画像データに一様なサイズの二次元フィルタを作用させても望む効果は得られず、フィルタによるスムージング効果に大きなバラツキが生じることとなる。そこで、顔の大きさによらずに安定したスムージング効果を得るためには、画像データの顔サイズに応じて二次元フィルタのサイズを変化させることが必要となる。
However, when such a “skin-beautifying” function is to be put into practical use, the following problems arise.
For example, when applied to an ID photo, the size of the ID photo varies greatly depending on the application, and the size of the image data also changes greatly. In addition, since the face size in the frame also changes depending on the shooting distance, the size of the face image on the image data has a large fluctuation range.
In this way, even if a two-dimensional filter having a uniform size is applied to face image data having a wide size range, a desired effect cannot be obtained, and a large variation occurs in the smoothing effect by the filter. Therefore, in order to obtain a stable smoothing effect regardless of the size of the face, it is necessary to change the size of the two-dimensional filter according to the face size of the image data.
一方、顔画像サイズが大きくなると二次元フィルタのサイズも大きくなるが、各画素の演算時間は二次元フィルタの面積比で増大するため、顔画像が大きくなるにつれ、フィルタリング処理の演算時間が著しく増大するという新たな問題が生じる。これに対しては、フィルタリング処理の際に、画素を間引くことにより演算量を縮減するなどの手法が考えられるが、反面、これによる画質劣化や疑似ノイズの発生など別の問題も生じる。 On the other hand, as the face image size increases, the size of the two-dimensional filter also increases. However, the calculation time of each pixel increases with the area ratio of the two-dimensional filter, so that the calculation time of filtering processing significantly increases as the face image increases. A new problem arises. For this, a method of reducing the amount of calculation by thinning out pixels in the filtering process can be considered, but on the other hand, other problems such as image quality degradation and generation of pseudo noise occur.
そこで本発明は、取り込まれた顔画像のサイズの大小にかかわらず、均質なスムージング効果が得られるとともに、大サイズの顔画像であっても、品質劣化が少なく、かつ高速にて処理可能であるような画像処理方法および装置を提供することを目的とする。 Therefore, the present invention can obtain a uniform smoothing effect regardless of the size of the captured face image, and can be processed at high speed with little quality deterioration even for a large-sized face image. An object of the present invention is to provide such an image processing method and apparatus.
上記課題を解決する本発明の画像処理方法は、人物の顔画像を表わす画像信号の肌部に現れるシミ、シワ、キズなどの不要画像を修整する美肌化を目的とするものであり、人物の顔を含む画像データをコンピュータに入力する人物画像入力段階と、前記人物画像から顔領域を特定し、この顔領域から肌部を抽出し肌領域を示す肌領域マスクデータを生成する肌領域抽出段階と、前記肌領域マスクデータに基き、肌領域にある各画素に正方配列の二次元マトリクスによるフィルタリング処理を施すスムージング処理段階と、
を有する、顔画像の不要画像部分を修正する画像処理方法であって、
前記スムージング処理段階は、顔の実寸の寸法を指定する顔実寸法設定ステップと、前記不要画像部分の実物上での寸法を指定する不要画像実寸法設定ステップと、前記不要画像実寸法を前記顔実寸法で除した値と、前記顔領域から得られる顔画像の画素数とを積算し、この積算結果に最も近い奇数値を前記二次元マトリクスの一辺の画素数として定めるマトリクスサイズ決定ステップとを含むことを特徴とする。
The image processing method of the present invention that solves the above-described problems is intended to beautify the skin by correcting unwanted images such as spots, wrinkles, and scratches that appear on the skin of the image signal representing the face image of a person. A person image input stage for inputting image data including a face to a computer, and a skin area extraction stage for identifying a face area from the person image, extracting a skin part from the face area, and generating skin area mask data indicating the skin area And, based on the skin area mask data, performing a filtering process by a two-dimensional matrix of a square array on each pixel in the skin area, and
An image processing method for correcting an unnecessary image portion of a face image, comprising:
The smoothing processing step includes a face actual dimension setting step for designating an actual size of a face, an unnecessary image actual dimension setting step for designating an actual size of the unnecessary image portion, and the unnecessary image actual dimension as the face. Matrix size determination step of integrating the value divided by the actual size and the number of pixels of the face image obtained from the face area, and determining an odd value closest to the integration result as the number of pixels on one side of the two-dimensional matrix It is characterized by including.
また、前記二次元マトリクスの一辺の画素数が5以上の場合、フィルタリング処理で用いる演算対象画素を、飛び石状に間引いて選択することを特徴としている。 Further, when the number of pixels on one side of the two-dimensional matrix is 5 or more, the calculation target pixels used in the filtering process are selected by thinning out in a stepping stone shape.
さらに、前記フィルタリング処理で用いる演算対象画素を、前記二次元マトリクスの中心にある着目画素に対し、同着目画像を中心に同心円状に選定することを特徴としている。 Further, the calculation target pixel used in the filtering process is selected concentrically with respect to the target pixel at the center of the two-dimensional matrix with the same target image as the center.
本件第2の発明は、
人物の顔を含む画像データをコンピュータに入力する人物画像入力手段と、前記人物画像から顔領域を特定し、この顔領域から肌部を抽出し肌領域を示す肌領域マスクデータを生成する肌領域抽出手段と、前記肌領域マスクデータに基き、肌領域にある各画素に正方配列の二次元マトリクスによるフィルタリング処理を施すスムージング処理手段と、前記フィルタリング処理の対象とする不要画像部分の実物上での寸法を設定する不要画像実寸法入力手段と、予め設定された平均的顔サイズの寸法で前記不要画像実寸法を除した値と、前記顔領域から得られる顔画像の画素数とを積算し、この積算結果に最も近い奇数値を前記二次元マトリクスの一辺の画素数として定めるマトリクスサイズ決定手段と、
を備えることを特徴とする画像処理装置にある。
The second invention of the present invention is
Human image input means for inputting image data including a person's face to a computer, and a skin area for specifying a face area from the person image, extracting a skin from the face area, and generating skin area mask data indicating the skin area Extraction means, smoothing processing means for performing filtering processing by a two-dimensional matrix of a square array on each pixel in the skin region based on the skin region mask data, and an unnecessary image portion to be subjected to the filtering processing on the real object An unnecessary image actual dimension input means for setting a dimension, a value obtained by dividing the unnecessary image actual dimension by a preset average face size dimension, and the number of pixels of the face image obtained from the face area; Matrix size determining means for determining an odd value closest to the integration result as the number of pixels on one side of the two-dimensional matrix;
An image processing apparatus comprising:
ここで、前記二次元マトリクスの一辺の画素数が5以上の場合、フィルタリング処理で用いる演算対象画素を、飛び石状に間引いて選択することを特徴とする。 Here, when the number of pixels on one side of the two-dimensional matrix is five or more, the calculation target pixels used in the filtering process are selected by thinning out in a stepping stone shape.
また、前記フィルタリング処理で用いる演算対象画素を、前記二次元マトリクスの中心にある着目画素に対し、同着目画像を中心に同心円状に選定することを特徴とする。 Further, the calculation target pixel used in the filtering process is selected concentrically with respect to the target pixel at the center of the two-dimensional matrix, centering on the target image.
本発明の画像処理方法および装置によれば、処理対象となる顔画像データに対し、その顔画像のサイズに応じたサイズの二次元マトリクスを得ることにより、顔画像のサイズによらず一定のフィルタリング効果を得ることができ、また、フィルタリング処理における演算対象画素を同心円状に配すことにより、画質劣化が少なく高速な処理を実現することができる。 According to the image processing method and apparatus of the present invention, by obtaining a two-dimensional matrix having a size corresponding to the size of the face image data to be processed, constant filtering regardless of the size of the face image. The effect can be obtained, and the processing target pixels in the filtering process are arranged concentrically, so that high-speed processing with little image quality deterioration can be realized.
以下、本発明の実施形態について、図面を参照しながら説明する。
図1は本発明の画像処理方法の機能ブロック図、図2はこれをコンピュータ処理で実現した場合のハードウェア構成例を示す。
図3は本発明の画像処理の処理フローを示す図、図4は肌領域マスクを生成する過程を示す図、図5は顔サイズと二次元マトリクスの関係を示す図、図6はMTMフィルタの原理を示す図、図7は二次元マトリクスと間引きパターンの関係を示す図である。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is a functional block diagram of an image processing method of the present invention, and FIG. 2 shows an example of a hardware configuration when this is realized by computer processing.
FIG. 3 is a diagram illustrating a processing flow of image processing according to the present invention, FIG. 4 is a diagram illustrating a process of generating a skin region mask, FIG. 5 is a diagram illustrating a relationship between a face size and a two-dimensional matrix, and FIG. FIG. 7 is a diagram showing the principle, and FIG. 7 is a diagram showing the relationship between a two-dimensional matrix and a thinning pattern.
図1の操作部21は、図2のモニタ4から視覚情報を得ながら、キーボード6、マウス7を用いて本発明の画像処理に関する指示を与えるためのものである。また処理部20はデータ格納部27にあるデータやパラメータを参照し画像処理を行なうことを示し、本発明の画像処理で用いる画像入力機能22、肌領域抽出機能23、スムージング処理機能24、画像出力機能25などから構成される。I/O外部接続部は、主に画像データの入出力のためのものであり、例えば、入力の場合は、データ格納メディアやデジタル撮像機器などが接続され、また、出力の場合は、データ格納メディアの他にプリンタなどが接続されることを想定している。
The
図3は本発明のスムージング処理にかかわる詳細フローを表わす。
まず、画像入力段階(S11)でコンピュータに入力された人物画像は、顔検出処理により顔部が特定される。顔検出のための手法は種々あるが図3に示すフローでは「Haar−like特徴」を用いている。
Haar−like特徴を用いた物体検出手法は、検出対象となる物体の明暗のパターンを基に、高速に識別を行うことを特徴とし、静止画や動画像中における顔検出などに利用されている。特に、証明写真のような正面、無帽の人物像に対しては高い検出精度を発揮する。Haar−like特徴を用いた顔の検出結果は、目・鼻・口などといった顔の局所情報と、顔の中心、サイズなどの情報を含んだ領域として表わされる。
FIG. 3 shows a detailed flow relating to the smoothing processing of the present invention.
First, the face portion of the person image input to the computer in the image input stage (S11) is specified by face detection processing. There are various methods for face detection, but the “Haar-like feature” is used in the flow shown in FIG.
The object detection method using the Haar-like feature is characterized in that identification is performed at high speed based on a light / dark pattern of an object to be detected, and is used for face detection in still images and moving images. . In particular, high detection accuracy is exhibited for a frontal, hatless person image such as an ID photo. A face detection result using the Haar-like feature is represented as an area including local information of the face such as eyes, nose, and mouth, and information such as the center and size of the face.
なお、Haar−like特徴による対象物検出の原理、顔検出への適用例などについては、下記の文献(非特許文献1、非特許文献2)に紹介されている。
また、Haar−like特徴を用い、画像中から顔を特定し、顔のサイズや位置を取得する手法は、既に画像処理のライブラリとして提供されており(Intel社が開発、公開しているOpenCVライブラリ)、これらを利用し顔の領域を表わす顔矩形領域を導くことは容易である。図4(2)に示す顔矩形領域42は、Haar−like特徴およびOpenCVを用いて得られた顔領域を図示したものであり、同顔矩形領域は処理画像中の顔の位置(中心)と大きさ(顔の幅および高さ)を表わしている。 In addition, a method for identifying a face from an image and acquiring a face size and position using Haar-like features has already been provided as an image processing library (OpenCV library developed and published by Intel). ), It is easy to derive a face rectangular area representing the face area by using these. A face rectangular area 42 shown in FIG. 4B is a face area obtained by using the Haar-like feature and OpenCV, and the face rectangular area indicates the position (center) of the face in the processed image. It represents the size (width and height of the face).
このように顔部が特定されると、顔の平均的肌色を示す部位の色を参照し顔の肌部を抽出するといった肌領域検出が可能となる。本発明では、特許文献3に開示される人物の肌領域抽出の方法およびマスクデータの作成方法を用いてマスクデータ生成を行なうこととしている(S13)。肌領域抽出により生成されたマスクデータの様態を図4(3)に示す。 When the face portion is specified in this way, it is possible to detect a skin region in which the skin portion of the face is extracted with reference to the color of the part indicating the average skin color of the face. In the present invention, mask data generation is performed using the method of extracting a human skin region and the method of creating mask data disclosed in Patent Document 3 (S13). The mode of the mask data generated by the skin region extraction is shown in FIG.
一方、前記Haar−like特徴による顔矩形領域から得られる顔の巾方向の大きさ(画素数)と、別途設定される顔の実寸法(S14)および不要画像実寸法(S15)により画像データ上でのフィルタの画素数であるマトリクスサイズ(一辺の画素数)を決定することができる(S16)。
なお、顔の実寸法は個人毎に測る必要はなく、図1の構成では、予めデータとして、例えば平均的日本人の顔のサイズ170ミリメートルという値が、データ格納部27に格納されている(顔実寸法273)。また、不要画像実寸法とは、シミ、シワなどの修整したい不要部分の大きさであり、前記顔の実寸法と単位を合わせミリメートル単位で測った数値を設定するが、この大きさの設定方法としては、図2のキーボード6から入力してもよいし、いくつかの大きさの中からマウス7で選択することも可能である。
On the other hand, the size of the face in the width direction (number of pixels) obtained from the face rectangular area based on the Haar-like feature, the actual face dimensions (S14) and unnecessary image actual dimensions (S15) set separately, The matrix size (the number of pixels on one side), which is the number of pixels of the filter, can be determined (S16).
Note that the actual face size need not be measured for each individual, and in the configuration of FIG. 1, for example, a value of an average Japanese face size of 170 mm is stored in the
フィルタのマトリクスサイズの算出は、
a=L×M/F
(ただし、Lは画像データ上の顔サイズすなわち顔矩形領域の巾方向の画素数、
Mは不要画像実寸法、
Fは顔の実寸法)
の計算式に基き、さらにここから得たaに最も近い奇数値とすることにより得られる。この値をAとすると、Aは、
A=INT(a/2+1)*2−1
(ただし、INTは小数点以下切り捨て型整数化を表わす演算子)
のような計算式で表わすことができる。
これにより、マトリクスサイズAは、入力された画像データの顔サイズに応じて変化することになるため、顔画像データのサイズや画素密度によらず一定したフィルタリング効果を得ることができる。
図5(イ)に人物の顔上での不要部分の様態、図5(ロ)(ハ)に顔画像上でのマトリクスサイズの様子を示す。(ロ)は顔画像が小サイズの場合、(ハ)は顔画像が大サイズの場合を示すが、図中のA、A’は顔画像の大小に応じてマトリクスサイズAも変化する様子を表わす。
To calculate the filter matrix size,
a = L × M / F
(Where L is the face size on the image data, that is, the number of pixels in the width direction of the face rectangular area,
M is the unnecessary image actual size,
F is the actual size of the face)
Is obtained by setting the odd value closest to a obtained here. If this value is A, then A
A = INT (a / 2 + 1) * 2-1
(However, INT is an operator that represents a rounded-down integer type)
It can be expressed by the following formula.
Thereby, since the matrix size A changes according to the face size of the input image data, a constant filtering effect can be obtained regardless of the size of the face image data and the pixel density.
FIG. 5 (a) shows a state of an unnecessary portion on the face of a person, and FIGS. 5 (b) and 5 (c) show a matrix size on the face image. (B) shows a case where the face image is a small size, and (C) shows a case where the face image is a large size, A and A ′ in the figure show how the matrix size A changes depending on the size of the face image. Represent.
上記より得たマトリクスサイズAの大きさのフィルタを用い、肌領域抽出(S13)で得た肌領域マスクデータを参照しながらフィルタリング処理(S17)を行なうが、ここではMTMフィルタを例にフィルタリング処理を説明する。
MTMフィルタは、基本は平均化フィルタであるが、着目画素と近傍の画素とを比較しその差分について、差分が小さい場合は着目画素と近傍画素との相関が強いとし、この近傍画素を演算対象に取り入れ、逆に差分が大きい場合は、演算対象から除外すことで、小振幅信号に対し重点的にフィルタ効果を作用させるものである。図6にMTMフィルタの原理を示す。
Using the filter of the matrix size A obtained above, the filtering process (S17) is performed with reference to the skin area mask data obtained in the skin area extraction (S13). Here, the filtering process is performed using the MTM filter as an example. Will be explained.
The MTM filter is basically an averaging filter, but the target pixel and the neighboring pixels are compared. If the difference is small, the correlation between the target pixel and the neighboring pixels is strong, and this neighboring pixel is calculated. In contrast, when the difference is large, the filter effect is focused on the small amplitude signal by excluding it from the calculation target. FIG. 6 shows the principle of the MTM filter.
一方、このようなフィルタリング処理における演算量はフィルタのサイズに依存するため、二次元マトリクスの一辺の画素数が増加するにつれ演算量は面積比で増加することになり、処理時間の著しい増大を招く。
処理時間の増大を避けるためには、フィルタリング処理時に処理対象画素を間引くことにより演算量を減少させることが望ましい。そこで本発明では、フィルタの二次元マトリクス上に演算対象とする画素のパターンを予め設定しておき、設定された画素以外は計算対象から外すことで演算量の減少、すなわち演算の高速化を実現している。
図7は二次元マトリクス上の間引きパターンの例であり、(A)は縦横の格子状のパターン、(B)は千鳥格子状のパターンを示す。なお、二次元マトリクスの一辺の画素数が3以下では間引きの効果は得られず、一辺の画素数が5以上で有効となる。
On the other hand, since the amount of computation in such filtering processing depends on the size of the filter, the amount of computation increases with the area ratio as the number of pixels on one side of the two-dimensional matrix increases, resulting in a significant increase in processing time. .
In order to avoid an increase in processing time, it is desirable to reduce the amount of calculation by thinning out the processing target pixels during the filtering process. Therefore, in the present invention, a pixel pattern to be calculated is set in advance on the two-dimensional matrix of the filter, and the calculation amount is reduced, that is, the calculation speed is increased by excluding the set pixels from the calculation target. is doing.
FIG. 7 shows an example of a thinning pattern on a two-dimensional matrix, where (A) shows a vertical and horizontal grid pattern, and (B) shows a staggered pattern. Note that the thinning effect cannot be obtained when the number of pixels on one side of the two-dimensional matrix is 3 or less, and is effective when the number of pixels on one side is 5 or more.
例えば図7(A)の例では、二次元マトリクスのサイズは7×7であり、着目画素61を中心とした近傍画素の数は48画素となるが、演算対象画素62を飛び石状に選定することにより演算対象画素の合計数を8画素まで縮減させている。この結果、画素ごとの繰り返し演算にかかわる処理時間が大幅に短縮でき、スムージング処理全体の処理時間短縮を達成した。 For example, in the example of FIG. 7A, the size of the two-dimensional matrix is 7 × 7 and the number of neighboring pixels centering on the pixel of interest 61 is 48 pixels, but the calculation target pixel 62 is selected in a stepping stone shape. As a result, the total number of calculation target pixels is reduced to 8 pixels. As a result, the processing time for the repetitive calculation for each pixel can be greatly shortened, and the processing time of the entire smoothing process can be shortened.
ところが、上記(A)、(B)の飛び石状パターンように規則性の繰り返しがあるパターンでは、このパターンと処理対象とする元画像に含まれるパターンとが干渉し、フィルタリング結果に干渉縞等の副次的文様が現れるといった副作用を生じることがある。例えば、肌部にかかった髪の毛のような線状の像に対しては、この部分に濃淡のパターンが残ることがある。
このような副作用を避けるには、間引きパターンから規則性をなくすのが有効であり、実験の結果、演算対象とする画素を図7(C)に示すような同心円状に配したパターンがより望ましいとの結果を得た。
However, in a pattern with repetitive regularity such as the stepping stone pattern of (A) and (B) above, this pattern interferes with the pattern included in the original image to be processed, and the filtering result includes interference fringes and the like. Side effects such as the appearance of secondary patterns may occur. For example, with respect to a linear image such as hair on the skin portion, a shading pattern may remain in this portion.
In order to avoid such a side effect, it is effective to eliminate regularity from the thinning pattern. As a result of the experiment, a pattern in which the pixels to be calculated are arranged in a concentric circle as shown in FIG. 7C is more desirable. And got the result.
このようにスムージング処理を施した結果は、画像出力(S18)としてデータ記録媒体(CD、DVD)やプリンタに出力することができる。 The result of the smoothing process can be output to a data recording medium (CD, DVD) or printer as an image output (S18).
図2は、本発明の画像処理方法をコンピュータ処理で実現した時のハードウェア構成例である。画像処理装置1は、バス9を介して接続されるCPU2、メモリ3、モニタ4、I/O5、キーボード6、マウス7とハードディスク8などで構成される。
メモリ3は、CPU2がプログラム82を実行する際に、実行すべきプログラムや一時的作業データを格納するデータ記憶場所である。
モニタ4は、視覚情報を表示する表示装置であり、キーボード6およびマウス7は、操作者による情報入力や指示を受け付け、その信号をCPUに伝達する入力装置である。
I/O5は外部との接続に関する接続口を表わし、例えば、デジタルカメラ、CD、DVDなどの外部機器、あるいはネットワークを介してプリンタや他のシステムと接続される。
ハードディスク8には、本システムが扱う対象とする情報からなるデータ81、図3のスムージング処理フローの各ステップを実行する画像処理プログラムを始め、CPUが実行するプログラム82、本システムがコンピュータとして機能するための基盤ソフトウェアであるOS83などが格納される。
また、上記の画像処理や入出力の制御は図2のCPU2がプログラム82を実行することにより実現される。
FIG. 2 is a hardware configuration example when the image processing method of the present invention is realized by computer processing. The
The
The
I /
The
Further, the above-described image processing and input / output control are realized by the
1 画像処理装置
2 CPU
3 メモリ
4 モニタ
5 I/O
6 キーボード
7 マウス
8 ハードディスク
20 処理部
21 操作部
27 データ格納部
42 顔矩形領域
43 肌領域マスク
61 着目画素
62 演算対象画素
1
3
6 keyboard 7
Claims (6)
前記人物画像から顔領域を特定し、この顔領域から肌部を抽出し肌領域を示す肌領域マスクデータを生成する肌領域抽出段階と、
前記肌領域マスクデータに基き、肌領域にある各画素に正方配列の二次元マトリクスによるフィルタリング処理を施すスムージング処理段階と、
を有する、顔画像の不要画像部分を修正する画像処理方法であって、
前記スムージング処理段階は、顔の実寸の寸法を指定する顔実寸法設定ステップと、
前記不要画像部分の実物上での寸法を指定する不要画像実寸法設定ステップと、
前記不要画像実寸法を前記顔実寸法で除した値と、前記顔領域から得られる顔画像の画素数とを積算し、この積算結果に最も近い奇数値を前記二次元マトリクスの一辺の画素数として定めるマトリクスサイズ決定ステップと、
を含むことを特徴とする画像処理方法。 A human image input stage for inputting image data including a human face to a computer;
A skin area extraction step of identifying a face area from the person image, extracting a skin portion from the face area, and generating skin area mask data indicating the skin area;
Based on the skin region mask data, a smoothing processing step of performing filtering processing with a two-dimensional matrix of a square array on each pixel in the skin region;
An image processing method for correcting an unnecessary image portion of a face image, comprising:
The smoothing processing step includes an actual face dimension setting step for designating an actual face dimension,
An unnecessary image actual dimension setting step for designating the dimension of the unnecessary image part on the actual object;
The value obtained by dividing the unnecessary actual image size by the actual face size is integrated with the number of pixels of the face image obtained from the face area, and the odd value closest to the integration result is the number of pixels on one side of the two-dimensional matrix. A matrix sizing step defined as:
An image processing method comprising:
前記人物画像から顔領域を特定し、この顔領域から肌部を抽出し肌領域を示す肌領域マスクデータを生成する肌領域抽出手段と、
前記肌領域マスクデータに基き、肌領域にある各画素に正方配列の二次元マトリクスによるフィルタリング処理を施すスムージング処理手段と、
前記フィルタリング処理の対象とする不要画像部分の実物上での寸法を設定する不要画像実寸法入力手段と、
予め設定された平均的顔サイズの寸法で前記不要画像実寸法を除した値と、前記顔領域から得られる顔画像の画素数とを積算し、この積算結果に最も近い奇数値を前記二次元マトリクスの一辺の画素数として定めるマトリクスサイズ決定手段と、
を備えることを特徴とする画像処理装置。 Person image input means for inputting image data including a person's face to a computer;
A skin area extracting unit that identifies a face area from the person image, extracts a skin portion from the face area, and generates skin area mask data indicating the skin area;
Based on the skin area mask data, smoothing processing means for applying a filtering process with a square array of two-dimensional matrix to each pixel in the skin area;
Unnecessary image actual dimension input means for setting the actual dimension of the unnecessary image portion to be subjected to the filtering process;
A value obtained by dividing the unnecessary image actual size by a predetermined average face size and the number of pixels of the face image obtained from the face area are integrated, and an odd value closest to the integration result is calculated as the two-dimensional value. Matrix size determining means defined as the number of pixels on one side of the matrix;
An image processing apparatus comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008231772A JP5029545B2 (en) | 2008-09-10 | 2008-09-10 | Image processing method and apparatus |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008231772A JP5029545B2 (en) | 2008-09-10 | 2008-09-10 | Image processing method and apparatus |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2010066943A JP2010066943A (en) | 2010-03-25 |
JP5029545B2 true JP5029545B2 (en) | 2012-09-19 |
Family
ID=42192486
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008231772A Expired - Fee Related JP5029545B2 (en) | 2008-09-10 | 2008-09-10 | Image processing method and apparatus |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5029545B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5810384B2 (en) * | 2011-05-11 | 2015-11-11 | 学校法人明治大学 | Face image processing system, face image processing method, and face image processing program |
JP5174223B2 (en) * | 2011-08-31 | 2013-04-03 | 株式会社東芝 | Object search device, video display device, and object search method |
JP6307873B2 (en) * | 2013-12-24 | 2018-04-11 | 富士通株式会社 | Object line detection apparatus, method, and program |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3252422B2 (en) * | 1991-12-28 | 2002-02-04 | ソニー株式会社 | Image processing device |
JP3319727B2 (en) * | 1999-10-20 | 2002-09-03 | 日本放送協会 | Image processing device |
JP2007243634A (en) * | 2006-03-09 | 2007-09-20 | Seiko Epson Corp | Image generating apparatus and photographing method of same |
JP5354842B2 (en) * | 2006-05-26 | 2013-11-27 | キヤノン株式会社 | Image processing method and image processing apparatus |
JP4353234B2 (en) * | 2006-10-31 | 2009-10-28 | ブラザー工業株式会社 | Image processing program and image processing apparatus |
JP2008059287A (en) * | 2006-08-31 | 2008-03-13 | Brother Ind Ltd | Image processor and image processing program |
US20080187184A1 (en) * | 2007-02-01 | 2008-08-07 | Kabushiki Kaisha Toshiba | System and method for facial image enhancement |
-
2008
- 2008-09-10 JP JP2008231772A patent/JP5029545B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2010066943A (en) | 2010-03-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP7027537B2 (en) | Image processing methods and equipment, electronic devices, and computer-readable storage media | |
US8879847B2 (en) | Image processing device, method of controlling image processing device, and program for enabling computer to execute same method | |
TWI441095B (en) | Distance evaluation methods and apparatuses, and machine readable medium thereof | |
JP4952625B2 (en) | Perspective transformation distortion generating document image correcting apparatus and method | |
US9041834B2 (en) | Systems and methods for reducing noise in video streams | |
JP5524692B2 (en) | Information processing apparatus and method, and program | |
JP5007953B2 (en) | Image processing apparatus, image processing method, and program | |
US10839529B2 (en) | Image processing apparatus and image processing method, and storage medium | |
JP2010045613A (en) | Image identifying method and imaging device | |
Jeon et al. | Ring difference filter for fast and noise robust depth from focus | |
JPWO2014024655A1 (en) | Image processing apparatus, image processing method, and image processing program | |
WO2011089813A1 (en) | Image processing device | |
JP6261199B2 (en) | Information processing apparatus, information processing method, and computer program | |
JP5029545B2 (en) | Image processing method and apparatus | |
US10430960B2 (en) | Image processing apparatus, image processing method, and storage medium | |
US10880457B2 (en) | Image processing apparatus, image capturing apparatus, image processing method, and storage medium | |
JP5807555B2 (en) | Image processing program, apparatus and method | |
JP5397468B2 (en) | Pattern noise elimination device, pattern noise elimination method, pattern noise elimination program | |
JP6467817B2 (en) | Image processing apparatus, image processing method, and program | |
McCrackin et al. | Strategic image denoising using a support vector machine with seam energy and saliency features | |
JP7338182B2 (en) | Action recognition device, action recognition method and program | |
JP5853369B2 (en) | Image processing apparatus, image processing method, and program | |
Wang et al. | Multi-focus Image Fusion Algorithm Based on Weighted Local Variance Focus Detection | |
JP2006107018A (en) | Method and apparatus for image analysis, method and system for image processing, and operation program therefor | |
JP2000123180A (en) | Hologram recognizing device and hologram evaluating method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20110614 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20120511 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20120529 |
|
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20120611 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5029545 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20150706 Year of fee payment: 3 |
|
LAPS | Cancellation because of no payment of annual fees |