JP2021140429A - Three-dimentional model generation method - Google Patents
Three-dimentional model generation method Download PDFInfo
- Publication number
- JP2021140429A JP2021140429A JP2020037165A JP2020037165A JP2021140429A JP 2021140429 A JP2021140429 A JP 2021140429A JP 2020037165 A JP2020037165 A JP 2020037165A JP 2020037165 A JP2020037165 A JP 2020037165A JP 2021140429 A JP2021140429 A JP 2021140429A
- Authority
- JP
- Japan
- Prior art keywords
- voxel
- camera
- point cloud
- voxels
- data
- 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
Links
Images
Abstract
Description
本発明は、3Dモデルを生成する方法に関する。 The present invention relates to a method of generating a 3D model.
従来、ドローンや車両に搭載されたカメラで動画を撮影し、撮影した動画を基に3D点群データを生成する方法が知られている。この3D点群データの利用方法として、例えば特許文献1には、3次元点群を解析することにより、ポリゴンモデルを精度良く生成する方法が記載されている。
Conventionally, there is known a method of shooting a moving image with a camera mounted on a drone or a vehicle and generating 3D point cloud data based on the shot moving image. As a method of using this 3D point cloud data, for example,
3D点群データの他の利用方法として、異常箇所を検知するというものがある。この利用方法は、点検時の監視対象物を表す3D点群データを、正常時の監視対象物を表す3D点群データと比較し、その相違点を異常箇所として検知するというものである。この利用方法では、一般に、点群の距離ベースで類似度を判定する方法が用いられる。 Another method of using the 3D point cloud data is to detect an abnormal part. In this usage method, the 3D point cloud data representing the monitored object at the time of inspection is compared with the 3D point cloud data representing the monitored object at the time of normal operation, and the difference is detected as an abnormal part. In this usage method, a method of determining the similarity based on the distance of a point cloud is generally used.
しかし、3D点群データを用いた異常検知には、オクルージョン問題が存在する。ここでオクルージョン問題とは、3D点群データにより表される3D点群のうち、点が存在しない領域に、そもそも物体が存在しないのか、それとも物体が壁等により遮蔽されて撮影することができず、その結果、その領域に物体が存在するのか否かが不明であるのかを区別することができないという問題である。仮に、壁等により遮蔽されて物体が撮影することができなかったとした場合、その後に当該遮蔽物が撤去されると、当該物体は従前から存在していたにもかかわらず、異常箇所として検知されてしまうことになる。 However, there is an occlusion problem in abnormality detection using 3D point cloud data. Here, the occlusion problem is that there is no object in the area where the point does not exist in the 3D point cloud represented by the 3D point cloud data, or the object is blocked by a wall or the like and cannot be photographed. As a result, it is not possible to distinguish whether or not an object exists in the area. If the object could not be photographed because it was shielded by a wall or the like, and then the object was removed, the object was detected as an abnormal part even though it had existed before. Will end up.
本発明は、このような事情に鑑みてなされたものであり、物体の存否が不明である領域を識別可能な3Dモデルを生成することを目的とする。 The present invention has been made in view of such circumstances, and an object of the present invention is to generate a 3D model capable of identifying a region where the existence or nonexistence of an object is unknown.
上記の課題を解決するため、本発明に係る3Dモデル生成方法は、コンピュータにより実行される3Dモデル生成方法であって、監視対象物を多数の地点から連続的にカメラで撮影することにより生成された画像群に基づいて、世界座標系で表される点群であって、前記監視対象物の立体形状を表す点群を設定する第1ステップと、前記世界座標系で表されるボクセル群であって、前記点群により表される立体形状の領域を占めるボクセル群を設定する第2ステップと、前記画像群に含まれる第1の画像の画素群の各々について、画像座標系で表される座標値を前記世界座標系で表される座標値に変換する第3ステップと、それぞれ座標値が変換された前記画素群の各々について、当該画素と前記カメラを通るカメラ視線直線を特定する第4ステップと、前記特定されたカメラ視線直線の各々について、当該カメラ視線直線が前記ボクセル群のうちの複数のボクセルと交差する場合に、当該複数のボクセルのうち、前記点群を構成する点を所定数以上含むボクセルであって、前記カメラに最も近いボクセルを第1のカテゴリに分類する一方で、その他のボクセルを第2のカテゴリに分類する第5ステップとを含み、前記第1のカテゴリは、前記第1のカテゴリに分類されたボクセルが占める領域に物体が存在することを示し、前記第2のカテゴリは、前記第2のカテゴリに分類されたボクセルが占める領域に物体が存在するか否かが不明であることを示すことを特徴とする。 In order to solve the above problems, the 3D model generation method according to the present invention is a 3D model generation method executed by a computer, and is generated by continuously photographing a monitored object from a large number of points with a camera. The first step of setting a point group representing the three-dimensional shape of the monitored object, which is a point group represented by the world coordinate system based on the image group, and a voxel group represented by the world coordinate system. Therefore, each of the second step of setting the voxel group occupying the area of the three-dimensional shape represented by the point group and the pixel group of the first image included in the image group is represented by the image coordinate system. The third step of converting the coordinate values into the coordinate values represented by the world coordinate system, and the fourth step of specifying the camera line-of-sight straight line passing through the pixel and the camera for each of the pixel groups to which the coordinate values have been converted. For each of the step and the specified camera line-of-sight line, when the camera line-of-sight line intersects a plurality of voxels in the voxel group, a point constituting the point group among the plurality of voxels is determined. The first category includes a fifth step of classifying the voxels containing a number or more and closest to the camera into the first category, while classifying the other voxels into the second category. Indicates that an object exists in the area occupied by the voxels classified into the first category, and the second category indicates whether or not the object exists in the area occupied by the voxels classified into the second category. Is characterized by indicating that is unknown.
好ましい態様において、前記第5ステップでは、前記特定されたカメラ視線直線の各々について、当該カメラ視線直線が、前記ボクセル群に含まれるボクセルであって、前記点群を構成する点を前記所定数以上含まないボクセルと交差する場合に、当該ボクセルを第3のカテゴリに分類し、前記第3のカテゴリは、前記第3のカテゴリに分類されたボクセルが占める領域に物体が存在しないことを示す。 In a preferred embodiment, in the fifth step, for each of the specified camera line-of-sight lines, the camera line-of-sight line is a voxel included in the voxel group, and the number of points constituting the point cloud is equal to or more than the predetermined number. When intersecting with a voxel that does not include, the voxel is classified into a third category, and the third category indicates that there is no object in the area occupied by the voxels classified into the third category.
さらに好ましい態様において、前記第3ステップでは、前記画像群に含まれる複数の画像の画素群の各々について、前記画像座標系で表される座標値を前記世界座標系で表される座標値に変換する。 In a further preferred embodiment, in the third step, the coordinate values represented by the image coordinate system are converted into the coordinate values represented by the world coordinate system for each of the pixel groups of the plurality of images included in the image group. do.
さらに好ましい態様において、前記3Dモデル生成方法は、それぞれカテゴリに分類された前記ボクセル群と、それぞれカテゴリに分類された他のボクセル群の間で、座標値が共通するボクセル同士のカテゴリを比較し、当該比較の結果を示す情報を出力する第6ステップをさらに含む。 In a more preferred embodiment, the 3D model generation method compares the categories of voxels having a common coordinate value between the voxel group classified into each category and another voxel group classified into each category. A sixth step of outputting information indicating the result of the comparison is further included.
本発明によれば、物体の存否が不明である領域を識別可能な3Dモデルを生成することができる。 According to the present invention, it is possible to generate a 3D model capable of identifying a region where the existence or nonexistence of an object is unknown.
1.実施形態
本発明の一実施形態に係る異常検知システム1について図面を参照して説明する。本実施形態に係る異常検知システム1は、監視対象物の3Dモデルを生成し、この監視対象物の正常時の3Dモデルと比較することで、当該監視対象物の異常を検知するためのシステムである。この異常検知システム1は、1以上の情報処理装置により構成される。
1. 1. Embodiment An
図1は、この異常検知システム1の機能構成を示すブロック図である。同図に示す異常検知システム1は、画像データ記憶部101、点群生成部102、点群データ記憶部103、参照点群データ記憶部104、レジストレーション部105、ボクセル化部106、ボクセルデータ記憶部107、カメラ属性データ記憶部108、画素位置推定部109、画素位置データ記憶部110、ラベル更新部111、参照ボクセルデータ記憶部112及びボクセル比較部113という機能を備える。
FIG. 1 is a block diagram showing a functional configuration of the
これらの機能のうち、各種の記憶部は、HDD等の記憶装置により実現される。その他の機能は、CPU等の演算処理装置が、記憶装置に記憶されている異常検知プログラムを実行することにより実現される。 Among these functions, various storage units are realized by a storage device such as an HDD. Other functions are realized by an arithmetic processing unit such as a CPU executing an abnormality detection program stored in the storage device.
以下、これらの機能を用いて実行される異常検知処理について説明する。図2は、この異常検知処理を示すフロー図である。 Hereinafter, the abnormality detection process executed by using these functions will be described. FIG. 2 is a flow chart showing this abnormality detection process.
異常検知システム1の点群生成部102は、画像データ記憶部101に記憶されている画像データセットD1に基づいて、監視対象物の立体形状を表す点群データD2を生成する(ステップSa1)。ここで、画像データ記憶部101に記憶される画像データセットD1は、監視対象物を点検時に多数の地点から連続的にカメラで撮影することにより生成された画像データのセットである。言い換えると、動画データである。この画像データセットD1は、例えば、航空機や車両等の移動体に取り付けられたカメラにより生成される。
The point
点群生成部102は、このステップSa1において、具体的には、SfM(Structure from Motion)及びMVS(Multi-view Stereo)技術を用いて、画像データセットD1から、監視対象物の立体形状を表す3D点群を復元する。3D点群を復元すると、復元した3D点群の相対座標値を、利用者により指定された地上基準点を基に世界座標値に変換することで、点群データD2を生成する。
In this step Sa1, the point
図3は、この点群データD2の一例を示す図である。同図に示す点群データD2は、点群を構成する各点の点ID、座標値及び色情報により構成されている。ここで、点IDは点の識別情報であり、座標値は世界座標系の座標値であり、色情報はRGB値である。 FIG. 3 is a diagram showing an example of this point cloud data D2. The point cloud data D2 shown in the figure is composed of point IDs, coordinate values, and color information of each point constituting the point cloud. Here, the point ID is the point identification information, the coordinate value is the coordinate value of the world coordinate system, and the color information is the RGB value.
図4は、この点群データD2により表される3D点群の一例を示す図である。同図に示す3D点群PGの各点の位置は、世界座標値(X,Y,Z)により表される。 FIG. 4 is a diagram showing an example of a 3D point cloud represented by the point cloud data D2. The position of each point of the 3D point cloud PG shown in the figure is represented by the world coordinate values (X, Y, Z).
点群生成部102は、点群データD2を生成すると、点群データ記憶部103に記憶する。
When the point
なお、この点群生成部102は、例えば、Pix4D(登録商標)mapperを実行することにより実現される。
The
点群データD2が生成されると、レジストレーション部105は、ICP(Iterative Closest Point)アルゴリズムを用いて、生成された点群データD2と、参照点群データ記憶部104に予め記憶されている参照点群データD3の位置合わせを行う(ステップSa2)。ここで、参照点群データ記憶部104に予め記憶される参照点群データD3は、正常時の監視対象物の立体形状を表す3D点群のデータである。この参照点群データD3のデータ構成は、図3に例示した点群データD2と同様である。
When the point cloud data D2 is generated, the
レジストレーション部105は、具体的には、点群データD2と参照点群データD3のずれ量を算出し、算出したずれ量を最小化するように点群データD2の各点の座標値を補正する。
Specifically, the
位置合わせが完了すると、ボクセル化部106は、点群データD2に基づいてボクセルデータD4を生成する(ステップSa3)。図5は、このボクセルデータ生成処理を示すフロー図である。
When the alignment is completed, the
同図に示すボクセルデータ生成処理において、ボクセル化部106は、点群データD2の座標値Xの最大値及び最小値、座標値Yの最大値及び最小値、並びに座標値Zの最大値及び最小値を特定する(ステップSb1)。言い換えると、点群データD2により表される立体形状に外接する直方体の長さ、幅及び高さを特定する。直方体の長さ等を特定すると、世界座標空間を分割するボクセル群であって、少なくとも上記の直方体の領域を占めるボクセル群を設定する(ステップSb2)。このボクセル群を構成する各ボクセルは、予め定められたサイズを有する。また、このボクセル群が形成する直方体の各面は、世界座標系のいずれかの座標軸と平行である。
In the voxel data generation process shown in the figure, the
図6は、このボクセル群の一例を示す図である。同図に示すボクセル群は、27個のボクセルからなり、全体で立方体CBを構成している。このボクセル群により構成される立方体CBは、点群データD2により表される3D点群PGの領域を占める。また、この立方体CBは、世界座標系のいずれかの座標軸と平行な面を有する。例えば、図6に示す面PL1は、X軸と平行である。 FIG. 6 is a diagram showing an example of this voxel group. The voxel group shown in the figure is composed of 27 voxels, and constitutes a cube CB as a whole. The cube CB composed of this voxel group occupies the region of the 3D point cloud PG represented by the point cloud data D2. Further, this cube CB has a plane parallel to any coordinate axis of the world coordinate system. For example, the plane PL1 shown in FIG. 6 is parallel to the X axis.
ボクセル群の設定後、ボクセル化部106は、設定したボクセル群についてボクセルデータD4を生成する(ステップSb3)。図7は、このボクセルデータD4の一例を示す図である。同図に示すボクセルデータD4は、ボクセル群を構成する各ボクセルのインデックス、ラベル及び点数により構成されている。ここで、インデックスは、ボクセルを識別するための世界座標系の座標値である。より具体的には、ボクセルを構成する8個の頂点のうち、座標値Yが最大であり、座標値Zが最小である頂点の座標値である。例えば、図6に示すボクセルVX1のインデックスは、頂点PT1の座標値である。
After setting the voxel group, the
ラベルは、ボックスが占める領域に物体が存在するか否か、又は物体の存否が不明であるかを示す情報である。このラベルには、「unknown」、「empty」及び「occupancy」の3種類がある。このうち、ラベル「unknown」は、ボクセルが占める領域が壁等により遮蔽されて撮影することができず、その結果、その領域に物体が存在するか否かが不明であることを示す。このラベル「unknown」は初期値である。ラベル「empty」は、ボクセルが占める領域に物体が存在しないことを示す。ラベル「occupancy」は、ボクセルが占める領域に物体が存在することを示す。 The label is information indicating whether or not an object exists in the area occupied by the box, or whether or not the existence or nonexistence of the object is unknown. There are three types of labels: "unknown", "empty" and "occupancy". Of these, the label "unknown" indicates that the area occupied by the voxels is blocked by a wall or the like and cannot be photographed, and as a result, it is unknown whether or not an object exists in that area. This label "unknown" is the initial value. The label "empty" indicates that there are no objects in the area occupied by the voxels. The label "occupancy" indicates that the object is in the area occupied by the voxels.
点数は、点群データD2を構成する点のうち、ボクセルに含まれる点の数である。 The score is the number of points included in the voxel among the points constituting the point cloud data D2.
ボクセル化部106は、ボクセルデータD4を生成すると、ボクセルデータ記憶部107に記憶する。
When the
ボクセルデータ生成処理が完了すると、画素位置推定部109は、画像データセットD1を構成する各画像データについて、画像を構成する各画素の世界座標値を推定する(ステップSa4)。より具体的には、画像を構成する各画素の画像座標値を世界座標値に変換する。ここで、画像座標値とは、画像座標系で表された平面上の位置を示す座標値である。
When the voxel data generation process is completed, the pixel
図8は、画像データにより表される画像の一例を示す図である。同図に示す画像IMは、監視対象物をカメラCAで撮影することにより生成された画像である。この画像IMに写る監視対象物は、同図において立方体CBの位置に配置されている。この画像IMには、画像座標系が定義されている。この画像座標系は、原点を左上隅とし、水平方向に延びるU軸と、垂直方向に延びるV軸とを有する座標系である。 FIG. 8 is a diagram showing an example of an image represented by image data. The image IM shown in the figure is an image generated by photographing the monitored object with the camera CA. The monitored object shown in this image IM is arranged at the position of the cube CB in the figure. An image coordinate system is defined in this image IM. This image coordinate system is a coordinate system having a U-axis extending in the horizontal direction and a V-axis extending in the vertical direction with the origin as the upper left corner.
図9は、画素位置推定部109により実行される座標変換処理を示すフロー図である。
FIG. 9 is a flow chart showing a coordinate conversion process executed by the pixel
同図に示す座標変換処理において、画素位置推定部109は、画像データセットD1の中から画像データを選択する(ステップSc1)。画像データを選択すると、カメラ属性データ記憶部108に記憶されているカメラ属性データD5を参照して、選択した画像データに対応するカメラのパラメータを特定する(ステップSc2)。ここで、カメラ属性データ記憶部108により記憶されるカメラ属性データD5は、上記の画像データセットD1を生成したカメラのパラメータを示すデータである。
In the coordinate conversion process shown in the figure, the pixel
図10は、このカメラ属性データD5の一例を示す図である。同図に示すカメラ属性データD5は、画像データセットD1を構成する画像データの画像IDと、当該画像データを生成した際のカメラのパラメータの複数の組により構成されている。ここで、カメラのパラメータには、内部パラメータとして、焦点距離及び画像中心、外部パラメータとして、回転軸角度及び平行移動行列が含まれている。 FIG. 10 is a diagram showing an example of the camera attribute data D5. The camera attribute data D5 shown in the figure is composed of an image ID of the image data constituting the image data set D1 and a plurality of sets of camera parameters when the image data is generated. Here, the camera parameters include the focal length and the center of the image as internal parameters, and the rotation axis angle and the translation matrix as external parameters.
画素位置推定部109は、パラメータを特定すると、選択した画像データから画素を選択する(ステップSc3)。画素を選択すると、選択した画素の画像座標値と、特定したパラメータを以下の式(1)に代入して、当該画素の世界座標値を算出する(ステップSc4)。
画素位置推定部109は、世界座標値を算出すると、算出した世界座標値を画素位置データ記憶部110に記憶する(ステップSc5)。その際、算出した世界座標値を、当該画素の画像座標値と、選択した画像データの画像IDとに対応付けて記憶する。ここで、画素位置データ記憶部110は、画素位置データD6を記憶する。図11は、画素位置データD6の一例を示す図である。同図に示す画素位置データD6は、画像IDと、画素の画像座標値及び世界座標値とにより構成されている。
When the pixel
世界座標値の記憶が完了すると、未選択の画素があるか否かを判定する(ステップSc6)。この判定の結果、未選択の画素がある場合には(ステップSc6のYES)、ステップSc3に戻る。一方、未選択の画素がない場合には(ステップSc6のNO)。未選択の画像データがあるか否かを判定する(ステップSc7)。この判定の結果、未選択の画像データがある場合には(ステップSc7のYES)、ステップSc1に戻る。一方、未選択の画像データがない場合には(ステップSc7のNO)、本座標変換処理を終了する。本座標変換処理の結果、画素位置データD6が生成される。 When the storage of the world coordinate values is completed, it is determined whether or not there are unselected pixels (step Sc6). As a result of this determination, if there are unselected pixels (YES in step Sc6), the process returns to step Sc3. On the other hand, when there are no unselected pixels (NO in step Sc6). It is determined whether or not there is unselected image data (step Sc7). As a result of this determination, if there is unselected image data (YES in step Sc7), the process returns to step Sc1. On the other hand, if there is no unselected image data (NO in step Sc7), the coordinate conversion process ends. As a result of this coordinate conversion process, pixel position data D6 is generated.
座標変換処理が完了すると、ラベル更新部111は、画像データセットD1を構成する各画像データの各画素について、画素とカメラ中心を通るカメラ視線直線を算出し、ボクセルデータD4により表されるボクセルのうち、このカメラ視線直線と交差するボクセルのラベルを更新する処理を実行する(ステップSa5)。図12は、このラベル更新処理を示すフロー図である。
When the coordinate conversion process is completed, the
同図に示すラベル更新処理において、ラベル更新部111は、画像データセットD1の中から画像データを選択する(ステップSd1)。画像データを選択すると、カメラ属性データ記憶部108に記憶されているカメラ属性データD5を参照して、選択した画像データに対応するカメラの座標値を特定する(ステップSd2)。カメラの座標値を特定すると、特定した座標値が、ボクセルデータD4により表されるボクセル群に含まれているか否かを判定する(ステップSd3)。言い換えると、ボクセル群が全体で構成する直方体にカメラが含まれているか否かを判定する。その際、ラベル更新部111は、以下の条件式(2)を満たすか否かを判定する。
この条件式(2)を満たさない場合、すなわち、直方体にカメラが含まれない場合には(ステップSd3のNO)、第1の更新処理を実行する(ステップSd4)。図13は、直方体にカメラが含まれていない状態の一例を示す図である。同図に示すカメラCAは、立方体CBの外部に存在する。一方、この条件式(2)を満たす場合、すなわち、直方体にカメラが含まれる場合には(ステップSd3のYES)、第2の更新処理を実行する(ステップSd5)。図14は、直方体にカメラが含まれている状態の一例を示す図である。同図に示すカメラCAは、立方体CBの内部に存在する。 If the conditional expression (2) is not satisfied, that is, if the rectangular parallelepiped does not include the camera (NO in step Sd3), the first update process is executed (step Sd4). FIG. 13 is a diagram showing an example of a state in which the rectangular parallelepiped does not include a camera. The camera CA shown in the figure exists outside the cube CB. On the other hand, when the conditional expression (2) is satisfied, that is, when the rectangular parallelepiped includes the camera (YES in step Sd3), the second update process is executed (step Sd5). FIG. 14 is a diagram showing an example of a state in which a camera is included in a rectangular parallelepiped. The camera CA shown in the figure exists inside the cube CB.
第1又は第2の更新処理が完了すると、未選択の画像データがあるか否かを判定する(ステップSd6)。この判定の結果、未選択の画像データがある場合には(ステップSd6のYES)、ステップSd1に戻る。一方、未選択の画像データがない場合には(ステップSd6のNO)、本ラベル更新処理を終了する。 When the first or second update process is completed, it is determined whether or not there is unselected image data (step Sd6). As a result of this determination, if there is unselected image data (YES in step Sd6), the process returns to step Sd1. On the other hand, if there is no unselected image data (NO in step Sd6), the label update process ends.
次に、第1の更新処理について説明する。図15は、この第1の更新処理を示すフロー図である。 Next, the first update process will be described. FIG. 15 is a flow chart showing the first update process.
同図に示す第1の更新処理において、ラベル更新部111は、ステップSd1で選択した画像データから画素を選択する(ステップSe1)。画素を選択すると、画素位置データD6を参照して、選択した画素の座標値(具体的には、世界座標値)を特定する(ステップSe2)。座標値を特定すると、特定した座標値と、ステップSd2で特定したカメラの座標値を通るカメラ視線直線を算出する(ステップSe3)。その際、ラベル更新部111は、画素とカメラの座標値を以下の式(3)に代入することによりカメラ視線直線を算出する。
ここで算出されるカメラ視線直線は、例えば、図8に示すカメラ視線直線L1に相当する。 The camera line-of-sight line calculated here corresponds to, for example, the camera line-of-sight line L1 shown in FIG.
カメラ視線直線を算出すると、算出したカメラ視線直線が交差する、上記直方体の面を算出する(ステップSe4)。ここで、上記直方体の各面は、以下の式(4)〜(9)により表される。
ラベル更新部111は、算出したカメラ視線直線の式と、式(4)〜(9)のいずれか1つの連立方程式を順番に解くことで、直方体の各面について媒介変数tを算出する。その結果、いずれの面についても、算出された媒介変数tの分母が「0」である場合、すなわち、カメラ視線直線が直方体と交差しない場合には(ステップSe5のNO)、ステップSe19に進む。一方、いずれかの面について、算出された媒介変数tの分母が「0」でない場合、すなわち、カメラ視線直線が直方体と交差する場合には(ステップSe5のYES)、媒介変数tが「0」でない面(言い換えると、カメラ視線直線が交差する面)の数が「2」であるか否かを判定する(ステップSe6)。この判定の結果、媒介変数tが「0」でない面の数が「2」である場合には(ステップSe6のYES)、より小さい媒介変数tが算出された面を入口面とする(ステップSe7)。言い換えると、カメラにより近い面を入口面とする。ここで特定される入口面は、例えば、図8に示す面PL2に相当する。一方、媒介変数tが「0」でない面の数が「2」より多い場合には(ステップSe6のNO)、すなわち、カメラ視線直線が直方体の頂点と交差する場合には、カメラ視線直線が交差する任意の面を入口面とする(ステップSe8)。
The
入口面を特定すると、特定した入口面と、これの反対面と、入口面と反対面の間に存在する複数の断面の中からいずれかの面を選択する(ステップSe9)。その際、ラベル更新部111は、カメラに近い面から順に選択する。ここで、次のステップの説明に進む前に、反対面と断面について説明する。
When the entrance surface is specified, one of the specified entrance surfaces, the opposite surface thereof, and a plurality of cross sections existing between the entrance surface and the opposite surface is selected (step Se9). At that time, the
図16は、ボクセル群の一例を示す平面図である。同図に示すボクセル群は、9個のボクセルからなり、全体で直方体RPを構成している。このボクセル群により構成される直方体RPは、カメラ視線直線L2と交差している。カメラ視線直線L2と交差する面のうち、面PL3が入口面に相当する。そして、この入口面に平行な面PL4が反対面に相当する。そして、この入口面と反対面の間に、断面CS1及びCS2が存在する。これらの断面CS1及びCS2は、入口面及び反対面と平行であり、かつ、ボクセルの長さ間隔で配置された断面である。 FIG. 16 is a plan view showing an example of the voxel group. The voxel group shown in the figure is composed of nine voxels, and constitutes a rectangular parallelepiped RP as a whole. The rectangular parallelepiped RP composed of this voxel group intersects the camera line-of-sight line L2. Of the surfaces that intersect the camera line-of-sight line L2, the surface PL3 corresponds to the entrance surface. The surface PL4 parallel to the entrance surface corresponds to the opposite surface. Then, the cross sections CS1 and CS2 exist between the entrance surface and the opposite surface. These cross sections CS1 and CS2 are cross sections that are parallel to the entrance surface and the opposite surface and are arranged at voxel length intervals.
ラベル更新部111は、上記の複数の面の中からいずれかの面を選択すると、選択した面が入口面であるか否かを判定する(ステップSe10)。この判定の結果、選択した面が入口面である場合には(ステップSe10のYES)、ステップSe11をスキップして、ステップSe12に進む。一方、選択した面が入口面でない場合には(ステップSe10のNO)、選択した面がカメラ視線直線と交差するか否かを判定する(ステップSe11)。具体的には、選択した面の式と、算出したカメラ視線直線の式の連立方程式を解くことで、当該面について媒介変数tを算出する。この判定の結果、算出した媒介変数tの分母が「0」である場合、すなわち、選択した面がカメラ視線直線と交差しない場合には(ステップSe11のNO)、ステップSe19に進む。一方、算出した媒介変数tの分母が「0」でない場合、すなわち、選択した面がカメラ視線直線と交差する場合には(ステップSe11のYES)、交点を算出する(ステップSe12)。具体的には、算出した媒介変数tを、算出したカメラ視線直線に代入することで交点を算出する。
When any surface is selected from the plurality of surfaces described above, the
交点を算出すると、ボクセルデータD4を参照して、算出した交点をその面上に持つボクセルを特定する(ステップSe13)。図16を参照して具体的に説明すると、交点PT2が算出されると、ボクセルVX2が特定され、交点PT3が算出されると、ボクセルVX3が特定され、交点PT4が算出されると、ボクセルVX4が特定される。なお、算出した交点をその面上に持つボクセルが2個特定された場合には、カメラから遠い方のボクセルが選択される。 When the intersection point is calculated, the voxel data D4 is referred to, and the voxel having the calculated intersection point on the surface is specified (step Se13). More specifically with reference to FIG. 16, when the intersection PT2 is calculated, the voxel VX2 is specified, when the intersection PT3 is calculated, the voxel VX3 is specified, and when the intersection PT4 is calculated, the voxel VX4 is specified. Is identified. When two voxels having the calculated intersection on the surface are specified, the voxel farther from the camera is selected.
ボクセルを特定すると、ボクセルデータD4を参照して、選択したボクセルに含まれる点の数を特定する(ステップSe14)。そして、特定した点の数が「0」であるか否かを判定する(ステップSe15)。この判定の結果、特定した点の数が「0」である場合には(ステップSe15のYES)、選択したボクセルのラベルを「unknown」から「empty」に更新する(ステップSe16)。このラベル「empty」は、当該ボクセルが占める領域に物体が存在しないことを示す。そして、ステップSe18に進む。一方、特定した点の数が「0」でない場合には(ステップSe15のNO)、選択したボクセルのラベルを「unknown」から「occupancy」に更新する(ステップSe17)。このラベル「occupancy」は、当該ボクセルが占める領域に物体が存在することを示す。そして、ステップSe18をスキップして、ステップSe19に進む。 When the voxel is specified, the number of points included in the selected voxel is specified with reference to the voxel data D4 (step Se14). Then, it is determined whether or not the number of the specified points is "0" (step Se15). As a result of this determination, if the number of specified points is "0" (YES in step Se15), the label of the selected voxel is updated from "unknown" to "empty" (step Se16). The label "empty" indicates that there are no objects in the area occupied by the voxel. Then, the process proceeds to step Se18. On the other hand, if the number of specified points is not "0" (NO in step Se15), the label of the selected voxel is updated from "unknown" to "occupancy" (step Se17). The label "occupancy" indicates that an object exists in the area occupied by the voxel. Then, step Se18 is skipped and the process proceeds to step Se19.
ここで、ステップSe18をスキップすることで、選択中の面の背後に存在する面についてはカメラ視線直線との交点が特定されないことになる。そのため、背後の面にカメラ視線直線との交点が存在したとしても、その交点を面上に持つボクセルのラベルは「unknown」のままとされる。これは、「occupancy」にラベルが更新されたボクセルの背後の領域は、壁等により遮蔽されて撮影することができず、物体の存否が不明の領域と考えられるからである。 Here, by skipping step Se18, the intersection with the straight line of the camera line of sight is not specified for the surface existing behind the selected surface. Therefore, even if there is an intersection with the straight line of the camera line of sight on the back surface, the label of the voxel having the intersection on the surface remains "unknown". This is because the area behind the voxel whose label has been updated to "occupancy" cannot be photographed because it is shielded by a wall or the like, and it is considered that the existence or nonexistence of the object is unknown.
次に、ステップSe18では、ラベル更新部111は、未選択の面があるか否かを判定する。この判定の結果、未選択の面がある場合には(ステップSe18のYES)、ステップSe9に戻る。一方、未選択の面がない場合には(ステップSe18のNO)。未選択の画素があるか否かを判定する(ステップSe19)。この判定の結果、未選択の画素がある場合には(ステップSe19のYES)、ステップSe1に戻る。一方、未選択の画素がない場合には(ステップSe19のNO)、第1の更新処理を終了する。
以上が第1の更新処理についての説明である。
Next, in step Se18, the
The above is the description of the first update process.
次に、上記のステップSd5で実行される第2の更新処理について説明する。この第2の更新処理は、ボクセル群が全体で構成する直方体にカメラが含まれている場合に実行される処理である。 Next, the second update process executed in step Sd5 described above will be described. This second update process is a process executed when the camera is included in the rectangular parallelepiped formed by the voxel group as a whole.
図17は、この第2の更新処理を示すフロー図である。同図に示す第2の更新処理は、ステップSe6〜Se8に代えて、ステップSf1〜Sf4を含む点においてのみ、第1の更新処理と相違している。したがって以下では、この相違点であるステップSf1〜Sf4についてのみ説明する。 FIG. 17 is a flow chart showing the second update process. The second update process shown in the figure is different from the first update process only in that steps Sf1 to Sf4 are included instead of steps Se6 to Se8. Therefore, in the following, only this difference, steps Sf1 to Sf4, will be described.
ステップSf1において、ラベル更新部111は、媒介変数tが「0」でない面(言い換えると、カメラ視線直線が交差する面)の数が「1」であるか否かを判定する。この判定の結果、媒介変数tが「0」でない面の数が「1」である場合には(ステップSf1のYES)、その媒介変数tが「0」でない面を出口面とする(ステップSf2)。ここで特定される出口面は、例えば、図14に示す面PL5に相当する。一方、媒介変数tが「0」でない面の数が「1」より多い場合には(ステップSf1のNO)、すなわち、カメラ視線直線が直方体の頂点と交差する場合には、カメラ視線直線が交差する任意の面を出口面とする(ステップSf3)。
In step Sf1, the
出口面を特定すると、特定した出口面に基づいて入口面を特定する(ステップSf4)。具体的には、特定した出口面と平行な断面であって、出口面とカメラの間に存在する断面のうち、カメラに最も近い断面を、入口面として特定する。ここで特定される入口面は、例えば、図14に示す面PL6に相当する。 When the exit surface is specified, the entrance surface is specified based on the specified exit surface (step Sf4). Specifically, among the cross sections parallel to the specified exit surface and existing between the exit surface and the camera, the cross section closest to the camera is specified as the entrance surface. The entrance surface specified here corresponds to, for example, the surface PL6 shown in FIG.
入口面を特定すると、以降は第1の更新処理と同様に、ステップSe9以降の処理を実行する。
以上が第2の更新処理についての説明である。
After specifying the entrance surface, the processes after step Se9 are executed in the same manner as the first update process.
The above is the description of the second update process.
ラベル更新部111は、以上説明したラベル更新処理を実行することで、図18に例示するように、画像データセットD1を構成する複数の画像データの複数の画素について、画素とカメラ中心を通るカメラ視線直線を算出する。そして、ボクセルデータD4により表されるボクセルのうち、このカメラ視線直線と交差するボクセルのラベルを更新する処理を実行する。
By executing the label update process described above, the
ラベル更新処理が完了すると、ボクセル比較部113は、ボクセルデータ記憶部107に記憶されているボクセルデータD4と、参照ボクセルデータ記憶部112に予め記憶されている参照ボクセルデータD7を比較する(ステップSa6)。ここで、参照ボクセルデータ記憶部112に予め記憶されている参照ボクセルデータD7は、正常時の監視対象物について生成されたボクセルデータである。この参照ボクセルデータD7のデータ構成は、図7に例示したボクセルデータD4と同様である。
When the label update process is completed, the
ボクセル比較部113は、具体的には、ボクセルデータD4と参照ボクセルデータD7の間で、インデックスが共通するボクセル同士のラベルを比較する。そして、ボクセルデータD4により表されるボクセルのうち、参照ボクセルデータD7により表されるボクセルとラベルが異なるボクセルを特定する。
Specifically, the
ここで、ボクセルデータD4と参照ボクセルデータD7のいずれについても、物体が存在しない領域を占めるボクセルにはラベル「empty」が付与されている。そのため、物体が存在しない領域を占めるボクセルについても、インデックスが共通するボクセルとラベルを比較することができる。そのため、監視対象物に新たに物体が付加された場合でも、当該物体の存在を検知することができる。これに対して、従来技術では、レファレンスデータにおいて点が存在しない領域は比較対象とはならないため、監視対象物に新たに物体が付加されても、当該物体の存在を検知することができない。 Here, in both the voxel data D4 and the reference voxel data D7, the label "empty" is given to the voxels that occupy the area where no object exists. Therefore, it is possible to compare the label with the voxel having a common index even for the voxel that occupies the area where the object does not exist. Therefore, even when a new object is added to the monitored object, the existence of the object can be detected. On the other hand, in the prior art, since the region where no point does not exist in the reference data is not a comparison target, even if a new object is added to the monitored object, the existence of the object cannot be detected.
次に、ボクセルを特定すると、特定したボクセルが識別可能なように、ボクセルデータD4により表されるボクセル群を示す画面を生成する(ステップSa7)。図19は、この画面の一例を示す図である。同図に示す画面では、参照ボクセルデータD7により表されるボクセル群と、ボクセルデータD4により表されるボクセル群が並置されている。これらのボクセル群を構成する各ボクセルには、ラベルの種類を表す文字が付されている。文字「u」は「unknown」を表し、文字「e」は「empty」を表し、文字「o」は「occupancy」を表す。各ボクセルに付された文字のうち、上記特定されたボクセルの文字には下線が付されている。したがって、この画面を見た利用者は、これらのボクセル群の相違点を識別することができる。言い換えると、正常時の監視対象物と点検時の監視対象物の相違点(言い換えると、異常発生箇所)を識別することができる。 Next, when the voxels are specified, a screen showing the voxel group represented by the voxel data D4 is generated so that the specified voxels can be identified (step Sa7). FIG. 19 is a diagram showing an example of this screen. In the screen shown in the figure, the voxel group represented by the reference voxel data D7 and the voxel group represented by the voxel data D4 are juxtaposed. Each voxel that composes these voxels is given a letter that indicates the type of label. The letter "u" stands for "unknown", the letter "e" stands for "empty", and the letter "o" stands for "occupancy". Of the characters attached to each voxel, the characters of the specified voxel are underlined. Therefore, the user who sees this screen can identify the difference between these voxel groups. In other words, it is possible to identify the difference between the monitored object during normal operation and the monitored object during inspection (in other words, the location where an abnormality occurs).
また、各ボクセルに付されるラベルの種類には「unknown」が含まれている。このラベル「unknown」は、ボクセルが占める領域が壁等により遮蔽されて撮影することができず、その結果、その領域に物体が存在するか否かが不明であることを示す。したがって、利用者は、ボクセル群のうち、物体の存否が不明であるボクセルを識別することができる。 In addition, "unknown" is included in the type of label attached to each voxel. This label "unknown" indicates that the area occupied by the voxel is blocked by a wall or the like and cannot be photographed, and as a result, it is unknown whether or not an object exists in the area. Therefore, the user can identify a voxel whose existence or nonexistence of an object is unknown from the voxel group.
2.変形例
上記の実施形態は以下に記載するように変形してもよい。以下に記載する1以上の変形例は互いに組み合わせてもよい。
2. Modification Example The above embodiment may be modified as described below. One or more modifications described below may be combined with each other.
2−1.変形例1
ラベル更新部111は、必ずしも、画像データセットD1を構成するすべての画像について第1又は第2の更新処理を実行する必要はない。例えば、ラベル更新部111は、画像データセットD1の中から所定のサンプリング間隔で画像データを抽出し、抽出した画像データについてのみ第1又は第2の更新処理を実行するようにしてもよい。
2-1.
The
同様に、ラベル更新部111は、必ずしも、画像データを構成するすべての画素について第1又は第2の更新処理を実行する必要はない。例えば、ラベル更新部111は、画像データから所定のサンプリング間隔で画素を抽出し、抽出した画素についてのみ第1又は第2の更新処理を実行するようにしてもよい。
Similarly, the
2−2.変形例2
ラベル更新部111は、上記の第1又は第2の更新処理において、ボクセルに含まれる点数の数が「0」と判定した場合には当該ボクセルのラベルを「empty」に更新し、「0」でないと判定した場合には「occupancy」に更新している。これに代えて、ボクセルに含まれる点数の数が、「1」以上の所定数以下と判定した場合に当該ボクセルのラベルを「empty」に更新し、当該所定数より大と判定した場合に「occupancy」に更新するようにしてもよい。すなわち、ラベルの種類を判定するための閾値を任意に変更してもよい。
2-2. Modification 2
When the
2−3.変形例3
ボクセル比較部113が比較結果を出力する方法は、上記の例に限られない。ボクセル比較部113は、監視対象物の正常時と点検時の相違点が識別可能な別の方法で比較結果を出力してもよい。
2-3. Modification 3
The method in which the
1…異常検知システム、101…画像データ記憶部、102…点群生成部、103…点群データ記憶部、104…参照点群データ記憶部、105…レジストレーション部、106…ボクセル化部、107…ボクセルデータ記憶部、108…カメラ属性データ記憶部、109…画素位置推定部、110…画素位置データ記憶部、111…ラベル更新部、112…参照ボクセルデータ記憶部、113…ボクセル比較部、CA…カメラ、CB…立方体、CS1、CS2…断面、IM…画像、L1、L2…カメラ視線直線、PG…3D点群、PL1〜PL6…面、PT1…頂点、PT2〜PT4…交点、RP…直方体、VX1〜VX4…ボクセル 1 ... Abnormality detection system, 101 ... Image data storage unit, 102 ... Point cloud generation unit, 103 ... Point cloud data storage unit, 104 ... Reference point cloud data storage unit, 105 ... Registration unit, 106 ... Voxelization unit, 107 ... Voxel data storage unit, 108 ... Camera attribute data storage unit, 109 ... Pixel position estimation unit, 110 ... Pixel position data storage unit, 111 ... Label update unit, 112 ... Reference voxel data storage unit, 113 ... Voxel comparison unit, CA ... camera, CB ... cube, CS1, CS2 ... cross section, IM ... image, L1, L2 ... camera line of sight, PG ... 3D point cloud, PL1-PL6 ... plane, PT1 ... apex, PT2-PT4 ... intersection, RP ... square , VX1-VX4 ... Voxels
Claims (4)
監視対象物を多数の地点から連続的にカメラで撮影することにより生成された画像群に基づいて、世界座標系で表される点群であって、前記監視対象物の立体形状を表す点群を設定する第1ステップと、
前記世界座標系で表されるボクセル群であって、前記点群により表される立体形状の領域を占めるボクセル群を設定する第2ステップと、
前記画像群に含まれる第1の画像の画素群の各々について、画像座標系で表される座標値を前記世界座標系で表される座標値に変換する第3ステップと、
それぞれ座標値が変換された前記画素群の各々について、当該画素と前記カメラを通るカメラ視線直線を特定する第4ステップと、
前記特定されたカメラ視線直線の各々について、当該カメラ視線直線が前記ボクセル群のうちの複数のボクセルと交差する場合に、当該複数のボクセルのうち、前記点群を構成する点を所定数以上含むボクセルであって、前記カメラに最も近いボクセルを第1のカテゴリに分類する一方で、その他のボクセルを第2のカテゴリに分類する第5ステップと
を含み、
前記第1のカテゴリは、前記第1のカテゴリに分類されたボクセルが占める領域に物体が存在することを示し、前記第2のカテゴリは、前記第2のカテゴリに分類されたボクセルが占める領域に物体が存在するか否かが不明であることを示すことを特徴とする3Dモデル生成方法。 A 3D model generation method executed by a computer.
A point cloud represented in the world coordinate system based on an image group generated by continuously photographing the monitored object from a large number of points with a camera, and is a point cloud representing the three-dimensional shape of the monitored object. The first step to set and
The second step of setting the voxel group represented by the world coordinate system and occupying the three-dimensional shape region represented by the point cloud, and the second step.
For each of the pixel groups of the first image included in the image group, the third step of converting the coordinate values represented by the image coordinate system into the coordinate values represented by the world coordinate system, and
For each of the pixel groups whose coordinate values have been converted, the fourth step of identifying the pixel and the camera line-of-sight line passing through the camera, and
For each of the specified camera line-of-sight lines, when the camera line-of-sight line intersects a plurality of voxels in the voxel group, a predetermined number or more of the points constituting the point group are included in the plurality of voxels. The voxels that are closest to the camera are classified into the first category, while the other voxels are classified into the second category, and the fifth step is included.
The first category indicates that an object exists in the area occupied by the voxels classified in the first category, and the second category is in the area occupied by the voxels classified in the second category. A 3D model generation method comprising showing that it is unknown whether or not an object exists.
前記第3のカテゴリは、前記第3のカテゴリに分類されたボクセルが占める領域に物体が存在しないことを示す
ことを特徴とする、請求項1に記載の3Dモデル生成方法。 In the fifth step, for each of the specified camera line-of-sight lines, the camera line-of-sight line is a voxel included in the voxel group, and the voxels do not include the points constituting the point cloud in excess of the predetermined number. When crossing, classify the voxels into a third category and
The 3D model generation method according to claim 1, wherein the third category indicates that no object exists in the area occupied by the voxels classified into the third category.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2020037165A JP2021140429A (en) | 2020-03-04 | 2020-03-04 | Three-dimentional model generation method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2020037165A JP2021140429A (en) | 2020-03-04 | 2020-03-04 | Three-dimentional model generation method |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2021140429A true JP2021140429A (en) | 2021-09-16 |
Family
ID=77668699
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2020037165A Pending JP2021140429A (en) | 2020-03-04 | 2020-03-04 | Three-dimentional model generation method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2021140429A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022196618A1 (en) | 2021-03-17 | 2022-09-22 | 公立大学法人大阪 | Transmitter, transmission method, receiver, and reception method |
-
2020
- 2020-03-04 JP JP2020037165A patent/JP2021140429A/en active Pending
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022196618A1 (en) | 2021-03-17 | 2022-09-22 | 公立大学法人大阪 | Transmitter, transmission method, receiver, and reception method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR20180014677A (en) | System and method for improved scoring of 3d poses and spurious point removal in 3d image data | |
JP5713159B2 (en) | Three-dimensional position / orientation measurement apparatus, method and program using stereo images | |
US8792726B2 (en) | Geometric feature extracting device, geometric feature extracting method, storage medium, three-dimensional measurement apparatus, and object recognition apparatus | |
JP7201909B2 (en) | DATASET CREATION METHOD, DATASET CREATION DEVICE, AND DATASET CREATION PROGRAM | |
JP6632208B2 (en) | Information processing apparatus, information processing method, and program | |
US11490062B2 (en) | Information processing apparatus, information processing method, and storage medium | |
US20160247067A1 (en) | Method and system for intelligent crane lifting | |
Herman et al. | Incremental acquisition of a three-dimensional scene model from images | |
JP6185385B2 (en) | Spatial structure estimation apparatus, spatial structure estimation method, and spatial structure estimation program | |
US20200104626A1 (en) | Construction of an efficient representation for a three-dimensional (3d) compound object from raw video data | |
US7295201B2 (en) | Method and system for generating automated exploded views | |
JP2007322351A (en) | Three-dimensional object collating device | |
JP2016217941A (en) | Three-dimensional evaluation device, three-dimensional data measurement system and three-dimensional measurement method | |
US11189053B2 (en) | Information processing apparatus, method of controlling information processing apparatus, and non-transitory computer-readable storage medium | |
Perez-Yus et al. | Peripheral expansion of depth information via layout estimation with fisheye camera | |
JP2018067188A (en) | Camera information correction device, camera information correction method, and camera information correction program | |
JP2021140429A (en) | Three-dimentional model generation method | |
JP2015184061A (en) | Extracting device, method, and program | |
US9117104B2 (en) | Object recognition for 3D models and 2D drawings | |
CN113945167A (en) | Workpiece data acquisition method and device | |
JP7093680B2 (en) | Structure difference extraction device, structure difference extraction method and program | |
CN112052489B (en) | Method and system for generating house type graph | |
CN113592976A (en) | Map data processing method and device, household appliance and readable storage medium | |
JP6306903B2 (en) | Information processing apparatus, information processing apparatus control method, and program | |
US20220230459A1 (en) | Object recognition device and object recognition method |