JP2005250778A - Vertical direction decision of image - Google Patents

Vertical direction decision of image Download PDF

Info

Publication number
JP2005250778A
JP2005250778A JP2004059193A JP2004059193A JP2005250778A JP 2005250778 A JP2005250778 A JP 2005250778A JP 2004059193 A JP2004059193 A JP 2004059193A JP 2004059193 A JP2004059193 A JP 2004059193A JP 2005250778 A JP2005250778 A JP 2005250778A
Authority
JP
Japan
Prior art keywords
image
processing apparatus
image processing
feature information
area
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
JP2004059193A
Other languages
Japanese (ja)
Inventor
Hitoshi Yamakado
均 山門
Takashi Tani
宇 谷
Toru Miyamoto
徹 宮本
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.)
Seiko Epson Corp
Original Assignee
Seiko Epson Corp
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 Seiko Epson Corp filed Critical Seiko Epson Corp
Priority to JP2004059193A priority Critical patent/JP2005250778A/en
Publication of JP2005250778A publication Critical patent/JP2005250778A/en
Pending legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide technology capable of automatically deciding the vertical direction of an image. <P>SOLUTION: First, by analyzing a pixel value of the color image, prescribed image characteristic information showing a characteristic of the color image is acquired. The vertical direction of the color image is decided by use of a decision rule using the image characteristic information. As the image characteristic information, a plurality of pieces of information such as person area information, sky/ground area information, linear information, rod-like object information can be used. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

この発明は、画像の天地を自動的に判定する技術に関する。   The present invention relates to a technique for automatically determining the top and bottom of an image.

デジタルカメラやカメラ付き携帯電話の普及によって、写真の電子化が急激に進められている。そのため、写真アルバムとしても、コンピュータ上でアルバムを構成する「電子アルバム」を好んで利用するユーザが増加している傾向にある。   With the widespread use of digital cameras and camera-equipped mobile phones, the digitization of photographs is rapidly progressing. For this reason, as for photo albums, the number of users who prefer and use “electronic albums” that make up albums on computers tends to increase.

電子アルバムに写真画像を配列する場合には、画像の天地を正しく向ける操作が必要になる。しかし、従来の電子アルバムは、画像の天地判定を行なう機能は有しておらず、手動により画像の方向を正しい方向に修正するという煩わしい作業をユーザに強いていた。   In order to arrange photographic images on an electronic album, it is necessary to perform an operation for correctly orienting the images. However, the conventional electronic album does not have a function of determining the top and bottom of the image, forcing the user to perform a cumbersome task of manually correcting the image direction to the correct direction.

特許文献1には、複写機において原稿の向きを検知する方法が開示されている。しかし、この方法は文字の向きから原稿の向きを検知するものであり、電子アルバムの素材となる写真画像(非文字画像)には適用できないものであった。   Patent Document 1 discloses a method for detecting the orientation of an original in a copying machine. However, this method detects the orientation of a document from the orientation of characters, and cannot be applied to a photographic image (non-character image) that is a material of an electronic album.

特開2003−143375号公報JP 2003-143375 A

なお、上述のような問題は、電子アルバムに限らず、画像管理ソフトウェアなどの他の画像処理ソフトウェアや画像処理装置にも共通する問題であった。   The above-described problems are not limited to electronic albums, but are common to other image processing software such as image management software and image processing apparatuses.

本発明は、上述した従来の課題を解決するためになされたものであり、画像の天地を自動的に判定することのできる技術を提供することを目的とする。   The present invention has been made to solve the above-described conventional problems, and an object thereof is to provide a technique capable of automatically determining the top and bottom of an image.

上記目的の少なくとも一部を達成するために、本発明による装置は、カラー画像の天地方向を判定する画像処理装置であって、
前記カラー画像の画素値を解析することによって、前記カラー画像の特徴を表す所定の画像特徴情報を取得する特徴情報取得部と、
前記画像特徴情報を利用した判定ルールを用いて前記カラー画像の天地方向を判定する天地方向判定部と、
を有することを特徴とする。
In order to achieve at least a part of the above object, an apparatus according to the present invention is an image processing apparatus for determining a vertical direction of a color image,
A feature information acquisition unit that acquires predetermined image feature information representing features of the color image by analyzing pixel values of the color image;
A top and bottom direction determination unit that determines the top and bottom direction of the color image using a determination rule that uses the image feature information; and
It is characterized by having.

この装置によれば、画像特徴情報を利用した判定ルールを用いてカラー画像の天地方向を判定するので、画像の天地を自動的に判定することが可能である。   According to this apparatus, since the top / bottom direction of the color image is determined using the determination rule using the image feature information, it is possible to automatically determine the top / bottom of the image.

前記天地方向判定部は、前記カラー画像の天地方向とともにその確率を決定し、確率の高い天地方向を採用するようにしてもよい。   The top / bottom direction determination unit may determine the probability together with the top / bottom direction of the color image, and may adopt a top / bottom direction with a high probability.

この構成によれば、より正確に天地方向を判定することができる。   According to this configuration, it is possible to determine the vertical direction more accurately.

前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する人物領域を表す人物領域情報を取得し、
前記天地方向判定部は、前記人物領域の天地の向きに応じて前記カラー画像の天地方向を判定するようにしてもよい。
The feature information acquisition unit acquires person area information representing a person area existing in the color image as the image feature information,
The top and bottom direction determination unit may determine the top and bottom direction of the color image according to the top and bottom direction of the person area.

この構成では、画像が人物を含む場合に、人物領域の向きに応じて天地方向を判定できるので、人物が正しく向くように画像の天地方向を決定することができる。   In this configuration, when the image includes a person, the top-and-bottom direction can be determined according to the direction of the person area, so that the top-and-bottom direction of the image can be determined so that the person faces correctly.

前記特徴情報取得部は、前記人物領域として、前記カラー画像内に存在する肌色領域を検出するようにしてもよい。   The feature information acquisition unit may detect a skin color area existing in the color image as the person area.

この構成では、肌色領域から人物を検出することができる。   In this configuration, a person can be detected from the skin color area.

前記特徴情報取得部は、肌色と認識する画素値の範囲を前記カラー画像の平均輝度に応じて変更するようにしてもよい。   The feature information acquisition unit may change the range of pixel values recognized as skin color according to the average luminance of the color image.

一般に、画像内の肌色の画素値は撮影時の周囲の明るさの影響を受ける。従って、上記の構成によれば、画像の平均輝度(明るさ)に応じて肌色領域を検出するパラメータを変更するので、より正確に肌色を検出することができる。   In general, the skin color pixel value in an image is affected by ambient brightness at the time of shooting. Therefore, according to the above configuration, the parameter for detecting the flesh color region is changed according to the average luminance (brightness) of the image, so that the flesh color can be detected more accurately.

前記天地方向判定部は、前記肌色領域に隣接する胴体領域の有無を前記天地方向判定に利用するようにしてもよい。   The top / bottom direction determination unit may use the presence / absence of a body region adjacent to the skin color region for the top / bottom direction determination.

この構成では、より正確に天地方向を判定することができる。   With this configuration, the top-and-bottom direction can be determined more accurately.

前記特徴情報取得部は、前記人物領域として、前記カラー画像内に存在する人物の顔領域を検出するようにしてもよい。   The feature information acquisition unit may detect a face area of a person existing in the color image as the person area.

この構成では、顔領域から人物を検出することができる。   In this configuration, a person can be detected from the face area.

前記特徴情報取得部は、前記カラー画像内に存在する肌色領域を抽出し、抽出された肌色領域の縦横比から前記顔領域となる肌色領域を選択するようにしてもよい。   The feature information acquisition unit may extract a skin color area existing in the color image and select a skin color area to be the face area from an aspect ratio of the extracted skin color area.

この構成では、より正確に顔領域を検出することができる。   With this configuration, the face area can be detected more accurately.

前記特徴情報取得部は、前記肌色領域の縦横比から前記顔領域の候補を選択し、前記顔領域候補の中で、顔の器官が含まれている領域を前記顔領域として選択するようにしてもよい。   The feature information acquisition unit selects the face area candidate from the aspect ratio of the skin color area, and selects an area including a facial organ from the face area candidates as the face area. Also good.

この構成では、さらに正確に顔領域を検出することができる。   With this configuration, the face area can be detected more accurately.

前記特徴情報取得部は、肌色領域であって、かつ、顔の器官が含まれている領域を前記顔領域として選択するようにしておもよい。   The feature information acquisition unit may select an area that is a skin color area and includes a facial organ as the face area.

この構成によっても、顔領域を正確に検出することができる。   Also with this configuration, the face area can be accurately detected.

前記天地方向判定部は、前記顔領域の中における前記顔の器官の位置関係を前記天地方向判定に利用するようにしてもよい。   The top / bottom direction determination unit may use the positional relationship of the facial organs in the face region for the top / bottom direction determination.

この構成では、より正確に天地方向を判定することができる。   With this configuration, the top-and-bottom direction can be determined more accurately.

前記天地方向判定部は、前記顔領域に隣接する頭髪領域の有無を前記天地方向判定に利用するようにしてもよい。   The top and bottom direction determination unit may use the presence or absence of a hair region adjacent to the face region for the top and bottom direction determination.

この構成によっても、正確に天地方向を判定することができる。   Also with this configuration, the top-and-bottom direction can be accurately determined.

前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する天空領域を表す天空領域情報を取得するようにしてもよい。   The feature information acquisition unit may acquire sky region information representing a sky region existing in the color image as the image feature information.

この構成では、画像が天空を含む場合に、天空領域情報に基づいて天地方向を判定できるので、天空が正しく上を向くように画像の天地方向を決定することができる。   In this configuration, when the image includes the sky, the top / bottom direction can be determined based on the sky region information. Therefore, the top / bottom direction of the image can be determined so that the sky faces up correctly.

前記特徴情報取得部は、
(i)前記カラー画像の昼夜の判定を行い、
(ii)前記カラー画像が昼に撮影された画像であると判定された場合には、前記カラー画像の平均輝度よりも明るい画素で構成された領域であって、かつ、前記カラー画像の端部に存在し、かつ、青、白、グレイのいずれかに属する色である領域を前記天空領域として検出するようにしてもよい。
The feature information acquisition unit
(I) Perform day / night determination of the color image,
(Ii) When it is determined that the color image is an image taken in the daytime, the color image is an area composed of pixels brighter than the average luminance of the color image, and an end portion of the color image And an area that is a color belonging to any one of blue, white, and gray may be detected as the sky area.

この構成では、昼の画像の場合に天空領域を正しく検出することができる。   With this configuration, it is possible to correctly detect the sky region in the case of a daytime image.

前記特徴情報取得部は、
(i)前記カラー画像を複数の区分領域に分割し、
(ii)各区分領域に対して周波数分析を行うことによって各区分領域の周波数特性を取得し、
(iii)低周波成分を主とする周波数特性を有する区分領域を前記天空領域として検出するようにしてもよい。
The feature information acquisition unit
(I) dividing the color image into a plurality of divided regions;
(Ii) obtaining frequency characteristics of each segmented region by performing frequency analysis on each segmented region;
(Iii) You may make it detect the division area | region which has a frequency characteristic mainly having a low frequency component as said sky area | region.

一般に、天空領域には物体がほとんど存在しないので、高周波成分が少なく低周波成分が主となる。従って、上記の構成によれば、天空領域を正しく検出することが可能である。   In general, since there are almost no objects in the sky region, there are few high-frequency components and mainly low-frequency components. Therefore, according to the above configuration, it is possible to correctly detect the sky region.

前記天地方向判定部は、前記天空領域が最も広く存在している箇所に近い画像端部を上方として判定するようにしてもよい。   The top-and-bottom direction determination unit may determine that an image end portion close to a place where the sky region is present most widely is set as the upper side.

この構成では、天地方向を正確に判定することができる。   With this configuration, it is possible to accurately determine the vertical direction.

前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する地上領域を表す地上領域情報を取得するようにしてもよい。   The feature information acquisition unit may acquire ground area information representing a ground area existing in the color image as the image feature information.

この構成では、画像が地上領域を含む場合に、地上領域情報に基づいて天地方向を判定できるので、地上領域が正しく下に存在するように画像の天地方向を決定することができる。   With this configuration, when the image includes a ground area, the top / bottom direction can be determined based on the ground area information, so that the top / bottom direction of the image can be determined so that the ground area exists correctly below.

前記特徴情報取得部は、
(i)前記カラー画像の昼夜の判定を行い、
(ii)前記カラー画像が夜に撮影された画像であると判定された場合には、前記カラー画像の平均輝度よりも明るい領域、または、所定の輝度以上の高輝度を有する高輝度部分が点在する暗い領域を前記地上領域として検出するようにしてもよい。
The feature information acquisition unit
(I) Perform day / night determination of the color image,
(Ii) When it is determined that the color image is an image taken at night, an area brighter than the average luminance of the color image or a high luminance part having a high luminance equal to or higher than a predetermined luminance An existing dark area may be detected as the ground area.

夜の画像では、地上領域に明かりが存在するので、明るい領域が地上領域となる可能性が高い。また、街灯やビルの明かりは、画像内に点在する高輝度部分となる。従って、上記の構成では、夜の画像における地上領域を正確に検出することができる。   In a night image, there is a light in the ground area, so there is a high possibility that a bright area will be the ground area. Street lights and building lights are high-intensity portions scattered in the image. Therefore, with the above configuration, the ground area in the night image can be accurately detected.

前記特徴情報取得部は、
(i)前記カラー画像を複数の区分領域に分割し、
(ii)各区分領域に対して周波数分析を行うことによって各区分領域の周波数特性を取得し、
(iii)高周波成分を主とする周波数特性を有する区分領域を地上領域として検出するようにしてもよい。
The feature information acquisition unit
(I) dividing the color image into a plurality of divided regions;
(Ii) obtaining frequency characteristics of each segmented region by performing frequency analysis on each segmented region;
(Iii) You may make it detect the division area which has a frequency characteristic mainly having a high frequency component as a ground area.

一般に、地上領域には多数の物体が存在するので、高周波成分が主となる。従って、上記の構成によって、地上領域を正しく検出することが可能である。   In general, since there are a large number of objects in the ground area, high frequency components are mainly used. Therefore, it is possible to correctly detect the ground area by the above configuration.

前記特徴情報取得部は、
(i)前記カラー画像の昼夜の判定を行い、
(ii)前記カラー画像が夜に撮影された画像であると判定された場合には、
前記カラー画像を縦方向に二分割した第1の画像と、横方向に二分割した第2の画像とに関して、分割した2つの領域の輝度コントラストを前記画像特徴情報としてそれぞれ算出し、
前記天地方向判定部は、前記輝度コントラストがより大きな分割方向において、輝度がより高い領域を下方として判定するようにしてもよい。
The feature information acquisition unit
(I) Perform day / night determination of the color image,
(Ii) If it is determined that the color image is an image taken at night,
For the first image obtained by dividing the color image into two in the vertical direction and the second image divided into two in the horizontal direction, the luminance contrast of the two divided regions is calculated as the image feature information, respectively.
The top-and-bottom direction determination unit may determine a region having a higher luminance as a lower side in a division direction in which the luminance contrast is higher.

一般に、夜の画像では、地上の方が天空よりも明るい傾向がある。従って、上記の構成によって天地方向を正しく判定することができる。   Generally, in night images, the ground tends to be brighter than the sky. Therefore, the top and bottom direction can be correctly determined by the above configuration.

前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像の全体にわたる直線を表す直線情報を取得し、前記天地方向判定部は、前記画像の上下方向と左右方向とのうちで前記直線となす角度がより大きな方向を天地方向と判定するようにしてもよい。   The feature information acquisition unit acquires, as the image feature information, straight line information representing a straight line over the entire color image, and the top and bottom direction determination unit includes the straight line between the vertical direction and the horizontal direction of the image. A direction with a larger angle may be determined as the top-and-bottom direction.

この構成では、水平線や地平線などのように画像の全体を横切る直線を用いて天地方向を判定することができる。   In this configuration, the top-and-bottom direction can be determined using a straight line that traverses the entire image, such as a horizontal line or a horizon line.

前記天地方向判定部は、
(i)前記直線を水平線または地平線とみなすとともに、
(ii)前記カラー画像の長手方向と前記直線の方向とが平行から所定の角度範囲にあると判断した場合に、現在の天地関係が正しいと判定するようにしてもよい。
The top and bottom direction determination unit
(I) Considering the straight line as a horizon or horizon,
(Ii) When it is determined that the longitudinal direction of the color image and the direction of the straight line are within a predetermined angle range from parallel, the current top-to-bottom relationship may be determined to be correct.

この構成では、画像が水平線や地平線を含む場合に天地方向を正しく判定することができる。   With this configuration, the top-to-bottom direction can be correctly determined when the image includes a horizontal line or a horizon line.

前記特徴情報取得部は、前記画像特徴情報として、さらに、前記カラー画像内に存在する天空領域を表す天空領域情報を取得し、
前記天地方向判定部は、
(i)前記直線を水平線または地平線とみなすとともに、
(ii)前記水平線または地平線に対して前記天空領域が存在する方向を上方として判定するようにしてもよい。
The feature information acquisition unit further acquires, as the image feature information, sky region information representing a sky region existing in the color image,
The top and bottom direction determination unit
(I) Considering the straight line as a horizon or horizon,
(Ii) The direction in which the sky region exists with respect to the horizon or horizon may be determined as upward.

この構成によっても、画像が水平線や地平線を含む場合に天地方向を正しく判定することができる。   Even with this configuration, it is possible to correctly determine the top-to-bottom direction when the image includes a horizontal line or a horizon line.

前記天地方向判定部は、
(i)前記直線を水平線または地平線とみなすとともに、
(ii)前記直線の近傍に所定の輝度以上の高輝度領域が一つのみ存在する場合に、前記直線に対して前記高輝度領域が存在する方向を上方として判定するようにしてもよい。
The top and bottom direction determination unit
(I) Considering the straight line as a horizon or horizon,
(Ii) When only one high-brightness area having a predetermined luminance or higher exists in the vicinity of the straight line, the direction in which the high-brightness area exists with respect to the straight line may be determined as upward.

この構成では、例えば夕方の画像であって水平線や地平線の近傍に太陽が存在するような場合に、その天地方向を正しく判定することができる。   With this configuration, for example, when the image is an evening image and the sun is present near the horizon or the horizon, the top-to-bottom direction can be correctly determined.

前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する3本以上の収束する直線で構成される消失線を表す消失線情報を取得するようにしてもよい。   The feature information acquisition unit may acquire vanishing line information representing vanishing lines composed of three or more converging straight lines existing in the color image as the image feature information.

この構成では、画像が消失線を含む場合に天地方向を正しく判定することができる。   With this configuration, it is possible to correctly determine the vertical direction when the image includes a vanishing line.

前記天地方向判定部は、前記消失線の両側の輝度コントラストを比較し、輝度が明るい側を上方として判定するようにしてもよい。   The top and bottom direction determination unit may compare the luminance contrasts on both sides of the vanishing line and determine that the brighter side is the upper side.

消失線の上側には天空が存在することが多いので、上記の構成によって天地方向を正しく判定することができる。   Since there is often a sky above the vanishing line, the top and bottom direction can be correctly determined by the above configuration.

前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する棒状のオブジェクトを表す棒状オブジェクト情報を取得するようにしてもよい。   The feature information acquisition unit may acquire bar-shaped object information representing a bar-shaped object existing in the color image as the image feature information.

この構成では、画像がビルディングのような棒状オブジェクトを含む場合に天地方向を正しく判定することができる。   With this configuration, the top-and-bottom direction can be correctly determined when the image includes a bar-like object such as a building.

前記特徴情報取得部は、
(i)前記カラー画像を色情報に基づいて複数の色領域に分離し、
(ii)前記複数の色領域のうちで縦横比が所定の値以上である色領域を前記棒状オブジェクトとして検出するようにしてもよい。
The feature information acquisition unit
(I) separating the color image into a plurality of color regions based on color information;
(Ii) A color area having an aspect ratio equal to or greater than a predetermined value among the plurality of color areas may be detected as the rod-like object.

この構成では、棒状オブジェクトを容易に検出することができる。   With this configuration, it is possible to easily detect a rod-like object.

あるいは、前記特徴情報取得部は、
(i)前記カラー画像を空間微分することによりエッジ画像を生成し、
(ii)前記エッジ画像に含まれる閉領域を検出するとともに、
(iii)縦横比が所定の値以上である閉領域を前記棒状オブジェクトとして検出するようにしてもよい。
Alternatively, the feature information acquisition unit
(I) generating an edge image by spatially differentiating the color image;
(Ii) detecting a closed region included in the edge image;
(Iii) You may make it detect the closed area | region whose aspect ratio is more than predetermined value as the said rod-shaped object.

これらの構成によっても、棒状オブジェクトを容易に検出することができる。   Also with these configurations, the rod-shaped object can be easily detected.

前記特徴情報取得部は、前記画像特徴情報として、さらに、前記カラー画像内に存在する天空領域を表す天空領域情報を取得し、
前記天地方向判定部は、前記棒状オブジェクトの長手方向の片端が前記天空領域に重なっている場合に、前記棒状オブジェクトの長手方向に沿った方向であって前記重なりの存在する方向を上方として判定するようにしてもよい。
The feature information acquisition unit further acquires, as the image feature information, sky region information representing a sky region existing in the color image,
The top-and-bottom direction determination unit determines that a direction along the longitudinal direction of the bar-shaped object and where the overlap exists is upward when one end in the longitudinal direction of the bar-shaped object overlaps the sky region. You may do it.

ビルディングなどの棒状オブジェクトが鉛直方向に立っている場合には、その上方が天空領域に係っているのが普通である。従って、上記の構成によって天地方向を正しく判定することができる。   When a bar-like object such as a building stands in the vertical direction, it is normal that the upper part is related to the sky region. Therefore, the top and bottom direction can be correctly determined by the above configuration.

前記画像特徴情報取得部は、複数種類の画像特徴情報を取得し、
前記天地方向判定部は、前記複数種類の画像特徴情報を用いて前記カラー画像の天地方向を判定するようにしてもよい。
The image feature information acquisition unit acquires a plurality of types of image feature information,
The top and bottom direction determining unit may determine the top and bottom direction of the color image using the plurality of types of image feature information.

この構成では、複数の画像特徴情報を用いて天地方向を判定するので、より正確に判定を行うことができる。   In this configuration, since the top-and-bottom direction is determined using a plurality of pieces of image feature information, the determination can be performed more accurately.

前記天地方向判定部は、
(i)各種類の画像特徴情報を用いて前記カラー画像の天地方向とその確率とをそれぞれ決定するとともに、
(ii)各種類の画像特徴情報を用いて得られた天地方向とその確率とを総合して前記カラー画像の天地方向を決定するようにしてもよい。
The top and bottom direction determination unit
(I) determining the vertical direction of the color image and its probability using each type of image feature information,
(Ii) The vertical direction of the color image may be determined by combining the vertical direction obtained by using each type of image feature information and the probability thereof.

この構成では、さらに正確に天地判定を行うことができる。   With this configuration, it is possible to perform the top-and-bottom determination more accurately.

なお、本発明は、種々の態様で実現することが可能であり、例えば、画像の天地方向決定方法および装置、電子アルバムの作成方法および装置、電子アルバムのための画像処理方法および装置、それらの方法または装置の機能を実現するためのコンピュータプログラム、そのコンピュータプログラムを記録した記録媒体、等の態様で実現することができる。   It should be noted that the present invention can be realized in various modes. For example, an image top-and-bottom direction determination method and apparatus, an electronic album creation method and apparatus, an image processing method and apparatus for an electronic album, and their The present invention can be realized in the form of a computer program for realizing the function of the method or apparatus, a recording medium on which the computer program is recorded, and the like.

次に、本発明の実施の形態を実施例に基づいて以下の順序で説明する。
A.実施例の装置構成および処理の概要:
B.天地方向判定処理の詳細:
C.変形例:
Next, embodiments of the present invention will be described in the following order based on examples.
A. Outline of apparatus configuration and processing of embodiment:
B. Details of the top / bottom direction determination process:
C. Variation:

A.実施例の装置構成および処理の概要:
図1は、本発明の一実施例としての画像処理システムを示す説明図である。この画像処理システムは、デジタルカメラ100とコンピュータ200とカラープリンタ300とを備えている。コンピュータ200は、電子アルバムの作成処理を実行する画像処理部210を備えている。この画像処理部210は、デジタルカメラ100に設けられていてもよく、また、カラープリンタ300に設けられていてもよい。
A. Outline of apparatus configuration and processing of embodiment:
FIG. 1 is an explanatory diagram showing an image processing system as an embodiment of the present invention. This image processing system includes a digital camera 100, a computer 200, and a color printer 300. The computer 200 includes an image processing unit 210 that executes an electronic album creation process. The image processing unit 210 may be provided in the digital camera 100 or may be provided in the color printer 300.

画像処理部210は、ユーザインタフェース部212と、画像群選択部214と、画像特徴情報取得部216と、天地方向判定部218と、ページ割当部220と、アルバム生成部222と、画像データ出力部224と、を有している。電子アルバムの素材として用いられる複数の画像は、画像格納部230に格納されている。これらの画像は通常は写真画像であるが、スキャナで取得した画像やコンピュータグラフィックスをアルバムの素材として用いても良い。後述するように、ユーザインタフェース部212(図1)は、ユーザが天地判定ルールを選択する際に使用するルール選択部としての機能を有している。画像処理部210の各構成要素の機能は、コンピュータプログラムによって実現される。   The image processing unit 210 includes a user interface unit 212, an image group selection unit 214, an image feature information acquisition unit 216, a top and bottom direction determination unit 218, a page allocation unit 220, an album generation unit 222, and an image data output unit. 224. A plurality of images used as materials for the electronic album are stored in the image storage unit 230. These images are usually photographic images, but images acquired by a scanner or computer graphics may be used as material for the album. As will be described later, the user interface unit 212 (FIG. 1) has a function as a rule selection unit used when the user selects a top / bottom determination rule. The function of each component of the image processing unit 210 is realized by a computer program.

図2は、実施例における処理手順を示すフローチャートである。ステップS100では、ユーザが電子アルバムの作成に関する種々の条件を指定する。この指定は、ユーザインタフェース部212によって表示デバイス上に表示されたユーザインタフェース画面を用いて行われる。   FIG. 2 is a flowchart illustrating a processing procedure in the embodiment. In step S100, the user designates various conditions regarding creation of an electronic album. This designation is performed using a user interface screen displayed on the display device by the user interface unit 212.

図3は、アルバム作成条件指定のためのユーザインタフェース画面の例を示す説明図である。このユーザインタフェース画面には、アルバム名を入力するためのフィールドF1と、天地判定ルールを選択するための複数のボタンBTと、アルバムに入れる画像を選択するための画像選択領域ISAと、を有している。   FIG. 3 is an explanatory diagram showing an example of a user interface screen for specifying album creation conditions. This user interface screen includes a field F1 for inputting an album name, a plurality of buttons BT for selecting a top / bottom determination rule, and an image selection area ISA for selecting an image to be included in the album. ing.

天地判定ルールは、画像の天地判定を行う際に使用するルールである。各ルールは、それぞれ異なる画像的な特徴に基づいて天地判定を行う。図3の例では、「人物」と、「空・地上」と、「直線」と、「棒状オブジェクト」と、の4つの特徴を用いるルールが選択可能に表示されている。「人物」に基づくルールは、画像を解析して人物である領域を画像的特徴として抽出し、この人物領域に基づいて天地を判定するルールである。「空・地上」に基づくルールは、画像を解析して天空または地上である領域を画像的特徴として抽出し、この空・地上領域に基づいて天地を判定するルールである。「直線」に基づくルールは、画像を解析して画像内に含まれている1つまたは複数の直線を画像的特徴として抽出し、この直線に基づいて天地を判定するルールである。「棒状オブジェクト」に基づくルールは、画像を解析してビルディングなどの棒状オブジェクト領域を画像的特徴として抽出し、この棒状オブジェクト領域に基づいて天地を判定するルールである。なお、天地判定ルールとしては、任意の複数のルールを選択対象とすることが可能である。   The top / bottom determination rule is a rule used when determining the top / bottom of an image. Each rule performs top-and-bottom determination based on different image characteristics. In the example of FIG. 3, rules using four characteristics of “person”, “sky / ground”, “straight line”, and “bar-shaped object” are displayed in a selectable manner. The rule based on “person” is a rule for analyzing an image, extracting a region that is a person as an image feature, and determining the top and bottom based on the person region. The rule based on “sky / ground” is a rule for analyzing the image, extracting a sky or ground area as an image feature, and determining the sky based on the sky / ground area. The rule based on “straight line” is a rule for analyzing the image, extracting one or more straight lines included in the image as image features, and determining the top and bottom based on the straight line. The rule based on the “bar object” is a rule for analyzing the image, extracting a bar object area such as a building as an image feature, and determining the top and bottom based on the bar object area. In addition, as a top-and-bottom determination rule, it is possible to select an arbitrary plurality of rules as selection targets.

この例から理解できるように、複数の天地判定ルールは、互いに異なる画像的な特徴を使用して画像の天地を判定するものである。なお、画像的な特徴としては、画像の画素値を解析した得られるものと、被写体位置のように各画像の撮影時に作成された付属情報から取得されるものを使用することができる。但し、複数の天地判定ルールは、少なくとも画像の画素値を解析して得られる画像的特徴を利用するものを含むことが好ましい。   As can be understood from this example, the plurality of top and bottom determination rules determine the top and bottom of the image using different image characteristics. In addition, as an image characteristic, what is obtained from analyzing the pixel value of an image and what is acquired from attached information created at the time of photographing each image such as a subject position can be used. However, it is preferable that the plurality of top and bottom determination rules include a rule that uses at least an image characteristic obtained by analyzing a pixel value of an image.

図3のボタンBTの中の「全て」の選択肢は、各特徴に基づく個別の天地判定を総合して最終的な天地判定を行うルールである。複数種類の画像特徴(例えば「人物」と「空・地上」)が選択されたときにも、それぞれの特徴によるに基づく個別の天地判定を総合して最終的な天地判定が行われる。   The “all” options in the button BT of FIG. 3 are rules for performing final top and bottom judgment by combining individual top and bottom judgments based on each feature. Even when a plurality of types of image features (for example, “person” and “sky / ground”) are selected, final top and bottom determination is performed by combining individual top and bottom determinations based on the respective features.

図3の画像選択領域ISAに示されている8つの画像G1〜G8の中で、1番目の画像G1と6番目の画像G6は、画像の左側が天方向である。従って、これらの画像G1,G6は、後述する天地判定において、画像の左端が天方向であると判定される。   Among the eight images G1 to G8 shown in the image selection area ISA of FIG. 3, the first image G1 and the sixth image G6 are on the left side of the image. Therefore, these images G1 and G6 are determined to have the left end in the top direction in the top / bottom determination described later.

アルバム作成条件が指定されると、ステップS200,S300,S400,S500において、選択された天地判定ルールに従って各画像の天地方向とその確率が決定される。この際、画像群選択部214(図1)が、画像選択領域ISAで選択された複数の画像を画像格納部230から取得する。そして、画像特徴情報取得部216が各画像の画像特徴情報を取得し、天地方向判定部218が画像特徴情報を用いて画像の天地方向と確率を決定する。なお、ステップS200,S300,S400,S500の詳細については後述する。   When the album creation conditions are specified, the top and bottom direction of each image and its probability are determined in steps S200, S300, S400, and S500 according to the selected top and bottom judgment rule. At this time, the image group selection unit 214 (FIG. 1) acquires a plurality of images selected in the image selection area ISA from the image storage unit 230. Then, the image feature information acquisition unit 216 acquires image feature information of each image, and the top / bottom direction determination unit 218 determines the top / bottom direction and probability of the image using the image feature information. Details of steps S200, S300, S400, and S500 will be described later.

ステップS600では、天地方向判定部218が複数のルールに基づく天地判定の結果を総合して、最終的な天地判定を実行する。この処理についても後述する。なお、ステップS100で1つの天地判定ルールのみが選択されているときには、そのルールで決定された結果がそのまま採用される。   In step S600, the top and bottom direction determination unit 218 performs final top and bottom determination by combining the results of top and bottom determination based on a plurality of rules. This process will also be described later. When only one top / bottom determination rule is selected in step S100, the result determined by the rule is used as it is.

ステップS700では、ページ割当部220が、アルバムの各ページに画像を割り当てる。この際、各画像の向きがステップS600で決定された正しい天地方向を向くように必要に応じて画像の回転が行われる。   In step S700, the page assignment unit 220 assigns an image to each page of the album. At this time, the image is rotated as necessary so that the orientation of each image faces the correct top-and-bottom direction determined in step S600.

こうして画像の各ページへの割当が終了すると、ステップS800において、アルバム生成部222が、アルバム画像を表すアルバム画像データを生成する。図4は、生成されたアルバム画像の一例を示している。この例では、1番目の画像G1と6番目の画像G6は、正しい天地方向を向くように画像が回転されて配置されている。   When the assignment of images to each page is completed in this way, in step S800, the album generation unit 222 generates album image data representing the album image. FIG. 4 shows an example of the generated album image. In this example, the first image G1 and the sixth image G6 are arranged such that the images are rotated so as to face the correct top-and-bottom direction.

このように、本実施例では、画像を解析することによって画像的な特徴を抽出し、この特徴に基づいて画像の天地を判定するので、ユーザの操作を有することなく画像を正しい向きに配置することができる。特に、複数の特徴に基づく天地判定を用いて総合的に天地判定を行うので、天地判定を精度良く行うことが可能である。   As described above, in this embodiment, image features are extracted by analyzing an image, and the top and bottom of the image is determined based on the features. Therefore, the image is arranged in the correct orientation without any user operation. be able to. In particular, since the top / bottom determination is comprehensively performed using the top / bottom determination based on a plurality of features, the top / bottom determination can be performed with high accuracy.

B.天地方向判定処理の詳細:
以下では、次の順に天地方向判定処理を説明する。
B1.人物領域に基づく天地方向判定手順:
B2.空・地上領域に基づく天地方向判定手順:
B3.直線に基づく天地方向判定手順:
B4.棒状オブジェクトに基づく天地方向判定手順:
B5.総合天地判定手順:
B. Details of the top / bottom direction determination process:
Hereinafter, the top / bottom direction determination processing will be described in the following order.
B1. Top / bottom direction determination procedure based on person area:
B2. Top-to-bottom direction determination procedure based on sky and ground area:
B3. Top and bottom direction determination procedure based on a straight line:
B4. Top-and-bottom direction determination procedure based on a bar-shaped object:
B5. Comprehensive top and bottom judgment procedure:

B1.人物領域に基づく天地方向判定手順:
図5Aは、人物領域に基づく天地判定手順を示すフローチャートである。ステップS202では、画像特徴情報取得部216が、処理対象とするカラー画像(以下、「処理対象画像」と呼ぶ)から人物領域を抽出する。図5BはステップS202の詳細手順を示している。
B1. Top / bottom direction determination procedure based on person area:
FIG. 5A is a flowchart illustrating the top-and-bottom determination procedure based on the person area. In step S202, the image feature information acquisition unit 216 extracts a person region from a color image to be processed (hereinafter referred to as a “processing target image”). FIG. 5B shows the detailed procedure of step S202.

ステップS262では、カラー画像から肌色領域を抽出する。この際、まず、画像データをHSV(色相/彩度/輝度)色空間に変換し、カラー画像の平均輝度Vaveを算出する。そして、平均輝度Vaveの所定の範囲毎に、肌色画素値の適切な範囲を設定して肌色画素の抽出を行なっている。肌色画素値の範囲の具体例は以下の通りである(H成分の範囲が0〜359、S,V各成分の範囲が0〜255の場合)。   In step S262, a skin color region is extracted from the color image. In this case, first, the image data is converted into an HSV (Hue / Saturation / Luminance) color space, and an average luminance Vave of the color image is calculated. Then, for each predetermined range of the average luminance Vave, an appropriate range of skin color pixel values is set and skin color pixels are extracted. Specific examples of the skin color pixel value range are as follows (when the H component range is 0 to 359 and the S and V component ranges are 0 to 255).

(A1)120≦Vaveの場合の肌色画素値の範囲:
H成分:10<H<40
S成分:S>60
V成分:V>150
但し、V成分が210以上の画素に関しては、S成分の値に無関係に、H成分が10<H<45の画素を肌色画素とする。この理由は、輝度が極めて高い画素、すなわちハイライトと考えられる画素に対しては、S(彩度)成分を無視してH(色相)成分のみで判断を行なう方が適切だからである。
(A1) Skin color pixel value range when 120 ≦ Vave:
H component: 10 <H <40
S component: S> 60
V component: V> 150
However, regarding a pixel having a V component of 210 or more, regardless of the value of the S component, a pixel having an H component of 10 <H <45 is defined as a flesh color pixel. This is because it is more appropriate to ignore the S (saturation) component and make a determination only with the H (hue) component for a pixel with extremely high luminance, that is, a pixel considered to be a highlight.

(A2)90≦Vave<120の場合の肌色画素値の範囲:
H成分:0<H<40
S成分:S>60
V成分:V>100
但し、V成分が210以上の画素に関しては、S成分の値に無関係に、H成分が10<H<45の画素を肌色画素とする。
(A2) Skin color pixel value range when 90 ≦ Vave <120:
H component: 0 <H <40
S component: S> 60
V component: V> 100
However, regarding a pixel having a V component of 210 or more, regardless of the value of the S component, a pixel having an H component of 10 <H <45 is defined as a flesh color pixel.

(A3)Vave<90の場合の肌色画素値の範囲:
H成分:0<H<30 又は 350<H<360
S成分:30<S<200
V成分:V>80
但し、V成分が210以上の画素に関しては、S成分の値に無関係に、10<H<35の画素を肌色画素とする。
(A3) Skin color pixel value range when Vave <90:
H component: 0 <H <30 or 350 <H <360
S component: 30 <S <200
V component: V> 80
However, for a pixel having a V component of 210 or more, a pixel of 10 <H <35 is defined as a skin color pixel regardless of the value of the S component.

このように、画像の平均輝度Vave(または平均明度)を複数の範囲に区分し、各範囲に対して肌色画素値の範囲を設定するようにすれば、画像全体が明るいか暗いかに応じて、適切な肌色画素の範囲を設定することができる。この結果、肌色画素の検出をより正確に行うことが可能である。   In this way, if the average luminance Vave (or average brightness) of the image is divided into a plurality of ranges and the range of skin color pixel values is set for each range, depending on whether the entire image is bright or dark, An appropriate skin color pixel range can be set. As a result, skin color pixels can be detected more accurately.

こうして検出された肌色画素の集合が肌色領域として抽出される。この際、ある程度の数(例えば10画素、または、画像全体の画素数の1%以上)以上の肌色画素が接した状態で集合している画像領域のみを肌色領域として抽出してもよい。また、肌色領域の中に、顔の器官(眉、目、鼻、口、耳)などが含まれている場合には、これらの器官を包含する領域を1つの肌色領域として抽出してもよい。なお、顔の器官を「顔の要素」とも呼ぶ。   A set of skin color pixels thus detected is extracted as a skin color region. At this time, only an image area gathered in a state where a certain number (for example, 10 pixels or 1% or more of the total number of pixels) or more skin color pixels are in contact may be extracted as the skin color area. If the skin color area includes facial organs (brows, eyes, nose, mouth, ears) and the like, the area including these organs may be extracted as one skin color area. . The organ of the face is also called “face element”.

図6(A)は、1番目の画像G1から抽出された肌色領域FAの例を示している。この例では、顔の器官を含む領域が1つの肌色領域FAとして抽出されている。   FIG. 6A shows an example of the skin color area FA extracted from the first image G1. In this example, an area including a facial organ is extracted as one skin color area FA.

なお、肌色画素の判断方法としては、これ以外の任意の方法を採用することができる。例えば、S成分やV成分の値に無関係に、H成分が予め定められた範囲内の値を有する場合に肌色画素として検出することが可能である。また、色空間としては、CIELab色空間やYIQ色空間などの色空間を用いることも可能である。   It should be noted that any other method can be employed as the skin color pixel determination method. For example, regardless of the values of the S component and the V component, when the H component has a value within a predetermined range, it can be detected as a skin color pixel. As the color space, a color space such as a CIELab color space or a YIQ color space may be used.

図5BのステップS264では、抽出した各肌色領域の縦横比Rを算出する。縦横比Rは、図6(B)に示すように、肌色領域を包含する矩形の長辺の長さWlongと短辺の長さWshortの比である。ステップS266では、この縦横比Rが所定の範囲(本実施例では1.5以上で3未満)の場合に、この肌色領域を人物の顔領域とみなして、その領域に顔領域(または「人物領域」)であることを示すフラグを付ける。ステップS264,S266の処理は、処理対象画像中のすべての肌色領域について実行される(ステップS268)。   In step S264 of FIG. 5B, the aspect ratio R of each extracted skin color area is calculated. As shown in FIG. 6B, the aspect ratio R is a ratio of the long side length Wlong and the short side length Wshort of the rectangle including the skin color region. In step S266, when the aspect ratio R is within a predetermined range (1.5 to less than 3 in the present embodiment), the skin color area is regarded as a human face area, and the face area (or “person” A flag indicating that the area is “)” is attached. The processes in steps S264 and S266 are executed for all skin color regions in the processing target image (step S268).

なお、本実施例では、顔領域を人物領域として抽出するものとしたが、これ以外の方法で人物領域を抽出するものとしてもよい。例えば、人物を構成する複数の要素(頭部、胴体、手足)のいくつかを含む広い領域を人物領域として抽出することも可能である。   In the present embodiment, the face area is extracted as a person area, but the person area may be extracted by a method other than this. For example, it is possible to extract a wide area including some of a plurality of elements (head, torso, limbs) constituting a person as a person area.

こうして人物領域の抽出が終了すると、図5AのステップS204において、天地方向判定部218が、処理対象画像内に人物領域が存在するか否かを判定する。人物領域が存在しない場合には、ステップS206において処理対象画像の天地方向が不明と判定され、ステップS600に移行して総合的な天地方向判定処理を待つことになる。この場合に、ステップS206における「天地方向が不明」という判定結果は、人物領域に基づく天地方向判定ができないことを意味しており、他の特徴を用いた天地判定はできる可能性がある。   When the extraction of the person area is thus completed, the top / bottom direction determination unit 218 determines whether or not the person area exists in the processing target image in step S204 of FIG. 5A. If the person area does not exist, it is determined in step S206 that the top / bottom direction of the processing target image is unknown, and the process proceeds to step S600 to wait for comprehensive top / bottom direction determination processing. In this case, the determination result that “the direction of the top and bottom is unknown” in step S206 means that the top and bottom direction cannot be determined based on the person area, and there is a possibility that the top and bottom determination using other features can be performed.

一方、処理対象画像内に人物領域が存在する場合には、人物領域の天地の向きに応じて画像の天地方向が判定される。具体的には、ステップS208において、画像特徴情報取得部216が、人物領域内の顔の器官を検出する。顔器官抽出処理は、例えば、ニューラルネットワークによる処理や、画像内の色変化や輝度変化を利用した処理、画像内の形状を利用した処理などの種々の処理を利用することができる。本実施例では、顔の器官として目と口を検出するものと仮定する。   On the other hand, when a person area exists in the processing target image, the top / bottom direction of the image is determined according to the top / bottom direction of the person area. Specifically, in step S208, the image feature information acquisition unit 216 detects a facial organ in the person region. For the facial organ extraction process, various processes such as a process using a neural network, a process using a color change or luminance change in an image, or a process using a shape in an image can be used. In this embodiment, it is assumed that eyes and mouth are detected as facial organs.

天地方向判定部218は、ステップS210〜S242において、顔の器官として目と口のいずれが検出されたかに応じて以下のような処理を実行する。   The top / bottom direction determination unit 218 executes the following processing in steps S210 to S242 depending on whether an eye or a mouth is detected as a facial organ.

目と口の両方とも検出できた場合(ステップS210)には、顔領域に対する目、口の位置関係から画像の天地方向を判定する(ステップS212)。例えば、図6(A)の例のように、両目と口とが検出された場合井は、両目の中間位置と口とを結ぶ直線によって天地方向が決定される。すなわち、口から両目の中間位置に向かう方向が天方向である。また、片目と口とが検出された場合には、その目と口とを結ぶ直線によって天地方向が決定される。ステップS214では、目と口の検出結果から判定確率が決定される。例えば、両目と口を全て検出できた場合は、判定確率を100%と決定し、片目と口が検出できた場合は判定確立を75%に設定する。   If both eyes and mouth can be detected (step S210), the top-to-bottom direction of the image is determined from the positional relationship of the eyes and mouth with respect to the face region (step S212). For example, as in the example of FIG. 6A, when both eyes and the mouth are detected, the vertical direction is determined by a straight line connecting the middle position of both eyes and the mouth. That is, the direction from the mouth toward the middle position of both eyes is the celestial direction. When one eye and mouth are detected, the top and bottom direction is determined by a straight line connecting the eyes and mouth. In step S214, the determination probability is determined from the detection result of the eyes and mouth. For example, if both eyes and mouth can be detected, the determination probability is determined to be 100%, and if one eye and mouth can be detected, the determination probability is set to 75%.

口が検出できずに目だけ検出できた場合(ステップS220)には、顔領域に対する目の位置から画像の天地方向を判定する(ステップS222)。例えば、顔領域のうちで目に近い端部から反対側の端部に向かうに方向を地方向(下方向)として決定する。この場合には、目のみが検出できているので、ステップS224において、判定確率を50%に設定する。この判定確率は、目と口の両方が検出された場合(ステップS214)よりも小さな値に設定される。   If only the eyes can be detected without detecting the mouth (step S220), the top-to-bottom direction of the image is determined from the position of the eyes with respect to the face region (step S222). For example, the direction from the end close to the eyes to the opposite end of the face region is determined as the ground direction (downward). In this case, since only eyes can be detected, the determination probability is set to 50% in step S224. This determination probability is set to a smaller value than when both eyes and mouth are detected (step S214).

目が検出できずに口だけ検出できた場合(ステップS230)には、顔領域に対する口の位置から画像の天地方向(上方向)を判定する(ステップS232)。例えば、顔領域のうちで口に近い端部から反対側の端部に向かう方向を天方向(上方向)として決定する。口は目に比べてより顔の端に近い位置に存在するので、目のみ検出できた場合よりも判定確率を少し高めの判定確率(例えば60%)に設定する。   When eyes cannot be detected and only the mouth can be detected (step S230), the vertical direction (upward direction) of the image is determined from the position of the mouth with respect to the face area (step S232). For example, the direction from the end close to the mouth to the opposite end of the face region is determined as the top direction (upward). Since the mouth is located closer to the edge of the face than the eyes, the determination probability is set to a slightly higher determination probability (for example, 60%) than when only the eyes can be detected.

目と口の両方とも検出できなかった場合(ステップS240)には、天地方向が不明としてステップS250に移行する。なお、天地方向が不明の場合には、画像の4つの辺の判定確率がすべて0%に設定される。また、ステップS212,S222,S232において天地方向(天方向または地方向)であると判定されなかった辺については、判定確率が0%に設定される。このような判定確率の設定は、他の特徴を用いた処理でも同じである。   If neither eyes nor mouth can be detected (step S240), the top-to-bottom direction is unknown and the process proceeds to step S250. When the top / bottom direction is unknown, the determination probabilities for the four sides of the image are all set to 0%. In addition, the determination probability is set to 0% for the sides that are not determined to be in the vertical direction (the vertical direction or the horizontal direction) in steps S212, S222, and S232. Such setting of the determination probability is the same in processing using other features.

なお、ステップS240において天地方向を不明とする代わりに、顔領域の長手方向に沿った直線と交差する2つの辺のうちで、顔領域がより近い辺を天方向と判定してもよい。この場合の判定確率は、目や口を検出できた場合よりも低い値(例えば30%)に設定される。   Instead of making the top / bottom direction unknown in step S240, the side closer to the face region may be determined as the top direction among the two sides intersecting the straight line along the longitudinal direction of the face region. In this case, the determination probability is set to a lower value (for example, 30%) than when eyes or a mouth can be detected.

ステップS250では、処理対象画像内のすべての人物領域に関する処理が終了したか否かが判断され、終了すると図2のステップS600(最終天地判定)に移行する。   In step S250, it is determined whether or not the processing related to all the person areas in the processing target image has been completed. When the processing is completed, the process proceeds to step S600 (final top / bottom determination) in FIG.

なお、複数の人物領域において異なる判定結果が得られた場合には、各人物領域の判定結果を総合して、人物領域に基づく判定結果を求めることができる。例えば、複数の判定結果の中で最も判定確率の高いものを採用することができる。また、同じ天地方向を有するものと判定された人物領域が複数個存在する場合には、その方向の判定確率を高めるように判定確率を修正してもよい。例えば、同じ第1の天地方向を有し、かつ、判定確率が75%である人物領域が2つ存在した場合には、その判定確率を90%に修正してもよい。この時、仮に他の人物領域に基づいて判定された第2の天地方向の75%の確率であれば、第1の天地方向およびその判定確率90%が最終的な判定結果として採用される。   When different determination results are obtained in a plurality of person areas, the determination results based on the person areas can be obtained by combining the determination results of the person areas. For example, the determination result having the highest determination probability among a plurality of determination results can be employed. In addition, when there are a plurality of person regions determined to have the same top-and-bottom direction, the determination probability may be modified to increase the determination probability in that direction. For example, when there are two person regions having the same first vertical direction and a determination probability of 75%, the determination probability may be corrected to 90%. At this time, if the probability is 75% of the second vertical direction determined based on another person area, the first vertical direction and the determination probability of 90% are adopted as the final determination result.

図6(C)は、上述した処理によって検出された天地方向に応じて回転した画像を示している。通常は、このように、画像の矩形の4辺のうちの1辺に平行な方向が天地方向となる。   FIG. 6C shows an image rotated according to the vertical direction detected by the above-described processing. Normally, the direction parallel to one of the four sides of the rectangular image is the top-and-bottom direction.

ところで、図6(D)の例ように、人物領域から判定された天方向Fupと、画像の1辺に並行な方向Gupとの間の角度θがかなり大きな値を示す場合がある。この場合には、例えば、4辺の方向Gup,Gdown,Gright,Gleftのうちで、顔領域の天方向Fupと最も近いものを画像の天方向として選択することが可能である。但し、画像の下方向Gdownは、天方向の候補から除外するようにしてもよい。この理由は、カメラを上下反転して撮影することが極めてまれだからである。   By the way, as in the example of FIG. 6D, the angle θ between the sky direction Fup determined from the person area and the direction Gup parallel to one side of the image may show a considerably large value. In this case, for example, among the four side directions Gup, Gdown, Gright, and Gleft, the one closest to the top direction Fup of the face region can be selected as the top direction of the image. However, the downward direction Gdown of the image may be excluded from the candidates for the top direction. This is because it is extremely rare to shoot with the camera turned upside down.

このように、人物領域に基づく天地方向判定処理では、処理対象画像を解析して人物領域を抽出し、その人物領域の天地の向きから画像の天地方向を判定するので、自動的に天地方向を判定することができる。また、特に、人物領域内における顔の器官の位置から天地方向を判定するようにすれば、より正確に天地方向を判定することができる。   In this way, in the top / bottom direction determination process based on the person area, the processing target image is analyzed to extract the person area, and the top / bottom direction of the image is determined from the top / bottom direction of the person area. Can be determined. In particular, if the top / bottom direction is determined from the position of the facial organ in the person area, the top / bottom direction can be determined more accurately.

なお、上述の説明では、顔領域内における顔の器官の位置に応じて天地方向を判定していたが、この代わりに、顔領域とその顔領域に隣接する頭髪部分(頭髪領域)との位置関係から天地方向を判定することも可能である。また、肌色領域(顔領域)とその肌色領域に隣接する胴体部分(胴体領域)との位置関係から天地方向を判定することも可能である。頭髪部分や胴体部分の判定は、例えばこれらの部分の典型的な形状を用いた形状テンプレートマッチングを用いて行うことが可能である。   In the above description, the top-and-bottom direction is determined according to the position of the facial organ in the face area. Instead, the position of the face area and the hair portion (hair area) adjacent to the face area is determined. It is also possible to determine the top and bottom direction from the relationship. It is also possible to determine the top-and-bottom direction from the positional relationship between the skin color region (face region) and the body part (body region) adjacent to the skin color region. The hair part and the body part can be determined using, for example, shape template matching using typical shapes of these parts.

B2.空・地上領域に基づく天地方向判定手順:
図7は、空・地上領域に基づく天地判定手順を示すフローチャートである。ステップS302では、画像特徴情報取得部216が、処理対象画像の平均輝度を求め、この平均輝度に応じて昼夜の判定を行なう。具体的には、画像の平均輝度が所定の閾値(例えば110)以上の場合には、昼に撮影された画像と判定し、閾値未満の場合には夜に撮影された画像と判定する。なお、昼夜判定は、撮影時に画像データに付されている撮影時間情報から行なっても良い。
B2. Top-to-bottom direction determination procedure based on sky and ground area:
FIG. 7 is a flowchart showing the top / bottom determination procedure based on the sky / ground area. In step S302, the image feature information acquisition unit 216 obtains the average luminance of the processing target image, and performs day / night determination according to the average luminance. Specifically, when the average luminance of the image is equal to or higher than a predetermined threshold (for example, 110), it is determined that the image is captured in the daytime, and when it is less than the threshold, it is determined that the image is captured at night. Note that day / night determination may be performed based on shooting time information attached to image data at the time of shooting.

図8(A)は、図3の2番目の画像G2を示している。この画像G2は昼に撮影された画像であり、明るい空領域を含んでいる。   FIG. 8A shows the second image G2 of FIG. This image G2 is an image taken in the daytime and includes a bright sky region.

昼の画像と判定された場合には、ステップS306以下の処理が実行される。まず、ステップS306では、画像特徴情報取得部216が、画像全体の平均輝度よりも明るい画素にフラグ付けを行なう。そして、ステップS308では、フラグ付けされた画素であって、かつ、連続している画素同士を連結する。以下では、こうして画素同士が連結された領域を「連結領域」と呼ぶ。ステップS310では、連結領域の色を調べ、その連結領域が青、白、グレイのいずれかに属する所定の色を有する場合に、空領域候補(「天空領域候補」とも呼ぶ)として再度フラグ付けを行なう。青、白、グレイに属する画素値の範囲は、例えば以下のように設定することができる。   If it is determined that the image is a daytime image, the processes in and after step S306 are executed. First, in step S306, the image feature information acquisition unit 216 flags pixels that are brighter than the average luminance of the entire image. In step S308, the pixels that are flagged and are continuous are connected. Hereinafter, an area where pixels are connected in this manner is referred to as a “connected area”. In step S310, the color of the connected area is checked, and if the connected area has a predetermined color belonging to any of blue, white, and gray, it is flagged again as a sky area candidate (also called “sky area candidate”). Do. The range of pixel values belonging to blue, white, and gray can be set as follows, for example.

青:200<H<240、Sは全範囲、V>(平均輝度Vaveの1.5倍)
白:Hは全範囲、S<10、V>(平均輝度Vaveの1.5倍)
グレイ:Hは全範囲、S<30、V>(平均輝度aveの1.5倍)
Blue: 200 <H <240, S is full range, V> (1.5 times the average luminance Vave)
White: H is the entire range, S <10, V> (1.5 times the average luminance Vave)
Gray: H is the entire range, S <30, V> (1.5 times the average luminance ave)

ある領域を空領域候補としてフラグ付けするかどうかの判断基準としては、例えば、(i)連結領域中の70%以上の画素が青、白、グレイのいずれかに属する色に分類される場合、あるいは、(ii)連結領域の平均色が青、白、グレイのいずれかに属する色に分類される場合、などのいくつかの基準を採用することができる。図8(B)は、画像G2に関して抽出された空領域SA(空領域候補)を示している。   For example, (i) when 70% or more of pixels in a connected region are classified as a color belonging to any one of blue, white, and gray, as a criterion for determining whether or not to flag a certain region as an empty region candidate, Alternatively, (ii) some criteria such as when the average color of the connected region is classified into a color belonging to any of blue, white, and gray can be adopted. FIG. 8B shows an empty area SA (empty area candidate) extracted with respect to the image G2.

こうして空領域候補が検出されると、天地方向判定部218は、ステップS312において、画像の4辺のうちで、空領域候補が一番広く存在する端部(辺)を画像の上方(天方向)と判定する。この際、空領域候補が複数の辺に接している場合には、各辺上における空領域候補の長さを計算し、各辺の長さに対する空領域候補の長さの比が最も大きい辺が画像の上方と判定される。図8(B)の例では、画像G2の上辺が、画像の上方(天方向)と判定される。   When the sky region candidate is detected in this way, in step S312, the top / bottom direction determination unit 218 sets an end (side) where the sky region candidate is widest among the four sides of the image above the image (top direction). ). In this case, when the sky region candidate is in contact with a plurality of sides, the length of the sky region candidate on each side is calculated, and the side having the largest ratio of the length of the sky region candidate to the length of each side is calculated. Is determined to be above the image. In the example of FIG. 8B, the upper side of the image G2 is determined to be above the image (upward direction).

ステップS314では、空領域候補が一つの辺のみにかかっている場合に、その判定確率が100%に設定される。また、各辺上における空領域候補の長さで上方を判定した場合には、判定確率が75%に設定される。   In step S314, when the sky region candidate covers only one side, the determination probability is set to 100%. In addition, when the upward direction is determined based on the length of the empty area candidate on each side, the determination probability is set to 75%.

このように、昼の画像に関しては、空領域が画像の4辺のうちのいずれに最も多く長く接しているかに応じて画像の天地方向を判定すれば、かなり正確に天地方向を判定することが可能である。   Thus, for a daytime image, if the sky direction of the image is determined according to which of the four sides of the image is the longest, the sky direction can be determined fairly accurately. Is possible.

一方、ステップS304において、昼の画像と判定されなかった場合には、ステップS320において、夜の画像であるか否かの判定が行われる。具体的には、例えば、画像全体の平均輝度Vaveが90未満の場合には夜と判定することができる。あるいは、画像を9等分し、そのうちの中央のブロックの平均輝度Vaveが90未満の場合に夜として判定を行なうことも可能である。昼の画像とも夜の画像とも判定されなかった場合には、ステップS330において天地方向不明と判定され、ステップS600(総合天地判定処理)に移行する。   On the other hand, if it is not determined that the image is a day image in step S304, it is determined in step S320 whether the image is a night image. Specifically, for example, when the average luminance Vave of the entire image is less than 90, it can be determined that the night. Alternatively, the image may be divided into nine equal parts, and the determination may be made as night when the average luminance Vave of the central block is less than 90. If neither the daytime image nor the nighttime image is determined, it is determined in step S330 that the top-and-bottom direction is unknown, and the process proceeds to step S600 (total top-and-bottom determination processing).

図9(A)は、図3の3番目の画像G3を示している。この画像G3は、全体的に暗く輝度が低いので、夜に撮影された画像であると判断される。なお、画像G3内の白い点は、街灯や、建物の窓、自動車のヘッドライトなどの明るい物体である。   FIG. 9A shows the third image G3 of FIG. Since this image G3 is dark overall and low in luminance, it is determined that the image G3 is an image taken at night. Note that white dots in the image G3 are bright objects such as street lamps, building windows, and automobile headlights.

ステップS320で夜の画像と判定された場合には、画像特徴情報取得部216は、ステップS322において処理対象画像を4つのブロックに等分し、各ブロックの平均輝度を求める。図9(B)は、画像G3が4つのブロックB1〜B4に区分された状態を示している。ステップS324では、図9(C)に示すように、画像の上方にある2つのブロックB1,B2で構成される上方領域Aupperと、下方にある2つのブロックB3,B4で構成される下方領域Alowerの間の輝度コントラストCT1が算出される。輝度コントラストCT1は、上方領域Aupperの平均輝度Vave(Aupper)と、下方領域Alowerの平均輝度Vave(Alower)の比である。同様に、図9(D)に示すように、現在の画像方向の左方にある2つのブロックB1,B3で構成される左方領域Aleftと、右方にある2つのブロックB2,B4で構成される右方領域Arightの間の輝度コントラストCT2=Vave(Aleft)/Vave(Aright)が算出される。   If it is determined in step S320 that the image is a night image, the image feature information acquisition unit 216 equally divides the processing target image into four blocks in step S322, and obtains the average luminance of each block. FIG. 9B shows a state in which the image G3 is divided into four blocks B1 to B4. In step S324, as shown in FIG. 9C, an upper area Aupper composed of two blocks B1 and B2 above the image and a lower area Alower composed of two blocks B3 and B4 below. Luminance contrast CT1 is calculated. The luminance contrast CT1 is a ratio of the average luminance Vave (Aupper) in the upper area Aupper and the average luminance Vave (Alower) in the lower area Alower. Similarly, as shown in FIG. 9 (D), a left area Aleft composed of two blocks B1 and B3 on the left side of the current image direction, and two blocks B2 and B4 on the right side. The luminance contrast CT2 = Vave (Aleft) / Vave (Aright) between the right areas Aright is calculated.

天地方向判定部218は、ステップS322において、これらの輝度コントラストCT1,CT2を比較し、より大きなコントラストを与える分割方向を画像の天地方向と判定する。さらに、その天地方向のうちで、より輝度の高い方を下方(地方向)と判定する。図9(C),9(D)の例では、図9(C)の上下分割のコントラストCT1の方が大きいので、現在の画像の上下方向が天地方向であると判定される。また、画像の上下方向のうちで、下方がより輝度が高いので、現在の下方が地方向であると判定される。なお、本明細書において、「分割方向」とは、分割線に垂直な方向を意味する。   In step S322, the top / bottom direction determination unit 218 compares the luminance contrasts CT1 and CT2 and determines the division direction that gives a larger contrast as the top / bottom direction of the image. Furthermore, among the top-and-bottom directions, the one with higher luminance is determined to be downward (the ground direction). In the examples of FIGS. 9C and 9D, since the up and down division contrast CT1 of FIG. 9C is larger, it is determined that the vertical direction of the current image is the vertical direction. Moreover, since the brightness is higher in the vertical direction of the image, it is determined that the current lower direction is the ground direction. In the present specification, the “dividing direction” means a direction perpendicular to the dividing line.

ステップS328では、輝度コントラストの値が十分大きい場合(例えば2以上の場合)に、判定確率が100%に設定され、それ以外の場合には判定確率が75%に設定される。   In step S328, when the brightness contrast value is sufficiently large (for example, 2 or more), the determination probability is set to 100%, and in other cases, the determination probability is set to 75%.

このように、空・地上領域に基づく天地方向判定処理では、昼の画像の場合には空領域を抽出し、その空領域の画像内の位置に応じて天地方向を判定するので、自動的に天地方向を判定することができる。また、夜の画像の場合には、画像内の上下方向の輝度コントラストと左右方向の輝度コントラストとを用いて天地方向を判定するので、夜の画像に関しても、正しく天地方向を判定することができる。但し、昼の画像か夜の画像かを判定せずに、画像内の空領域を抽出し、空領域の画像内の位置から天地方向を判定するようにしてもよい。   In this way, in the top / bottom direction determination process based on the sky / ground area, the sky area is extracted in the case of a daytime image, and the top / bottom direction is determined according to the position of the sky area in the image. The top and bottom direction can be determined. In the case of a night image, the vertical direction is determined using the vertical and horizontal luminance contrasts in the image, so that the vertical direction can also be correctly determined for a night image. . However, without determining whether the image is a daytime image or a night image, the sky region in the image may be extracted, and the top-and-bottom direction may be determined from the position of the sky region in the image.

また、空領域(空領域候補)が抽出された場合には、それ以外の領域を地上領域として認識するようにしてもよい。あるいは、空領域が認識できない場合にも、特定の色や形状を有する領域(例えば茶色や緑色の広大な領域)を地上領域として抽出するようにしてもよい。この場合には、地上領域の画像内の位置に応じて天地方向を判定することが可能である。   In addition, when an empty area (empty area candidate) is extracted, other areas may be recognized as the ground area. Alternatively, even when the sky area cannot be recognized, an area having a specific color or shape (for example, a vast area of brown or green) may be extracted as the ground area. In this case, it is possible to determine the top / bottom direction according to the position of the ground region in the image.

図10は、図7のステップS320以降の処理の変形例を示している。この処理手順では、図7のステップS322〜S328がステップS340〜S344で置き換えられており、他の手順は図7と同じである。   FIG. 10 shows a modification of the processing after step S320 in FIG. In this processing procedure, steps S322 to S328 in FIG. 7 are replaced by steps S340 to S344, and other procedures are the same as those in FIG.

ステップS340では、画像特徴情報取得部216が、処理対象画像を4つのブロックに等分し、各ブロックにおいて、それぞれの平均輝度よりも高い輝度を有する画素数H1〜H4(「高輝度画素数」と呼ぶ)をカウントする。図11(A),(B)は、画像G3と、4つのブロックB1〜B4に関する高輝度画素数H1〜H4が検出された状態を示している。なお、ブロック分割の数は、4以外の任意の値に設定することが可能である。但し、画像の上下方向の分割数と左右方向の分割数を同じ値にすることが好ましい。   In step S340, the image feature information acquisition unit 216 equally divides the processing target image into four blocks, and in each block, the number of pixels H1 to H4 having a luminance higher than the average luminance (“high luminance pixel number”). Count). FIGS. 11A and 11B show a state in which the number of high luminance pixels H1 to H4 related to the image G3 and the four blocks B1 to B4 is detected. The number of block divisions can be set to any value other than 4. However, it is preferable to set the vertical division number and the horizontal division number of the image to the same value.

ステップS342では、天地方向判定部218が、各ブロックの高輝度画素数H1〜H4を比較して、高輝度画素数の値が最も大きなブロックがある方向を下方(地方向)と判定する。図11(B)の場合には、4番目のブロックB4に接する画像の下辺または右辺を画像の下方(地方向)と判定する。この理由は、夜の画像で明かりのあるところは、地上に近い可能性が高いからである。なお、この判定の際には、画像の下辺または右辺のうちで、2番目の高輝度画素数を有するブロックB3にも接する辺を下方と判定することが好ましい。図11(C)は、9つのブロックB1〜B9に分割した場合を示している。この場合には、8番目のブロックB8の高輝度画素数H8が最も大きいので、このブロックB8に接する画像の下辺が画像の下方向と判定される。   In step S342, the top / bottom direction determination unit 218 compares the high-luminance pixel numbers H1 to H4 of the respective blocks, and determines the direction in which the block having the largest value of the high-luminance pixel number is downward (the ground direction). In the case of FIG. 11B, the lower side or the right side of the image in contact with the fourth block B4 is determined as the lower side (the ground direction) of the image. This is because a place where there is a light in a night image is likely to be close to the ground. In this determination, it is preferable to determine that the lower side or the right side of the image that touches the block B3 having the second high luminance pixel number is the lower side. FIG. 11C shows a case where the block is divided into nine blocks B1 to B9. In this case, since the number of high luminance pixels H8 of the eighth block B8 is the largest, the lower side of the image in contact with the block B8 is determined as the downward direction of the image.

ステップS344では、高輝度画素数の最大値Hmaxと最小値Hminとの差を求め、この差が大きい場合には判定確率を100%に設定し、小さい場合には判定確率を75%に設定してステップS600(総合天地判定処理)に移行する。なお、(Hmax−Hmin)が大きい場合に判定確率をより高い値に設定する理由は、この場合に地上と空の区別がより明瞭になっていると考えられるからである。   In step S344, the difference between the maximum value Hmax and the minimum value Hmin of the number of high-luminance pixels is obtained. If this difference is large, the determination probability is set to 100%, and if it is small, the determination probability is set to 75%. Then, the process proceeds to step S600 (total top / bottom determination process). The reason why the determination probability is set to a higher value when (Hmax−Hmin) is large is that the distinction between the ground and the sky is considered to be clearer in this case.

図12は、図7のステップS320以降の処理の他の変形例を示している。この処理手順では、図7のステップS322〜S328がステップS350〜S354で置き換えられており、他の手順は図7と同じである。   FIG. 12 shows another modification of the processing after step S320 in FIG. In this processing procedure, steps S322 to S328 in FIG. 7 are replaced with steps S350 to S354, and other procedures are the same as those in FIG.

ステップS350では、画像特徴情報取得部216が、処理対象画像を16個のブロックに等分し、各ブロックにおいて周波数分析を行い、高周波数成分が大きなブロックに対してフラグ付けを行う。   In step S350, the image feature information acquisition unit 216 equally divides the processing target image into 16 blocks, performs frequency analysis in each block, and flags a block having a large high frequency component.

図13は、画像G3の16個のブロックに関して周波数分析が行われた結果を示している。ここでは、画像の上側にある8つのブロックでは低周波成分が主成分となっており、下側にある8つのブロックでは高周波成分が主成分となっている。ここで、高周波成分と低周波成分のいずれが主成分となっているかの判定は、例えば、全周波数領域を所定の境界周波数で2つに分割し、高周波領域での成分の和(または最大値)と、低周波領域の成分の和(または最大値)とを比較することによって実行することができる。なお、この変形例でもブロック分割の数は、16以外の任意の値に設定することが可能である。   FIG. 13 shows the result of frequency analysis performed on 16 blocks of the image G3. Here, the low frequency component is the main component in the eight blocks on the upper side of the image, and the high frequency component is the main component in the eight blocks on the lower side. Here, whether the high frequency component or the low frequency component is the main component is determined by dividing the entire frequency region into two at a predetermined boundary frequency, for example, and summing the components in the high frequency region (or the maximum value). ) And the sum (or maximum value) of the components in the low frequency region. In this modification as well, the number of block divisions can be set to any value other than 16.

ステップS352では、天地方向判定部218が、高周波ブロックが多く存在する領域を地上領域と見なして、その領域に近い画像の端部(辺)を画像の下方(地方向)と判定する。具体的には、例えば、互いに隣接する1つ以上高周波ブロックで構成される地上領域を検出し、その地上領域に最も近接している画像の辺を、画像の下方と判定することが可能である。   In step S352, the top / bottom direction determination unit 218 regards an area where many high-frequency blocks exist as a ground area, and determines an end (side) of the image close to that area as the lower side (ground direction) of the image. Specifically, for example, it is possible to detect a ground area composed of one or more high-frequency blocks adjacent to each other and determine the side of the image closest to the ground area as the lower side of the image. .

ステップS354は、高周波ブロックがステップS352で画像の下方と判定された端部(辺)に接している場合には、判定確率を80%と設定し、そうでない場合には判定確率を60%と設定する。高周波ブロックが画像の下方と判定された端部に接している場合により高い判定確率を設定する理由は、地上領域をより正しく検出できている可能性が高いからである。   In step S354, the determination probability is set to 80% when the high-frequency block is in contact with the end (side) determined to be below the image in step S352, and the determination probability is set to 60% otherwise. Set. The reason why a higher determination probability is set when the high-frequency block is in contact with the edge determined to be below the image is that there is a high possibility that the ground area can be detected more correctly.

上述した図7および図10,図12の変形例から理解できるように、夜の画像に関しては、分割ブロックの輝度または周波数分析結果を利用することによって、画像の天地方向を判定することが可能である。但し、夜の画像に関しては、上述の方法以外の種々の方法で地上領域を検出することも可能である。例えば、処理対象画像の平均輝度よりも明るい領域を地上領域として検出してもよく、あるいは、所定の輝度以上の高輝度を有する高輝度部分が点在する暗い領域を地上領域として検出してもよい。   As can be understood from the above-described modified examples of FIGS. 7, 10, and 12, for night images, it is possible to determine the top-to-bottom direction of the images by using the luminance or frequency analysis results of the divided blocks. is there. However, for night images, the ground region can be detected by various methods other than those described above. For example, an area brighter than the average brightness of the processing target image may be detected as a ground area, or a dark area in which high-intensity portions having high brightness equal to or higher than a predetermined brightness are scattered may be detected as a ground area. Good.

なお、図12の周波数分析を用いた天地判定は、夜の画像に限らず昼の画像にも適用可能である。昼の画像では、空領域では低周波成分が主成分となるので、低周波成分が主である領域やブロックを、空領域(空領域候補)として選択することができる。従って、昼の画像か夜の画像かに拘わらず、低周波成分を主とする領域を空領域と判定し、高周波成分を主とする領域を地上領域と判定することができる。   Note that the top and bottom determination using the frequency analysis of FIG. 12 can be applied not only to a night image but also to a day image. In the daytime image, since the low frequency component is the main component in the sky region, it is possible to select a region or block mainly containing the low frequency component as the sky region (empty region candidate). Therefore, regardless of whether it is a daytime image or a nighttime image, it is possible to determine an area mainly including low-frequency components as an empty area and an area mainly including high-frequency components as a ground area.

B3.直線に基づく天地方向判定手順:
図14Aおよび図14Bは、直線に基づく天地判定手順を示すフローチャートである。ステップS402では、画像特徴情報取得部216が、処理対象画像内の直線の検出を行なう。なお、画像内の直線は、例えば、処理対象画像を空間微分して各画素のエッジ量を求め、各画素のエッジ量で構成される画像(エッジ画像)を生成し、このエッジ画像に対してハフ変換を行うことによって求めることができる。なお、画像の空間微分は、例えばラプラシアンフィルタなどの微分フィルタを用いて行うことが可能である。
B3. Top and bottom direction determination procedure based on a straight line:
14A and 14B are flowcharts showing the top and bottom determination procedure based on a straight line. In step S402, the image feature information acquisition unit 216 detects a straight line in the processing target image. The straight line in the image is obtained by, for example, spatially differentiating the processing target image to obtain the edge amount of each pixel, and generating an image (edge image) composed of the edge amount of each pixel. It can be obtained by performing a Hough transform. The spatial differentiation of the image can be performed using a differential filter such as a Laplacian filter.

ステップS404では、天地方向判定部218が、直線が検出されたか否かを判断する。ここで、直線とは、所定の長さ(例えば100画素)以上の線分を意味している。直線が検出されなかった場合には、ステップS440において天地方向不明と判定し、ステップS600(総合天地判定処理)に移行する。一方、直線が検出された場合には、ステップS406において、その直線が画像の縦方向、あるいは横方向全体にわたる直線であるかどうかの判定を行なう。縦方向または横方向全体にわたる直線が存在しない場合には、図14Bに示す収束直線判定処理(後述)に移行する。   In step S404, the top / bottom direction determination unit 218 determines whether or not a straight line is detected. Here, the straight line means a line segment having a predetermined length (for example, 100 pixels) or more. If a straight line is not detected, it is determined in step S440 that the top / bottom direction is unknown, and the process proceeds to step S600 (total top / bottom determination processing). On the other hand, if a straight line is detected, it is determined in step S406 whether the straight line is a straight line extending in the vertical or horizontal direction of the image. When there is no straight line extending in the vertical direction or the entire horizontal direction, the process proceeds to a convergence straight line determination process (described later) shown in FIG. 14B.

一方、画像全体にわたる直線が存在する場合には、天地方向判定部218が、図14AのステップS410以降の処理を実行する。図15は、画像全体にわたる直線(「貫通直線」とも呼ぶ)を含む画像の例を示している。この画像G4は水平線を含んでおり、この水平線が貫通直線TSGとして判定される。なお、図3に示した画像G2,G5,G6も直線を含んでいるが、貫通直線は含んでいない。   On the other hand, when there is a straight line over the entire image, the top / bottom direction determination unit 218 executes the processing after step S410 in FIG. 14A. FIG. 15 shows an example of an image including a straight line (also referred to as a “penetrating straight line”) over the entire image. This image G4 includes a horizontal line, and this horizontal line is determined as a through straight line TSG. Note that the images G2, G5, and G6 shown in FIG. 3 also include straight lines, but do not include through straight lines.

ステップS410では、まず、画像の長手方向と貫通直線の方向が一致するかどうか判定を行なう。この判定は、画像の長手方向と貫通直線の方向のなす角度が所定の値(例えば20度)以下であるか否かによって行うことができる。画像の長手方向と一致する長い直線が存在する場合には、その直線が水平線や地平線などであることが多いと考えられる。そこで、これらの2つの方向が一致した場合には、ステップS412において、現在の画像の上方をそのまま上方と判定し、判定確率を75%に設定してステップS600(総合天地判定処理)へ移る。この理由は、横長の画像を撮影する際にカメラを上下反転して撮影することが極めてまれだからである。一方、2つの方向が一致しなかった場合には、ステップS420において、画像特徴情報取得部216が空領域の検出を行なう。この処理は、図7のステップS310で説明したものと同じである。   In step S410, first, it is determined whether or not the longitudinal direction of the image matches the direction of the through straight line. This determination can be made based on whether or not the angle formed between the longitudinal direction of the image and the direction of the penetrating straight line is equal to or less than a predetermined value (for example, 20 degrees). If there is a long straight line that coincides with the longitudinal direction of the image, it is often considered that the straight line is a horizontal line or a horizon line. Therefore, when these two directions coincide with each other, in step S412, it is determined that the current image is directly above, the determination probability is set to 75%, and the process proceeds to step S600 (total top / bottom determination processing). This is because it is extremely rare to take a picture by turning the camera upside down when taking a landscape image. On the other hand, if the two directions do not match, the image feature information acquisition unit 216 detects an empty area in step S420. This process is the same as that described in step S310 of FIG.

ステップS420において空領域が検出できた場合には、ステップS422において、空領域が検出された方向を上方と判定し、判定確率を75%に設定してステップS600(総合天地判定処理)へ移る。但し、図7のステップS312,S314と同様に、空領域と画像の辺(端部)との関係から判定確率を設定するようにしても良い。   If the sky area can be detected in step S420, the direction in which the sky area is detected is determined to be upward in step S422, the determination probability is set to 75%, and the process proceeds to step S600 (total top / bottom determination processing). However, as in steps S312 and S314 in FIG. 7, the determination probability may be set from the relationship between the sky region and the side (edge) of the image.

一方、ステップS420で空領域が検出できなかった場合には、ステップS430において、貫通直線近傍に高輝度領域が存在するかどうかの判定を行なう。ここで、「高輝度領域」とは、例えば、HSV色空間でのV値が所定の値(例えば200)以上である画素が、所定数(例えば20画素)以上集合している領域を意味する。例えば、夕焼けの画像を撮影した場合には、太陽が高輝度領域として認識される。貫通直線近辺に高輝度領域が検出された場合には、ステップS432において、貫通直線よりも高輝度領域に近い方の画像の辺を上方として判定し、判定確率を75%に設定してステップS600(総合天地判定処理)へ移る。なお、高輝度領域が2つ以上検出された場合には、物体の鏡面反射によるものである可能性が高いので、高輝度領域無しと判定してもよい。ステップS430において貫通直線近傍に高輝度領域が検出できなかった場合には、ステップS440において天地方向不明と判定し、ステップS600(総合天地判定処理)へ移る。   On the other hand, if an empty area cannot be detected in step S420, it is determined in step S430 whether a high luminance area exists in the vicinity of the through straight line. Here, the “high luminance region” means, for example, a region where a predetermined number (for example, 20 pixels) or more of pixels having a V value in the HSV color space that is equal to or larger than a predetermined value (for example, 200). . For example, when a sunset image is taken, the sun is recognized as a high brightness area. If a high-luminance area is detected in the vicinity of the through-line, in step S432, the side of the image closer to the high-luminance area than the through-line is determined as the upper side, and the determination probability is set to 75%. Move to (Comprehensive top / bottom judgment processing). When two or more high-luminance areas are detected, there is a high possibility that the object is due to specular reflection of the object, and it may be determined that there is no high-luminance area. If a high brightness area cannot be detected in the vicinity of the through straight line in step S430, it is determined in step S440 that the top / bottom direction is unknown, and the process proceeds to step S600 (total top / bottom determination processing).

図14Bに示す収束直線判定処理では、まずステップS450において、画像特徴情報取得部216が、3本以上の直線が検出されているか否かを判断する。3本以上の直線が検出された場合には、ステップS452において、ほぼ1点に収束する3本以上の直線の組(「収束直線群」または「消失線群」と呼ぶ)を探索する。図16(A)は元画像G5を示し、図16(B)は、収束点CPに収束する直線群CSGを示している。なお、収束直線群CSGの収束点CPは、ある程度の許容範囲を有していてもよい。   In the convergence straight line determination process shown in FIG. 14B, first, in step S450, the image feature information acquisition unit 216 determines whether or not three or more straight lines are detected. If three or more straight lines are detected, a set of three or more straight lines that converge to approximately one point (referred to as a “converging straight line group” or “disappearing line group”) is searched in step S452. FIG. 16A shows the original image G5, and FIG. 16B shows a straight line group CSG that converges at the convergence point CP. The convergence point CP of the convergence straight line group CSG may have a certain allowable range.

ステップS450において3本の直線が検出されなかった場合、あるいは、ステップS452において収束直線群が検出されなかった場合には、天地方向不明と判定して、ステップS600(総合天地判定処理)へ移る。   If three straight lines are not detected in step S450, or if a convergent straight line group is not detected in step S452, it is determined that the vertical direction is unknown, and the process proceeds to step S600 (total vertical determination process).

一方、ステップS452において、収束直線群が検出された場合には、画像特徴情報取得部216が、収束直線群の両側に関する輝度コントラストを算出する。具体的には、例えば図16(C)に示すように、収束直線群CSGを挟む2つの領域A1,A2における平均輝度をそれぞれ算出して、それらの平均輝度の比を輝度コントラストとして算出する。そして、輝度がより高い方の領域が存在する画像の辺を上方(天方向)と判定し、その判定確率を60%に設定してステップS600(総合天地判定処理)へ移る。輝度がより高い領域を画像の上方向と判定する理由は、輝度が高い方がより空に近い方向である可能性が高いからである。なお、この場合の設定確率も、図7のステップS312,S314と同様に、より高輝度の領域と画像の辺(端部)との関係に応じて設定するようにしても良い。   On the other hand, when the convergence straight line group is detected in step S452, the image feature information acquisition unit 216 calculates the luminance contrast on both sides of the convergence straight line group. Specifically, for example, as shown in FIG. 16C, the average luminance in each of the two regions A1 and A2 sandwiching the convergence straight line group CSG is calculated, and the ratio of the average luminance is calculated as the luminance contrast. Then, the side of the image in which the region with the higher luminance exists is determined to be upward (top direction), the determination probability is set to 60%, and the process proceeds to step S600 (total top / bottom determination processing). The reason why the area with higher luminance is determined as the upper direction of the image is that a higher luminance is more likely to be closer to the sky. Note that the setting probability in this case may also be set according to the relationship between the higher brightness area and the side (edge) of the image, as in steps S312 and S314 of FIG.

このように、直線に基づく天地方向判定処理では、図15のように貫通直線が存在する場合に、貫通直線の方向や、貫通直線と空領域との位置関係に応じて画像の天地を正しく判定することができる。従って、水平線や地平線などのような貫通直線がある場合に、画像の天地を正しく判定することが可能である。また、収束直線群が存在する場合には、収束直線群の両側の輝度に応じて画像の天地を正しく判定することができる。   Thus, in the top / bottom direction determination process based on a straight line, when there is a penetrating straight line as shown in FIG. 15, the top / bottom of the image is correctly determined according to the direction of the penetrating straight line and the positional relationship between the penetrating straight line and the sky region. can do. Therefore, it is possible to correctly determine the top and bottom of the image when there is a through straight line such as a horizontal line or a horizon line. Further, when the convergence straight line group exists, the top and bottom of the image can be correctly determined according to the luminance on both sides of the convergence straight line group.

なお、画像が貫通直線を含む場合には、上述の判定の代わりに、画像の上下方向と左右方向との2つの方向のうちで、貫通直線となす角度がより大きな方向を天地方向と判定するようにしてもよい。例えば、貫通直線の向きが画像の左右方向に近い場合には、画像の上下方向が天地方向となり、元の画像の方向が正しく天地を向いていると判定される。一方、貫通直線の向きが画像の上下方向に近い場合には、画像の左右方向が天地方向となる。この場合には、他の画像的な特徴(例えば画像の左右のコントラストなど)を用いて天方向または地方向を判定してもよい。   When the image includes a penetrating straight line, instead of the above-described determination, the direction in which the angle formed by the penetrating straight line is larger among the two directions of the vertical and horizontal directions of the image is determined as the vertical direction. You may do it. For example, when the direction of the penetrating straight line is close to the horizontal direction of the image, it is determined that the vertical direction of the image is the top-and-bottom direction, and the original image direction is correctly facing the top and bottom. On the other hand, when the direction of the penetrating straight line is close to the vertical direction of the image, the horizontal direction of the image is the vertical direction. In this case, the celestial direction or the ground direction may be determined using other image characteristics (for example, left and right contrast of the image).

また、画像が収束線群を含む場合には、上述の判定の代わりに、収束線群の方向に基づいて天地を判定してもよい。通常は、図16の例のように、収束線群の収束点CPが画像の上方向に向いている場合が多い。従って、収束線群の向かう方向に基づいて、画像の上下方向または左右方向を天地方向と判定することが可能である。この場合にも、他の画像的な特徴(例えば画像のコントラストなど)を用いて天方向または地方向を判定してもよい。   When the image includes a convergence line group, the top and bottom may be determined based on the direction of the convergence line group instead of the above determination. Usually, as in the example of FIG. 16, the convergence point CP of the convergence line group is often directed upward in the image. Therefore, it is possible to determine the vertical direction or the horizontal direction of the image as the top-and-bottom direction based on the direction in which the convergence line group is directed. Also in this case, the celestial direction or the ground direction may be determined using other image characteristics (for example, image contrast).

B4.棒状オブジェクトに基づく天地方向判定手順:
図17は、棒状オブジェクトに基づく天地判定手順を示すフローチャートである。棒状オブジェクトとは、ビルディングなどのような長手の被写体を意味している。
B4. Top-and-bottom direction determination procedure based on a bar-shaped object:
FIG. 17 is a flowchart showing the top / bottom determination procedure based on the bar-shaped object. A bar-like object means a long subject such as a building.

ステップS502では、画像特徴情報取得部216が、処理対象画像の各画素の色情報を用いて領域分割処理(領域分離処理)を行なう。具体的には、例えば、HSV色空間のH成分を所定の複数の範囲に予め区分しておき、各範囲のH成分を有する画素で構成される領域を抽出することによって、領域分割を行うことが可能である。この場合に、ある領域内の画素数が極めて少ない(例えば10画素以下)の場合には、その領域が周囲のより大きな領域に吸収されるものとしてもよい。   In step S502, the image feature information acquisition unit 216 performs region division processing (region separation processing) using the color information of each pixel of the processing target image. Specifically, for example, the H component of the HSV color space is divided into a plurality of predetermined ranges in advance, and the region composed of pixels having the H component in each range is extracted to perform region division. Is possible. In this case, when the number of pixels in a certain area is extremely small (for example, 10 pixels or less), the area may be absorbed by a larger surrounding area.

なお、領域分割は、他の方法を用いて行うことも可能である。例えば、処理対象画像を空間微分することによってエッジ画像を求め、このエッジ画像内の閉領域を検出することによって領域分割を行うことも可能である。   It should be noted that the area division can also be performed using other methods. For example, it is possible to obtain an edge image by spatially differentiating the processing target image and to perform region division by detecting a closed region in the edge image.

ステップS504では、画像特徴情報取得部216が、縦横比が所定の値(例えば4倍)以上の領域に対して、棒状オブジェクトとしてのフラグ付けを行なう。図18(A)は、棒状オブジェクトSOBを含む画像G6の例を示している。縦横比Rは、図18(B)に示すように、棒状オブジェクトSOBを包含する矩形の長辺の長さWlongと短辺の長さWshortの比である。   In step S504, the image feature information acquisition unit 216 performs flagging as a bar-shaped object for an area having an aspect ratio of a predetermined value (for example, four times) or more. FIG. 18A shows an example of an image G6 including a rod-shaped object SOB. As shown in FIG. 18B, the aspect ratio R is a ratio of the long side length Wlong and the short side length Wshort of the rectangle including the rod-shaped object SOB.

ステップS506では、天地方向判定部218が、棒状オブジェクトの一方の端が空領域に重なるかどうかの判定を行なう。空領域の抽出処理は、図7のステップS310で説明したものと同じである。図18(A)のように、棒状オブジェクトの一端が空領域に重なっている(または接している)場合には、重なっている端部の方向を上方(天方向)と判定し、判定確率を75%に設定する(ステップS508,S510)。そして、次の棒状オブジェクトがあればステップS512からステップS506に戻り、ステップS506以降の処理を繰り返す。一方、ステップS506において、棒状オブジェクトの両方の端部がいずれも空領域に重ならない場合、または、空領域が存在しない場合には、天地方向不明と判定してステップS600(総合天地判定処理)へ移る。   In step S506, the top / bottom direction determination unit 218 determines whether one end of the bar-shaped object overlaps the sky region. The empty area extraction processing is the same as that described in step S310 in FIG. As shown in FIG. 18A, when one end of the bar-shaped object overlaps (or is in contact with) the empty area, the direction of the overlapping end is determined to be upward (top direction), and the determination probability is 75% is set (steps S508 and S510). If there is a next rod-like object, the process returns from step S512 to step S506, and the processes after step S506 are repeated. On the other hand, if both ends of the rod-shaped object do not overlap the sky area in step S506, or if there is no sky area, it is determined that the top / bottom direction is unknown, and the process proceeds to step S600 (total top / bottom determination processing). Move.

図18(A)の画像G6の場合には、棒状オブジェクトSOBの左側の端部が空領域と重なっているので、画像の左側が天方向であると判定される。図18(C)は、判定された天地方向に応じて回転した画像を示している。   In the case of the image G6 in FIG. 18A, since the left end of the rod-shaped object SOB overlaps with the empty area, it is determined that the left side of the image is the sky direction. FIG. 18C shows an image rotated according to the determined vertical direction.

このように、画像内にビルディングのような棒状オブジェクトがある場合には、その長手方向が天地方向である可能性が高い。従って、上述のように、棒状オブジェクトを用いてかなり正確に天地方向を判定することができる。   Thus, when there is a bar-like object such as a building in the image, there is a high possibility that the longitudinal direction is the vertical direction. Therefore, as described above, it is possible to determine the top-and-bottom direction fairly accurately using the rod-like object.

B5.総合天地判定手順:
図19は、総合天地判定処理の手順を示すフローチャートである。天地方向判定部218は、図3において選択された各特徴を用いた天地方向判定結果を用いて、画像の各端ごと(各辺ごと)に判定確率を加算する(ステップS602,S604)。具体的には、画像の上辺と下辺と左辺と右辺について、各特徴を用いて算出された判定確率を加算する。なお、上述したように、各特徴を用いた判定処理において、天地方向不明の場合には4辺のすべての判定確率が0%に設定されている。また、天方向または地方向と判定されていない辺についても判定確率が0%に設定されている。なお、判定確率の加算は、天方向または地方向のいずれかに関して行われる。この場合に、地方向と判定された辺がある場合には、その対向する辺が天方向と判定されたものと見なされる。本実施例では、天方向に関して判定確率を加算している。
B5. Comprehensive top and bottom judgment procedure:
FIG. 19 is a flowchart illustrating the procedure of the comprehensive top / bottom determination process. The top / bottom direction determination unit 218 uses the top / bottom direction determination result using each feature selected in FIG. 3 to add a determination probability to each end (each side) of the image (steps S602 and S604). Specifically, the determination probabilities calculated using the features are added to the upper side, the lower side, the left side, and the right side of the image. Note that, as described above, in the determination process using each feature, when the top-to-bottom direction is unknown, all determination probabilities for the four sides are set to 0%. In addition, the determination probability is set to 0% for the sides that are not determined to be the celestial direction or the ground direction. Note that the addition of the determination probability is performed with respect to either the celestial direction or the ground direction. In this case, when there is a side determined as the ground direction, it is considered that the opposite side is determined as the top direction. In this embodiment, the determination probability is added with respect to the sky direction.

判定確率の加算がすべて終了すると、ステップS606において、判定確率が最も高い端(辺)を上方(天方向)と最終的に判断し、ステップS608でその結果を出力する。この結果出力としては、最終的に上方と判定された端(辺)を上方にするように画像を回転した結果を出力しても良く、あるいは、あらかじめ各端に番号付けを行なっておき、上方となる端の番号を出力しても良い。   When all of the determination probabilities have been added, in step S606, the end (side) having the highest determination probability is finally determined as upward (upward direction), and the result is output in step S608. As the result output, the result of rotating the image so that the end (side) finally determined to be upward may be output, or the respective ends are numbered in advance, May be output.

このように、本実施例では、複数の特徴についてそれぞれ天地方向とその判定確率を決定し、画像の各辺毎に判定確率を加算し、加算後の判定確率を用いて最終的な天地方向を決定するので、高い精度で天地方向を判定することが可能である。また、天地方向判定に用いる特徴の種類は、ユーザが所定の選択肢の中から任意に選択できるので、関係が少ないと思われる特徴を予め除外して処理を進めることができる。この結果、より精度良く、より短時間で判定結果を得ることが可能である。   In this way, in this embodiment, the top and bottom direction and its determination probability are determined for each of the plurality of features, the determination probability is added for each side of the image, and the final top and bottom direction is determined using the determination probability after the addition. Since it is determined, it is possible to determine the vertical direction with high accuracy. In addition, since the user can arbitrarily select the type of feature used for the top / bottom direction determination from predetermined options, it is possible to proceed by excluding features that seem to have little relationship in advance. As a result, it is possible to obtain the determination result with higher accuracy and in a shorter time.

なお、上述の総合天地判定処理において、各辺の判定確率を加算する代わりに、各特徴を用いて得られた判定確率の中で最も高い値を示す辺を、画像の天地方向(天方向または地方向)として決定するようにしてもよい。但し、判定確率を加算すれば、より確実に正しい天地方向を決定できる可能性がある。   In the above-described comprehensive top / bottom determination process, instead of adding the determination probabilities for each side, the side that indicates the highest value among the determination probabilities obtained using the features is represented by the top / bottom direction of the image (top or bottom direction). It may be determined as (ground direction). However, if the determination probability is added, there is a possibility that the correct top-and-bottom direction can be determined more reliably.

C.変形例:
なお、この発明は上記実施例や実施形態に限られるものではなく、その要旨を逸脱しない範囲において種々の態様において実施することが可能であり、例えば次のような変形も可能である。
C. Variation:
In addition, this invention is not restricted to the said Example and embodiment, It can implement in a various aspect in the range which does not deviate from the summary, For example, the following deformation | transformation is also possible.

C1.変形例1:
上記実施例では、色空間としてHSV色空間を使用していたが、他の任意の色空間を用いて処理を行うことが可能である。
C1. Modification 1:
In the above embodiment, the HSV color space is used as the color space, but it is possible to perform processing using any other color space.

C2.変形例2:
上記実施例では、各特徴を用いた天地方向判定の際に、判定確率を同時に算出していたが、判定確率は必ずしも算出する必要は無い。
C2. Variation 2:
In the above-described embodiment, the determination probability is calculated at the same time when determining the vertical direction using each feature. However, the determination probability is not necessarily calculated.

C3.変形例3:
上記実施例では、画像的な特徴として、人物領域と、空領域・地上領域と、直線と、棒状オブジェクトの4種類を使用していたが、画像的な特徴としては、この一部のみを使用することもでき、また、他の種々の特徴を利用することも可能である。但し、人物領域と空領域とは多くの写真画像で検出されると期待されるので、少なくともこれらの2種類の特徴を利用することが好ましい。
C3. Variation 3:
In the above embodiment, four types of image features are used: a person region, a sky region / ground region, a straight line, and a rod-like object. However, only a part of these are used as image features. It is also possible to use various other features. However, since it is expected that the person area and the sky area are detected in many photographic images, it is preferable to use at least these two types of features.

C4.変形例4:
上記実施例では、電子アルバムを作成する方法および装置を説明したが、本発明による画像の天地方向の判定は、電子アルバムの作成に限らず、他の用途にも利用することも可能である。
C4. Variation 4:
In the above embodiment, the method and apparatus for creating an electronic album has been described. However, the determination of the vertical direction of an image according to the present invention is not limited to the creation of an electronic album, but can be used for other purposes.

本発明の一実施例としての画像処理システムを示す説明図。1 is an explanatory diagram showing an image processing system as one embodiment of the present invention. 実施例における処理手順を示すフローチャート。The flowchart which shows the process sequence in an Example. アルバム作成条件指定のためのユーザインタフェース画面の例を示す説明図。Explanatory drawing which shows the example of the user interface screen for album creation condition designation | designated. アルバム画像の一例を示す説明図。Explanatory drawing which shows an example of an album image. 人物領域に基づく天地判定手順を示すフローチャート。The flowchart which shows the top-and-bottom determination procedure based on a person area. ステップS202の詳細手順を示すフローチャート。The flowchart which shows the detailed procedure of step S202. 人物領域に基づく天地判定処理の内容を示す説明図。Explanatory drawing which shows the content of the top-and-bottom determination process based on a person area. 空・地上領域に基づく天地判定手順を示すフローチャート。The flowchart which shows the top-and-bottom determination procedure based on the sky / ground area. 昼の画像に関する空・地上領域に基づく天地判定処理の内容を示す説明図。Explanatory drawing which shows the content of the top-and-bottom determination process based on the sky and ground area regarding a daytime image. 夜の画像に関する空・地上領域に基づく天地判定処理の内容を示す説明図。Explanatory drawing which shows the content of the top-and-bottom determination process based on the sky and the ground area regarding a night image. 空・地上領域に基づく天地判定手順の変形例を示すフローチャート。The flowchart which shows the modification of the top-and-bottom determination procedure based on the sky / ground area. 図10の処理の内容を示す説明図。Explanatory drawing which shows the content of the process of FIG. 空・地上領域に基づく天地判定手順の他の変形例を示すフローチャート。The flowchart which shows the other modification of the top-and-bottom determination procedure based on the sky and the ground area. 図12の処理の内容を示す説明図。Explanatory drawing which shows the content of the process of FIG. 直線に基づく天地判定手順を示すフローチャート。The flowchart which shows the top-and-bottom determination procedure based on a straight line. 収束直線判定の手順を示すフローチャート。The flowchart which shows the procedure of a convergence straight line determination. 画像全体にわたる直線を含む画像の例を示す説明図。Explanatory drawing which shows the example of the image containing the straight line over the whole image. 収束直線群を含む画像の例を示す説明図。Explanatory drawing which shows the example of the image containing a convergence straight line group. 棒状オブジェクトに基づく天地判定手順を示すフローチャート。The flowchart which shows the top-and-bottom determination procedure based on a rod-shaped object. 棒状オブジェクトに基づく天地判定処理の内容を示す説明図。Explanatory drawing which shows the content of the top-and-bottom determination process based on a rod-shaped object. 総合天地判定処理の手順を示すフローチャート。The flowchart which shows the procedure of a general top-and-bottom determination process.

符号の説明Explanation of symbols

100…デジタルカメラ
200…コンピュータ
210…画像処理部
212…ユーザインタフェース部
214…画像群選択部
216…画像特徴情報取得部
218…天地方向判定部
220…ページ割当部
222…アルバム生成部
224…画像データ出力部
230…画像格納部
300…カラープリンタ
DESCRIPTION OF SYMBOLS 100 ... Digital camera 200 ... Computer 210 ... Image processing part 212 ... User interface part 214 ... Image group selection part 216 ... Image feature information acquisition part 218 ... Top and bottom direction determination part 220 ... Page allocation part 222 ... Album generation part 224 ... Image data Output unit 230 ... Image storage unit 300 ... Color printer

Claims (34)

カラー画像の天地方向を判定する画像処理装置であって、
前記カラー画像の画素値を解析することによって、前記カラー画像の特徴を表す所定の画像特徴情報を取得する特徴情報取得部と、
前記画像特徴情報を利用した判定ルールを用いて前記カラー画像の天地方向を判定する天地方向判定部と、
を有することを特徴とする画像処理装置。
An image processing apparatus for determining a vertical direction of a color image,
A feature information acquisition unit that acquires predetermined image feature information representing features of the color image by analyzing pixel values of the color image;
A top and bottom direction determination unit that determines the top and bottom direction of the color image using a determination rule that uses the image feature information; and
An image processing apparatus comprising:
請求項1記載の画像処理装置であって、
前記天地方向判定部は、前記カラー画像の天地方向とともにその確率を決定し、確率の高い天地方向を採用する、画像処理装置。
The image processing apparatus according to claim 1,
The top / bottom direction determination unit determines the probability together with the top / bottom direction of the color image, and adopts a top / bottom direction with a high probability.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する人物領域を表す人物領域情報を取得し、
前記天地方向判定部は、前記人物領域の天地の向きに応じて前記カラー画像の天地方向を判定する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The feature information acquisition unit acquires person area information representing a person area existing in the color image as the image feature information,
The top / bottom direction determination unit is an image processing apparatus that determines the top / bottom direction of the color image according to a top / bottom direction of the person area.
請求項3記載の画像処理装置であって、
前記特徴情報取得部は、前記人物領域として、前記カラー画像内に存在する肌色領域を検出する、画像処理装置。
The image processing apparatus according to claim 3,
The feature information acquisition unit is an image processing apparatus that detects a skin color area existing in the color image as the person area.
請求項記4載の画像処理装置であって、
前記特徴情報取得部は、肌色と認識する画素値の範囲を、前記カラー画像の平均輝度に応じて変更する、画像処理装置。
An image processing apparatus according to claim 4,
The feature information acquisition unit is an image processing apparatus that changes a range of pixel values recognized as skin color according to an average luminance of the color image.
請求項3ないし5のいずれかに記載の画像処理装置であって、
前記天地方向判定部は、前記肌色領域に隣接する胴体領域の有無を前記天地方向判定に利用する、画像処理装置。
An image processing apparatus according to any one of claims 3 to 5,
The top-and-bottom direction determination unit is an image processing apparatus that uses the presence or absence of a body region adjacent to the skin color region for the top-and-bottom direction determination.
請求項3ないし6のいずれかに記載の画像処理装置であって、
前記特徴情報取得部は、前記人物領域として、前記カラー画像内に存在する人物の顔領域を検出する、画像処理装置。
The image processing apparatus according to any one of claims 3 to 6,
The feature information acquisition unit is an image processing apparatus that detects a face area of a person existing in the color image as the person area.
請求項7記載の画像処理装置であって、
前記特徴情報取得部は、前記カラー画像内に存在する肌色領域を抽出し、抽出された肌色領域の縦横比から前記顔領域となる肌色領域を選択する、画像処理装置。
The image processing apparatus according to claim 7,
The image processing apparatus, wherein the feature information acquisition unit extracts a skin color area existing in the color image, and selects a skin color area to be the face area from an aspect ratio of the extracted skin color area.
請求項8記載の画像処理装置であって、
前記特徴情報取得部は、前記肌色領域の縦横比から前記顔領域の候補を選択し、前記顔領域候補の中で、顔の器官が含まれている領域を前記顔領域として選択する、画像処理装置。
The image processing apparatus according to claim 8, wherein
The feature information acquisition unit selects the face area candidate from the aspect ratio of the skin color area, and selects an area including a facial organ as the face area from the face area candidates. apparatus.
請求項7記載の画像処理装置であって、
前記特徴情報取得部は、肌色領域であって、かつ、顔の器官が含まれている領域を前記顔領域として選択する、画像処理装置。
The image processing apparatus according to claim 7,
The image processing apparatus, wherein the feature information acquisition unit selects an area that is a skin color area and includes a facial organ as the face area.
請求項10または9記載の画像処理装置であって、
前記天地方向判定部は、前記顔領域の中における前記顔の器官の位置関係を前記天地方向判定に利用する、画像処理装置。
The image processing apparatus according to claim 10 or 9, wherein
The top-to-bottom direction determination unit is an image processing device that uses a positional relationship of the facial organs in the face region for the top-to-bottom direction determination.
請求項7ないし11のいずれかに記載の画像処理装置であって、
前記天地方向判定部は、前記顔領域に隣接する頭髪領域の有無を前記天地方向判定に利用する、画像処理装置。
An image processing apparatus according to any one of claims 7 to 11,
The top and bottom direction determination unit is an image processing apparatus that uses the presence or absence of a hair region adjacent to the face region for the top and bottom direction determination.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する天空領域を表す天空領域情報を取得する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The feature information acquisition unit is an image processing apparatus that acquires sky region information representing a sky region existing in the color image as the image feature information.
請求項13記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像の昼夜の判定を行い、
(ii)前記カラー画像が昼に撮影された画像であると判定された場合には、前記カラー画像の平均輝度よりも明るい画素で構成された領域であって、かつ、前記カラー画像の端部に存在し、かつ、青、白、グレイのいずれかに属する色である領域を前記天空領域として検出する、画像処理装置。
The image processing apparatus according to claim 13,
The feature information acquisition unit
(I) Perform day / night determination of the color image,
(Ii) When it is determined that the color image is an image taken in the daytime, the color image is an area composed of pixels brighter than the average luminance of the color image, and an end portion of the color image An image processing apparatus that detects an area that is present in a color and belongs to any one of blue, white, and gray as the sky area.
請求項13記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像を複数の区分領域に分割し、
(ii)各区分領域に対して周波数分析を行うことによって各区分領域の周波数特性を取得し、
(iii)低周波成分を主とする周波数特性を有する区分領域を前記天空領域として検出する、画像処理装置。
The image processing apparatus according to claim 13,
The feature information acquisition unit
(I) dividing the color image into a plurality of divided regions;
(Ii) obtaining frequency characteristics of each segmented region by performing frequency analysis on each segmented region;
(Iii) An image processing apparatus that detects a segmented region having frequency characteristics mainly including a low-frequency component as the sky region.
請求項13ないし15のいずれかに記載の画像処理装置であって、
前記天地方向判定部は、前記天空領域が最も広く存在している箇所に近い画像端部を上方として判定する、画像処理装置。
The image processing apparatus according to any one of claims 13 to 15,
The top / bottom direction determination unit is an image processing device that determines an image edge portion close to a place where the sky region is present most widely as an upper side.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する地上領域を表す地上領域情報を取得する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The feature information acquisition unit is an image processing device that acquires ground region information representing a ground region existing in the color image as the image feature information.
請求項17記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像の昼夜の判定を行い、
(ii)前記カラー画像が夜に撮影された画像であると判定された場合には、前記カラー画像の平均輝度よりも明るい領域、または、所定の輝度以上の高輝度を有する高輝度部分が点在する暗い領域を前記地上領域として検出する、画像処理装置。
The image processing device according to claim 17,
The feature information acquisition unit
(I) Perform day / night determination of the color image,
(Ii) When it is determined that the color image is an image taken at night, an area brighter than the average luminance of the color image or a high luminance part having a high luminance equal to or higher than a predetermined luminance An image processing apparatus for detecting an existing dark area as the ground area.
請求項17記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像を複数の区分領域に分割し、
(ii)各区分領域に対して周波数分析を行うことによって各区分領域の周波数特性を取得し、
(iii)高周波成分を主とする周波数特性を有する区分領域を地上領域として検出する、画像処理装置。
The image processing device according to claim 17,
The feature information acquisition unit
(I) dividing the color image into a plurality of divided regions;
(Ii) obtaining frequency characteristics of each segmented region by performing frequency analysis on each segmented region;
(Iii) An image processing apparatus that detects a segmented area having frequency characteristics mainly including a high-frequency component as a ground area.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像の昼夜の判定を行い、
(ii)前記カラー画像が夜に撮影された画像であると判定された場合には、
前記カラー画像を縦方向に二分割した第1の画像と、横方向に二分割した第2の画像とに関して、分割した2つの領域の輝度コントラストを前記画像特徴情報としてそれぞれ算出し、
前記天地方向判定部は、前記輝度コントラストがより大きな分割方向において、輝度がより高い領域を下方として判定する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The feature information acquisition unit
(I) Perform day / night determination of the color image,
(Ii) If it is determined that the color image is an image taken at night,
For the first image obtained by dividing the color image into two in the vertical direction and the second image divided into two in the horizontal direction, the luminance contrast of the two divided regions is calculated as the image feature information, respectively.
The top-and-bottom direction determination unit is an image processing apparatus that determines a region having a higher luminance as a lower side in a division direction in which the luminance contrast is higher.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像の全体にわたる直線を表す直線情報を取得し、
前記天地方向判定部は、前記画像の上下方向と左右方向とのうちで前記直線となす角度がより大きな方向を天地方向と判定する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The feature information acquisition unit acquires, as the image feature information, straight line information representing a straight line over the entire color image,
The top-to-bottom direction determination unit is an image processing apparatus that determines a top-to-bottom direction as a direction that has a larger angle with the straight line between a vertical direction and a horizontal direction of the image.
請求項21記載の画像処理装置であって、
前記天地方向判定部は、
(i)前記直線を水平線または地平線とみなすとともに、
(ii)前記カラー画像の長手方向と前記直線の方向とが平行から所定の角度範囲にあると判断した場合に、現在の天地関係が正しいと判定する、画像処理装置。
The image processing apparatus according to claim 21, wherein
The top and bottom direction determination unit
(I) Considering the straight line as a horizon or horizon,
(Ii) An image processing apparatus that determines that the current top-to-bottom relationship is correct when it is determined that the longitudinal direction of the color image and the direction of the straight line are within a predetermined angle range from parallel.
請求項21記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、さらに、前記カラー画像内に存在する天空領域を表す天空領域情報を取得し、
前記天地方向判定部は、
(i)前記直線を水平線または地平線とみなすとともに、
(ii)前記水平線または地平線に対して前記天空領域が存在する方向を上方として判定する、画像処理装置。
The image processing apparatus according to claim 21, wherein
The feature information acquisition unit further acquires, as the image feature information, sky region information representing a sky region existing in the color image,
The top and bottom direction determination unit
(I) Considering the straight line as a horizon or horizon,
(Ii) An image processing apparatus that determines that the direction in which the sky region is present is upward with respect to the horizon or the horizon.
請求項21記載の画像処理装置であって、
前記天地方向判定部は、
(i)前記直線を水平線または地平線とみなすとともに、
(ii)前記直線の近傍に所定の輝度以上の高輝度領域が一つのみ存在する場合に、前記直線に対して前記高輝度領域が存在する方向を上方として判定する、画像処理装置。
The image processing apparatus according to claim 21, wherein
The top and bottom direction determination unit
(I) Considering the straight line as a horizon or horizon,
(Ii) An image processing apparatus that, when only one high-brightness area having a predetermined luminance or more exists in the vicinity of the straight line, determines that the direction in which the high-brightness area exists with respect to the straight line is upward.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する3本以上の収束する直線で構成される消失線を表す消失線情報を取得する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The image processing apparatus, wherein the feature information acquisition unit acquires vanishing line information representing vanishing lines composed of three or more converging straight lines existing in the color image as the image feature information.
請求項25記載の画像処理装置であって、
前記天地方向判定部は、前記消失線の両側の輝度コントラストを比較し、輝度が明るい側を上方として判定する、画像処理装置。
The image processing apparatus according to claim 25, wherein
The top-and-bottom direction determination unit is an image processing apparatus that compares luminance contrasts on both sides of the vanishing line and determines that the brighter side is the upper side.
請求項1または2記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、前記カラー画像内に存在する棒状のオブジェクトを表す棒状オブジェクト情報を取得する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The feature information acquisition unit is an image processing apparatus that acquires, as the image feature information, bar-shaped object information representing a bar-shaped object existing in the color image.
請求項27記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像を色情報に基づいて複数の色領域に分離し、
(ii)前記複数の色領域のうちで縦横比が所定の値以上である色領域を前記棒状オブジェクトとして検出する、画像処理装置。
The image processing apparatus according to claim 27, wherein
The feature information acquisition unit
(I) separating the color image into a plurality of color regions based on color information;
(Ii) An image processing apparatus that detects a color area having an aspect ratio equal to or greater than a predetermined value among the plurality of color areas as the rod-like object.
請求項27記載の画像処理装置であって、
前記特徴情報取得部は、
(i)前記カラー画像を空間微分することによりエッジ画像を生成し、
(ii)前記エッジ画像に含まれる閉領域を検出するとともに、
(iii)縦横比が所定の値以上である閉領域を前記棒状オブジェクトとして検出する、画像処理装置。
The image processing apparatus according to claim 27, wherein
The feature information acquisition unit
(I) generating an edge image by spatially differentiating the color image;
(Ii) detecting a closed region included in the edge image;
(Iii) An image processing apparatus that detects a closed region having an aspect ratio equal to or greater than a predetermined value as the rod-like object.
請求項27ないし29のいずれかに記載の画像処理装置であって、
前記特徴情報取得部は、前記画像特徴情報として、さらに、前記カラー画像内に存在する天空領域を表す天空領域情報を取得し、
前記天地方向判定部は、前記棒状オブジェクトの長手方向の片端が前記天空領域に重なっている場合に、前記棒状オブジェクトの長手方向に沿った方向であって前記重なりの存在する方向を上方として判定する、画像処理装置。
30. The image processing apparatus according to claim 27, wherein:
The feature information acquisition unit further acquires, as the image feature information, sky region information representing a sky region existing in the color image,
The top-and-bottom direction determination unit determines that a direction along the longitudinal direction of the bar-shaped object and where the overlap exists is upward when one end in the longitudinal direction of the bar-shaped object overlaps the sky region. , Image processing device.
請求項1または2記載の画像処理装置であって、
前記画像特徴情報取得部は、複数種類の画像特徴情報を取得し、
前記天地方向判定部は、前記複数種類の画像特徴情報を用いて前記カラー画像の天地方向を判定する、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The image feature information acquisition unit acquires a plurality of types of image feature information,
The top-to-bottom direction determination unit is an image processing apparatus that determines the top-to-bottom direction of the color image using the plurality of types of image feature information.
請求項31記載の画像処理装置であって、
前記天地方向判定部は、
(i)各種類の画像特徴情報を用いて前記カラー画像の天地方向とその確率とをそれぞれ決定するとともに、
(ii)各種類の画像特徴情報を用いて得られた天地方向とその確率とを総合して前記カラー画像の天地方向を決定する、画像処理装置。
The image processing apparatus according to claim 31, wherein
The top and bottom direction determination unit
(I) determining the vertical direction of the color image and its probability using each type of image feature information,
(Ii) An image processing apparatus that determines the vertical direction of the color image by combining the vertical direction obtained using each type of image feature information and the probability thereof.
カラー画像の天地を判定する方法であって、
(a)前記カラー画像の画素値を解析することによって、前記カラー画像の特徴を表す所定の画像特徴情報を取得する工程と、
(b)前記画像特徴情報を利用した判定ルールを用いて前記カラー画像の天地方向を判定する工程と、
を備えることを特徴とする画像天地判定方法。
A method for determining the top and bottom of a color image,
(A) obtaining predetermined image feature information representing features of the color image by analyzing pixel values of the color image;
(B) determining the vertical direction of the color image using a determination rule using the image feature information;
An image top-and-bottom determination method comprising:
カラー画像の天地を判定するためのコンピュータプログラムであって、
前記カラー画像の画素値を解析することによって、前記カラー画像の特徴を表す所定の画像特徴情報を取得する特徴情報取得機能と、
前記画像特徴情報を利用した判定ルールを用いて前記カラー画像の天地方向を判定する天地方向判定機能と、
をコンピュータに実現させるコンピュータプログラム。
A computer program for determining the top and bottom of a color image,
A feature information acquisition function for acquiring predetermined image feature information representing features of the color image by analyzing pixel values of the color image;
A top / bottom direction determination function for determining the top / bottom direction of the color image using a determination rule using the image feature information;
A computer program that causes a computer to realize
JP2004059193A 2004-03-03 2004-03-03 Vertical direction decision of image Pending JP2005250778A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004059193A JP2005250778A (en) 2004-03-03 2004-03-03 Vertical direction decision of image

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004059193A JP2005250778A (en) 2004-03-03 2004-03-03 Vertical direction decision of image

Publications (1)

Publication Number Publication Date
JP2005250778A true JP2005250778A (en) 2005-09-15

Family

ID=35031210

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004059193A Pending JP2005250778A (en) 2004-03-03 2004-03-03 Vertical direction decision of image

Country Status (1)

Country Link
JP (1) JP2005250778A (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008139929A1 (en) * 2007-05-08 2008-11-20 Nec Corporation Image direction judging method, image direction judging device and program
WO2009096524A1 (en) * 2008-01-31 2009-08-06 Nec Corporation Method, device, and program for judging image orientation
JP2010079102A (en) * 2008-09-26 2010-04-08 Xing Inc Karaoke device
WO2010052830A1 (en) * 2008-11-06 2010-05-14 日本電気株式会社 Image orientation determination device, image orientation determination method, and image orientation determination program
JP2010157969A (en) * 2009-01-05 2010-07-15 Canon Inc Image capturing apparatus, object detecting method and program
JP2010244330A (en) * 2009-04-07 2010-10-28 Nikon Corp Image performance program and image performance device
WO2019111375A1 (en) * 2017-12-07 2019-06-13 圭史朗 金森 Monitoring device, monitoring system, monitoring method, and monitoring program
JP2019164450A (en) * 2018-03-19 2019-09-26 株式会社Screenホールディングス Image processing method, computer program and recording medium

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008139929A1 (en) * 2007-05-08 2008-11-20 Nec Corporation Image direction judging method, image direction judging device and program
JP5224069B2 (en) * 2007-05-08 2013-07-03 日本電気株式会社 Image orientation determination method, image orientation determination apparatus, and program
WO2009096524A1 (en) * 2008-01-31 2009-08-06 Nec Corporation Method, device, and program for judging image orientation
JP2010079102A (en) * 2008-09-26 2010-04-08 Xing Inc Karaoke device
US8442351B2 (en) 2008-11-06 2013-05-14 Nec Corporation Image orientation determination device, image orientation determination method, and image orientation determination program
WO2010052830A1 (en) * 2008-11-06 2010-05-14 日本電気株式会社 Image orientation determination device, image orientation determination method, and image orientation determination program
JP5527213B2 (en) * 2008-11-06 2014-06-18 日本電気株式会社 Image orientation determination apparatus, image orientation determination method, and image orientation determination program
JP2010157969A (en) * 2009-01-05 2010-07-15 Canon Inc Image capturing apparatus, object detecting method and program
JP2010244330A (en) * 2009-04-07 2010-10-28 Nikon Corp Image performance program and image performance device
WO2019111375A1 (en) * 2017-12-07 2019-06-13 圭史朗 金森 Monitoring device, monitoring system, monitoring method, and monitoring program
JP2019164450A (en) * 2018-03-19 2019-09-26 株式会社Screenホールディングス Image processing method, computer program and recording medium
WO2019181072A1 (en) * 2018-03-19 2019-09-26 株式会社Screenホールディングス Image processing method, computer program, and recording medium
JP7079631B2 (en) 2018-03-19 2022-06-02 株式会社Screenホールディングス Image processing methods, computer programs and recording media
US11430130B2 (en) 2018-03-19 2022-08-30 SCREEN Holdings Co., Ltd. Image processing method and computer-readable recording medium having recorded thereon image processing program

Similar Documents

Publication Publication Date Title
US8565525B2 (en) Edge comparison in segmentation of video sequences
JP5538909B2 (en) Detection apparatus and method
US6912313B2 (en) Image background replacement method
US8077969B2 (en) Contour finding in segmentation of video sequences
US8126268B2 (en) Edge-guided morphological closing in segmentation of video sequences
US7362918B2 (en) System and method for de-noising multiple copies of a signal
JP5432714B2 (en) Composition analysis method, image apparatus having composition analysis function, composition analysis program, and computer-readable recording medium
CN107808136A (en) Image processing method, device, readable storage medium storing program for executing and computer equipment
US20090028432A1 (en) Segmentation of Video Sequences
US20090219379A1 (en) Average Calculation in Color Space, Particularly for Segmentation of Video Sequences
CN108537782B (en) Building image matching and fusing method based on contour extraction
US20110268359A1 (en) Foreground/Background Segmentation in Digital Images
US10249029B2 (en) Reconstruction of missing regions of images
JP2007504719A (en) System and method for detecting and correcting red eyes in an image suitable for embedded applications
JP2013025650A (en) Image processing apparatus, image processing method, and program
JP5818552B2 (en) Image processing apparatus, image processing method, and program
JP5864936B2 (en) Image processing apparatus, image processing method, and program
JP2009211490A (en) Image recognition method and image recognition device
JP4599110B2 (en) Image processing apparatus and method, imaging apparatus, and program
JP2005250778A (en) Vertical direction decision of image
CN109064431B (en) Picture brightness adjusting method, equipment and storage medium thereof
EP2890109A1 (en) Method for sorting a group of images of a database and method for color correcting an image, corresponding devices, computer program and non-transitory computer-readable medium
CN113781330A (en) Image processing method, device and electronic system
JP6118295B2 (en) Marker embedding device, marker detection device, method, and program
JP2002208013A (en) Device for extracting image area and method for the same