JP2020187089A - Determination device, determination method, and program - Google Patents

Determination device, determination method, and program Download PDF

Info

Publication number
JP2020187089A
JP2020187089A JP2019093678A JP2019093678A JP2020187089A JP 2020187089 A JP2020187089 A JP 2020187089A JP 2019093678 A JP2019093678 A JP 2019093678A JP 2019093678 A JP2019093678 A JP 2019093678A JP 2020187089 A JP2020187089 A JP 2020187089A
Authority
JP
Japan
Prior art keywords
determination
image
stool
color
region
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
JP2019093678A
Other languages
Japanese (ja)
Inventor
宣広 滝
Nobuhiro Taki
宣広 滝
江美 上田
Emi Ueda
江美 上田
健太 田中
Kenta Tanaka
健太 田中
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.)
Lixil Corp
Original Assignee
Lixil 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 Lixil Corp filed Critical Lixil Corp
Priority to JP2019093678A priority Critical patent/JP2020187089A/en
Publication of JP2020187089A publication Critical patent/JP2020187089A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Investigating Or Analysing Biological Materials (AREA)
  • Investigating Or Analysing Materials By Optical Means (AREA)

Abstract

To provide a determination device capable of suppressing an increase in the device cost in an analysis relating to excrement using an image.SOLUTION: Disclosed is a determination device for determining a determination item relating to excrement, which includes: an image information acquiring unit for acquiring image information on an object image obtained by photographing an internal space of a toilet bowl in excretion; an extraction unit for extracting a determination area which performs determination of the determination item in the object image using characteristics of a predetermined assumed color assumed in the excrement; and a determination unit for performing the determination on the determination item about an image indicated in the determination area extracted by the extraction unit.SELECTED DRAWING: Figure 1

Description

本発明は、判定装置、判定方法、及びプログラムに関する。 The present invention relates to a determination device, a determination method, and a program.

生体の排泄の状況を把握する試みがある。例えば、カメラで排泄物を撮影し、その画像を解析する技術が開示されている(例えば特許文献1参照)。 There is an attempt to grasp the status of excretion of the living body. For example, a technique for photographing excrement with a camera and analyzing the image is disclosed (see, for example, Patent Document 1).

特開2007−252805号公報JP-A-2007-252805

上記の特許文献1のような技術を用いた場合においては、解析の精度が十分なものになるとは言い難かった。すなわち、予め作成した便の排出速度、固さ又は大きさと、便の分類(硬便や水様便など)を対応付けたテーブルを用いた解析を行うため、テーブルに設定されていない対象について正しい分類が得られない懸念がある。 When the technique as described in Patent Document 1 is used, it cannot be said that the accuracy of the analysis is sufficient. That is, since the analysis is performed using a table that associates the stool discharge rate, hardness or size created in advance with the stool classification (hard stool, watery stool, etc.), the target that is not set in the table is correct. There is a concern that the classification cannot be obtained.

また、排泄物が便鉢の何処の領域に落下するか不明であるため、便鉢の内部空間の全体が撮像されている画像を、解析の対象とする必要がある。この場合、解析の対象とする画像には、排泄物が撮像された領域と、排泄物が撮像されていない領域とが存在する。解析の対象とする画像の全体を解析の対象とすると、排泄物が撮像されていない領域も解析することとなるために、処理負荷が増大してしまうという問題があった。このため、増大する処理負荷に対応できる高い演算能力を有する装置が必要となり、装置コストが増大してしまうという問題があった。 In addition, since it is unknown where the excrement falls in the toilet bowl, it is necessary to analyze an image in which the entire internal space of the toilet bowl is captured. In this case, the image to be analyzed includes a region where the excrement is imaged and a region where the excrement is not imaged. When the entire image to be analyzed is analyzed, there is a problem that the processing load increases because the region where the excrement is not imaged is also analyzed. For this reason, there is a problem that a device having a high computing power that can cope with an increasing processing load is required, and the device cost increases.

本発明は、このような事情に鑑みてなされたものであり、その目的は、画像を用いた排泄物に関する解析において、装置コストの増大を抑制することができる判定装置、判定方法、及びプログラムを提供することである。 The present invention has been made in view of such circumstances, and an object of the present invention is to provide a determination device, a determination method, and a program capable of suppressing an increase in equipment cost in analysis of excrement using an image. Is to provide.

上述した課題を解決するために本発明の一実施形態は、排泄物に関する判定事項を判定する判定装置であり、排泄における便鉢の内部空間を撮像した対象画像の画像情報を取得する画像情報取得部と、排泄物に想定される所定の想定色の特性を用いて、前記対象画像において前記判定事項に関する判定を行う判定領域を抽出する抽出部と、前記抽出部により抽出された前記判定領域に示される画像について前記判定事項に関する判定を行う判定部と、を備える判定装置である。 In order to solve the above-mentioned problems, one embodiment of the present invention is a determination device that determines determination items related to excrement, and acquires image information of a target image that captures the internal space of a toilet bowl in excretion. In the extraction unit, which extracts a determination region for making a determination regarding the determination item in the target image, and the determination region extracted by the extraction unit, using the characteristics of the predetermined color assumed for the excrement. It is a determination device including a determination unit that determines the determination items for the image shown.

また、本発明の一実施形態は、上述の判定装置であって、前記抽出部は、前記対象画像における画素ごとの色について、前記想定色との色空間上における空間距離を算出し、算出した前記空間距離が所定の閾値未満である画素の集合を、前記判定領域として抽出する。 Further, one embodiment of the present invention is the above-mentioned determination device, and the extraction unit calculates and calculates the spatial distance in the color space from the assumed color for each pixel color in the target image. A set of pixels whose spatial distance is less than a predetermined threshold is extracted as the determination region.

また、本発明の一実施形態は、上述の判定装置であって、前記抽出部は、前記対象画像における画素ごとの色について、前記想定色との色の要素ごとの差分に重みづけをした値を用いて、色空間上における空間距離を算出する。 Further, one embodiment of the present invention is the above-mentioned determination device, and the extraction unit is a value obtained by weighting the difference between the color of each pixel in the target image and each element of the color from the assumed color. Is used to calculate the spatial distance on the color space.

また、本発明の一実施形態は、上述の判定装置であって、前記対象画像は、RGB画像であり、前記想定色は、RGB値で示される色であり、前記抽出部は、前記対象画像における画素ごとのR値、G値、B値の比率を示す色比率と、前記想定色における前記色比率との、R要素における比率の差分、G要素における比率の差分、及びB要素における比率の差分に重みづけをした値を用いて、色空間上における空間距離を算出する。 Further, one embodiment of the present invention is the above-mentioned determination device, the target image is an RGB image, the assumed color is a color indicated by an RGB value, and the extraction unit is the target image. The difference in the ratio in the R element, the difference in the ratio in the G element, and the ratio in the B element between the color ratio indicating the ratio of the R value, the G value, and the B value for each pixel and the color ratio in the assumed color. The spatial distance on the color space is calculated using the weighted value of the difference.

また、本発明の一実施形態は、上述の判定装置であって、前記抽出部は、前記対象画像における画素ごとに算出した前記空間距離をグレースケールに対応させたグレースケール対象画像を作成し、当該グレースケール対象画像における画素のグレースケール値が所定の第1閾値未満である領域を排泄物がある領域とし、前記判定領域として当該排泄物がある領域を抽出する。 Further, one embodiment of the present invention is the above-mentioned determination device, and the extraction unit creates a grayscale target image in which the spatial distance calculated for each pixel in the target image corresponds to a grayscale. A region in which the grayscale value of the pixels in the grayscale target image is less than a predetermined first threshold value is defined as a region containing excrement, and a region containing the excrement is extracted as the determination region.

また、本発明の一実施形態は、上述の判定装置であって、前記抽出部は、前記グレースケール対象画像における画素のグレースケール値が前記第1閾値未満、且つ前記第1閾値より小さい所定の第2閾値以上である領域を水様便がある領域とし、前記グレースケール対象画像における画素のグレースケール値が前記第2閾値未満である領域を硬便がある領域とし、前記判定領域として当該水様便がある領域及び当該硬便がある領域を抽出する。 Further, one embodiment of the present invention is the above-mentioned determination device, and the extraction unit determines that the grayscale value of a pixel in the grayscale target image is less than the first threshold value and smaller than the first threshold value. A region having watery stools above the second threshold value is defined as a region having watery stools, a region having a grayscale value of pixels in the grayscale target image less than the second threshold value is defined as a region having hard stools, and the water is used as the determination region. The area with stool and the area with hard stool are extracted.

また、本発明の一実施形態は、排泄物に関する判定事項を判定する判定方法であり、画像情報取得部が、排泄における便鉢の内部空間を撮像した対象画像の画像情報を取得し、抽出部が、排泄物に想定される所定の想定色に基づいて、前記対象画像において、前記判定事項に関する判定を行う判定領域を抽出し、判定部が、前記抽出部により抽出された前記判定領域に示される画像について前記判定事項に関する判定を行う判定方法である。 Further, one embodiment of the present invention is a determination method for determining determination items related to excretion, in which an image information acquisition unit acquires image information of a target image obtained by capturing an image of the internal space of a toilet bowl during excretion, and an extraction unit. However, based on a predetermined assumed color assumed for excrement, a determination region for making a determination regarding the determination item is extracted from the target image, and the determination unit is shown in the determination area extracted by the extraction unit. This is a determination method for determining the determination items for the image to be displayed.

また、本発明の一実施形態は、排泄物に関する判定事項を判定する判定装置のコンピュータを、排泄における便鉢の内部空間を撮像した対象画像の画像情報を取得する画像情報取得手段、排泄物に想定される所定の想定色に基づいて、前記対象画像において、前記判定事項に関する判定を行う判定領域を抽出する抽出手段、前記抽出手段により抽出された前記判定領域に示される画像について前記判定事項に関する判定を行う判定手段、として機能させるためのプログラムである。 Further, in one embodiment of the present invention, the computer of the determination device for determining the determination items related to the excrement is used as an image information acquisition means and excrement for acquiring the image information of the target image obtained by capturing the internal space of the toilet bowl in the excretion. An extraction means for extracting a determination area for making a determination regarding the determination item in the target image based on an assumed predetermined color, and an image shown in the determination area extracted by the extraction means with respect to the determination item. It is a program for functioning as a determination means for making a determination.

以上説明したように、この発明によれば、画像を用いた排泄物に関する解析において、装置コストの増大を抑制することができる。 As described above, according to the present invention, it is possible to suppress an increase in device cost in the analysis of excrement using images.

第1の実施形態に係る判定装置10が適用される判定システム1の構成を示すブロック図である。It is a block diagram which shows the structure of the determination system 1 to which the determination apparatus 10 which concerns on 1st Embodiment is applied. 第1の実施形態に係る学習済みモデル記憶部16の構成を示すブロック図である。It is a block diagram which shows the structure of the trained model storage part 16 which concerns on 1st Embodiment. 第1の実施形態に係る判定装置10が判定の対象とする画像について説明する図である。It is a figure explaining the image to be determined by the determination apparatus 10 which concerns on 1st Embodiment. 第1の実施形態に係る判定装置10が行う処理の全体の流れを示すフローチャートである。It is a flowchart which shows the whole flow of the process performed by the determination apparatus 10 which concerns on 1st Embodiment. 第1の実施形態に係る判定装置10が行う判定処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the determination process performed by the determination apparatus 10 which concerns on 1st Embodiment. 第1の実施形態に係る判定装置10が行う洗浄方法の判定処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the determination process of the cleaning method performed by the determination apparatus 10 which concerns on 1st Embodiment. 第2の実施形態に係る判定装置10Aを説明する図である。It is a figure explaining the determination apparatus 10A which concerns on 2nd Embodiment. 第2の実施形態に係る判定装置10Aが適用される判定システム1Aの構成を示すブロック図である。It is a block diagram which shows the structure of the determination system 1A to which the determination apparatus 10A which concerns on 2nd Embodiment is applied. 第2の実施形態に係る前処理部19が行う処理を説明する図である。It is a figure explaining the process performed by the pre-processing unit 19 which concerns on 2nd Embodiment. 第2の実施形態に係る判定装置10Aが行う処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the process performed by the determination apparatus 10A which concerns on 2nd Embodiment. 第2の実施形態の変形例1に係る前処理部19が行う処理を説明する図である。It is a figure explaining the process performed by the pre-processing unit 19 which concerns on the modification 1 of the 2nd Embodiment. 第2の実施形態の変形例1に係る判定装置10Aが行う処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the process performed by the determination apparatus 10A which concerns on the modification 1 of the 2nd Embodiment. 第2の実施形態の変形例2に係る前処理部19が行う処理を説明する図である。It is a figure explaining the process performed by the pre-processing unit 19 which concerns on modification 2 of the 2nd Embodiment. 第2の実施形態の変形例2に係る判定装置10Aが行う処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the process performed by the determination apparatus 10A which concerns on the modification 2 of the 2nd Embodiment. 第3の実施形態に係る判定装置10Bの構成を示すブロック図である。It is a block diagram which shows the structure of the determination apparatus 10B which concerns on 3rd Embodiment. 第3の実施形態に係る解析部12Bが行う処理を説明する図である。It is a figure explaining the process performed by the analysis unit 12B which concerns on 3rd Embodiment. 第3の実施形態に係る判定装置10Bが行う処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the process performed by the determination apparatus 10B which concerns on 3rd Embodiment.

以下、実施形態の判定装置を、図面を参照して説明する。 Hereinafter, the determination device of the embodiment will be described with reference to the drawings.

(第1の実施形態)
まず、第1の実施形態について説明する。
図1は、第1の実施形態に係る判定装置10が適用される判定システム1の構成を示すブロック図である。判定システム1は、例えば、判定装置10と、学習装置20とを備える。
(First Embodiment)
First, the first embodiment will be described.
FIG. 1 is a block diagram showing a configuration of a determination system 1 to which the determination device 10 according to the first embodiment is applied. The determination system 1 includes, for example, a determination device 10 and a learning device 20.

判定装置10は、判定の対象とする対象画像(以下、単に画像ともいう)を基に、排泄に関する判定を行う。対象画像は、排泄に関する画像であって、例えば、排泄後の便鉢32(図3参照)の内部空間34(同)を撮像した画像である。排泄後とは、使用者が排泄をした後、便器が洗浄される前までの任意の時点であり、例えば、便器30(同)に着座していた使用者が脱座した時である。排泄に関する判定とは、排泄行動と状況、及び排泄物の洗浄に関する判定事項であって、例えば、排泄の有無、尿の有無、便の有無、便の性状、紙(トイレットペーパ)の使用の有無、紙の使用量等の情報に基づく排泄後の便器30洗浄方法や排泄の状況などである。便の性状は、便の形状を示す「硬便」「普通便」「軟便」「泥状便」「水様便」等の便の状態を示す情報であってもよいし、「硬い」「柔らかい」など性状や状態を示す情報であってもよい。便の形状は、便鉢への飛び散りや、溜水部の便の溶け出し方、濁り方、溜水内部(水中)や水面より上(空気中)での特徴などの観点でラベル付(評価)を行う。また便の性状は便の量を示す情報であってもよいし、便の量は多いか少ないかの二つ、あるいは多いか普通か少ないかの三つ等の区分けを示す情報であっても良いし、便の量を数値で示す情報であっても良い。また、便の性状は、便の色を示す情報であってもよい。便の色は、例えば、黄土色〜茶色である場合を通常の便の色とし、通常の便の色か否かを示す情報であってもよいし、特に便の色が黒色(いわゆるタール便の色)か否かを示す情報であってもよい。排泄後の便器30の洗浄方法には、洗浄に用いる洗浄水の水量、水圧、及び洗浄の回数などが含まれる。 The determination device 10 determines the excretion based on the target image (hereinafter, also simply referred to as an image) to be determined. The target image is an image related to excretion, for example, an image of the internal space 34 (same as above) of the toilet bowl 32 (see FIG. 3) after excretion. The post-excretion is an arbitrary time point after the user excretes and before the toilet bowl is washed, for example, when the user sitting on the toilet bowl 30 (same as above) is unseat. Judgment regarding excretion is a judgment item regarding excretion behavior and situation, and cleaning of excrement. For example, presence / absence of excretion, presence / absence of urine, presence / absence of stool, properties of stool, presence / absence of use of paper (toilet paper). , How to clean the toilet bowl 30 after excretion based on information such as the amount of paper used, and the status of excretion. The property of the stool may be information indicating the state of the stool such as "hard stool", "ordinary stool", "loose stool", "muddy stool", "watery stool" indicating the shape of the stool, or "hard" or "hard". It may be information indicating properties or conditions such as "soft". The shape of the stool is labeled (evaluated) from the viewpoints of splashing into the toilet bowl, how the stool in the reservoir melts out, how it becomes turbid, and the characteristics inside the reservoir (underwater) and above the water surface (in the air). )I do. Further, the property of the stool may be information indicating the amount of stool, or information indicating the classification of the amount of stool into two such as large or small, or large, normal or small. It may be information that indicates the amount of stools numerically. Further, the property of the stool may be information indicating the color of the stool. The color of the stool may be, for example, ocher to brown as the color of the normal stool, and may be information indicating whether or not the color of the stool is the color of the normal stool. In particular, the color of the stool is black (so-called tar stool). It may be information indicating whether or not it is (color). The washing method of the toilet bowl 30 after excretion includes the amount of washing water used for washing, the water pressure, the number of washings, and the like.

判定装置10は、例えば、画像情報取得部11と、解析部12と、判定部13と、出力部14と、画像情報記憶部15と、学習済みモデル記憶部16と、判定結果記憶部17と、を備える。ここで、解析部12は、「推定部」の一例である。 The determination device 10 includes, for example, an image information acquisition unit 11, an analysis unit 12, a determination unit 13, an output unit 14, an image information storage unit 15, a learned model storage unit 16, and a determination result storage unit 17. , Equipped with. Here, the analysis unit 12 is an example of the “estimation unit”.

画像情報取得部11は、排泄に関して撮像された、便鉢32の内部空間34の画像(対象画像)の画像情報を取得する。画像情報取得部11は、取得した画像情報を、解析部12に出力すると共に、画像情報記憶部15に記憶させる。画像情報取得部11は、便器装置3及び撮像装置4(図3参照)と接続する。 The image information acquisition unit 11 acquires image information of an image (target image) of the internal space 34 of the toilet bowl 32, which is captured for excretion. The image information acquisition unit 11 outputs the acquired image information to the analysis unit 12 and stores it in the image information storage unit 15. The image information acquisition unit 11 is connected to the toilet bowl device 3 and the image pickup device 4 (see FIG. 3).

解析部12は、画像情報取得部11から得られた画像情報に対応する画像(対象画像)の解析を行う。解析部12による解析とは、排泄に関する画像を基に、排泄に関する判定の項目について推定を行うことである。 The analysis unit 12 analyzes an image (target image) corresponding to the image information obtained from the image information acquisition unit 11. The analysis by the analysis unit 12 is to estimate the items of determination regarding excretion based on the image related to excretion.

解析部12は、例えば、判定部13の判定項目に応じた学習済みモデルを用いて推定を行う。学習済みモデルは、例えば、学習済みモデル記憶部16に記憶されたモデルであって、排泄に関する画像と、排泄に関する評価の結果との対応関係を学習したモデルである。 The analysis unit 12 estimates using, for example, a trained model corresponding to the determination item of the determination unit 13. The trained model is, for example, a model stored in the trained model storage unit 16 and is a model in which the correspondence between the image related to excretion and the evaluation result regarding excretion is learned.

例えば、解析部12は、画像と尿の有無との対応関係を学習した学習済みモデルから得られた出力を尿の有無を推定した推定結果とする。また、解析部12は、画像と便の有無との対応関係を学習した学習済みモデルから得られた出力を便の有無を推定した推定結果とする。また、解析部12は、画像と便の性状との対応関係を学習した学習済みモデルから得られた出力を便の性状を推定した推定結果とする。また、解析部12は、画像と紙の使用の有無との対応関係を学習した学習済みモデルから得られた出力を紙の使用の有無を推定した推定結果とする。また、解析部12は、画像と紙の使用量との対応関係を学習した学習済みモデルから得られた出力を紙の使用量を推定した推定結果とする。 For example, the analysis unit 12 uses the output obtained from the learned model that learned the correspondence between the image and the presence or absence of urine as the estimation result of estimating the presence or absence of urine. Further, the analysis unit 12 uses the output obtained from the learned model that learned the correspondence between the image and the presence or absence of stool as the estimation result of estimating the presence or absence of stool. In addition, the analysis unit 12 uses the output obtained from the trained model that learned the correspondence between the image and the stool properties as the estimation result of estimating the stool properties. Further, the analysis unit 12 uses the output obtained from the trained model that has learned the correspondence between the image and the presence / absence of paper as the estimation result of estimating the presence / absence of paper. Further, the analysis unit 12 uses the output obtained from the trained model that has learned the correspondence between the image and the paper usage as the estimation result of estimating the paper usage.

解析部12は、画像から複数の項目を推定する学習済みモデルを用いて推定を行うようにしてもよい。例えば、解析部12は、画像と、尿及び便それぞれの有無との対応関係を学習した学習済みモデルを用いて推定を行うようにしてもよい。解析部12は、学習済みモデルから画像に尿及び便の何れもないと推定された場合に、排泄が無いと推定する。 The analysis unit 12 may perform estimation using a trained model that estimates a plurality of items from an image. For example, the analysis unit 12 may perform estimation using a trained model that has learned the correspondence between the image and the presence / absence of each of urine and stool. When it is estimated from the trained model that there is neither urine nor stool in the image, the analysis unit 12 estimates that there is no excretion.

判定部13は、解析部12から得られた解析結果を用いて、排泄に関する判定を行う。例えば、判定部13は、画像から推定した尿の有無を、その画像における尿の有無を判定した判定結果とする。また、判定部13は、画像から推定した便の有無を、その画像における便の有無を判定した判定結果とする。また、判定部13は、画像から推定した便の性状を、その画像における便の性状を判定した判定結果とする。また、判定部13は、画像から推定した紙の使用の有無を、その画像における紙の使用の有無を判定した判定結果とする。また、判定部13は、画像から推定した紙の使用量を、その画像における紙の使用量を判定した判定結果とする。 The determination unit 13 makes a determination regarding excretion using the analysis result obtained from the analysis unit 12. For example, the determination unit 13 uses the presence or absence of urine estimated from the image as a determination result for determining the presence or absence of urine in the image. Further, the determination unit 13 uses the presence / absence of stool estimated from the image as the determination result of determining the presence / absence of stool in the image. In addition, the determination unit 13 uses the stool properties estimated from the image as the determination result for determining the stool properties in the image. In addition, the determination unit 13 determines whether or not paper is used in the image as a determination result of determining whether or not paper is used in the image. Further, the determination unit 13 uses the amount of paper used estimated from the image as the determination result for determining the amount of paper used in the image.

判定部13は、複数の推定結果を用いて、排泄に関する判定を行うようにしてもよい。例えば、画像から推定した便の性状、及び紙の使用量に基づいて、排泄後の便器30の洗浄方法を判定するようにしてもよい。 The determination unit 13 may make a determination regarding excretion using a plurality of estimation results. For example, the method of cleaning the toilet bowl 30 after excretion may be determined based on the properties of the stool estimated from the image and the amount of paper used.

出力部14は、判定部13による判定結果を出力する。出力部14は、例えば、排泄行動を行ったユーザの端末に判定結果を送信するようにしてもよい。これにより、ユーザが、自身の排泄行動と状況の判定結果を認識することが可能である。
画像情報記憶部15は、画像情報取得部11により取得された画像情報を記憶する。
学習済みモデル記憶部16は、判定項目の各々に対応した学習済みモデルを記憶する。
判定結果記憶部17は、判定部13による判定結果を記憶する。
The output unit 14 outputs the determination result by the determination unit 13. For example, the output unit 14 may transmit the determination result to the terminal of the user who has performed the excretion behavior. As a result, the user can recognize his / her excretory behavior and the determination result of the situation.
The image information storage unit 15 stores the image information acquired by the image information acquisition unit 11.
The trained model storage unit 16 stores the trained model corresponding to each of the determination items.
The determination result storage unit 17 stores the determination result by the determination unit 13.

学習済みモデル記憶部16に記憶される学習済みモデルは、例えば、ディープラーニング(DL)の手法を用いて作成される。DLは、多層のニューラルネットワークで構成されるディープニューラルネットワーク(DNN)による機械学習の手法である。DNNは、神経科学における予測符号化の原理から発想を得たネットワークにより実現され、神経伝達網を摸した関数により構築される。DLの手法を用いることにより、学習済みモデルに、あたかも人間の思考と同じように、画像に内在する特徴量を自動的に認識させることができる。すなわち、特徴量を抽出する作業を行うことなく、学習済みモデルにデータそのものを学習させることにより、直接画像から推定を行うことが可能となる。 The trained model stored in the trained model storage unit 16 is created, for example, by using a deep learning (DL) method. DL is a machine learning method using a deep neural network (DNN) composed of a multi-layer neural network. DNN is realized by a network inspired by the principle of predictive coding in neuroscience, and is constructed by a function that mimics the neurotransmission network. By using the DL method, the trained model can be made to automatically recognize the feature amount inherent in the image as if it were a human thought. That is, it is possible to estimate directly from the image by letting the trained model learn the data itself without performing the work of extracting the feature amount.

なお、本実施形態では、学習済みモデルがDLの手法を用いて作成された場合を例に説明するが、これに限定されない。学習済みモデルは、少なくとも画像データからその特徴量を抽出することなく、画像データと便性の評価結果とを対応付けた学習データを学習させることにより作成されたモデルであればよい。ここでの画像データは、便鉢32の内部空間34の様々な画像である。 In this embodiment, the case where the trained model is created by using the DL method will be described as an example, but the present invention is not limited to this. The trained model may be a model created by training the training data in which the image data and the evaluation result of convenience are associated with each other, at least without extracting the feature amount from the image data. The image data here are various images of the internal space 34 of the toilet bowl 32.

図2は、第1の実施形態に係る学習済みモデル記憶部16の構成を示すブロック図である。学習済みモデル記憶部16は、例えば、尿有無推定モデル161と、便有無推定モデル162と、便性状推定モデル163と、紙使用有無推定モデル165と、使用紙量推定モデル166とを備える。 FIG. 2 is a block diagram showing the configuration of the trained model storage unit 16 according to the first embodiment. The trained model storage unit 16 includes, for example, a urine presence / absence estimation model 161, a stool presence / absence estimation model 162, a stool property estimation model 163, a paper use / absence estimation model 165, and a paper usage estimation model 166.

尿有無推定モデル161は、画像と尿の有無との対応関係を学習した学習済みモデルであり、排泄に関する画像に、その画像から判断された尿の有無を示す情報が対応付けられた学習データを学習させることにより作成される。
便有無推定モデル162は、画像と便の有無との対応関係を学習した学習済みモデルであり、排泄に関する画像に、その画像から判断された便の有無を示す情報が対応付けられた学習データを学習させることにより作成される。
The urine presence / absence estimation model 161 is a learned model in which the correspondence relationship between the image and the presence / absence of urine is learned, and the learning data in which the image related to excretion is associated with the information indicating the presence / absence of urine judged from the image. Created by learning.
The stool presence / absence estimation model 162 is a learned model in which the correspondence between the image and the presence / absence of stool is learned, and the learning data in which the image related to excretion is associated with the information indicating the presence / absence of stool judged from the image is used. Created by learning.

便性状推定モデル163は、画像と便の性状との対応関係を学習した学習済みモデルであり、排泄に関する画像に、その画像から判断された便の性状を示す情報が対応付けられた学習データを学習させることにより作成される。 The stool property estimation model 163 is a learned model in which the correspondence between the image and the stool property is learned, and the learning data in which the information indicating the stool property determined from the image is associated with the image related to excretion is provided. Created by learning.

紙使用有無推定モデル165は、画像と紙の使用の有無との対応関係を学習した学習済みモデルであり、排泄に関する画像に、その画像から判断された使用された紙の有無を示す情報が対応付けられた学習データを学習させることにより作成される。
使用紙量推定モデル166は、画像と紙の使用量との対応関係を学習した学習済みモデルであり、排泄に関する画像に、その画像から判断された紙の使用量を示す情報が対応付けられた学習データを学習させることにより作成される。紙の使用量は多いか少ないかの二つ、或いは多いか普通か少ないかの三つなどの区分けを示す情報であってもよいし、紙の量を数値で示す情報であってもよい。
なお、画像から排泄の有無等を判断する方法としては、例えば、学習データを作成する担当者が判断することが考えられる。
The paper use estimation model 165 is a learned model that learns the correspondence between the image and the use of paper, and the image related to excretion corresponds to the information indicating the presence or absence of the used paper judged from the image. It is created by training the attached learning data.
The paper usage estimation model 166 is a trained model that has learned the correspondence between the image and the paper usage, and the image related to excretion is associated with information indicating the paper usage judged from the image. It is created by training the training data. The amount of paper used may be two, which is large or small, or three, which is large, normal, or small, and may be information that indicates the amount of paper numerically.
As a method of determining the presence or absence of excretion from the image, for example, the person in charge of creating the learning data may determine.

図3は、第1の実施形態に係る判定装置10が判定の対象とする画像について説明する図である。図3には、便器装置3と、撮像装置4との位置関係が模式的に示されている。 FIG. 3 is a diagram for explaining an image to be determined by the determination device 10 according to the first embodiment. FIG. 3 schematically shows the positional relationship between the toilet bowl device 3 and the image pickup device 4.

便器装置3は、例えば、便鉢32を有する便器30を備える。便器装置3は、便鉢32の内部空間34に設けられた開口部36に、洗浄水Sを供給可能に構成されている。便器装置3は、便器30に設けられた機能部(不図示)により、便器装置3の使用者の着座や脱座、局部洗浄の使用開始、及び排泄後の便鉢32の洗浄の操作などが検知される。便器装置3は、機能部による検知結果を、判定装置10に送信する。 The toilet device 3 includes, for example, a toilet 30 having a toilet bowl 32. The toilet device 3 is configured to be able to supply the washing water S to the opening 36 provided in the internal space 34 of the toilet bowl 32. The toilet device 3 uses a functional unit (not shown) provided in the toilet 30 to allow the user of the toilet device 3 to sit or leave, start using local cleaning, and perform cleaning of the toilet bowl 32 after excretion. Detected. The toilet device 3 transmits the detection result by the functional unit to the determination device 10.

なお、以下の説明では、便器装置3の使用者が便器30に着座した場合において、使用者の前側を「前側」、後側を「後側」という。また、便器装置3の使用者が便器30に着座した場合において、使用者の左側を「左側」、右側を「右側」という。また、便器装置3が設置されている床面から離れている側を「上側」、床面に近い側を「下側」という。 In the following description, when the user of the toilet bowl device 3 is seated on the toilet bowl 30, the front side of the user is referred to as "front side" and the rear side is referred to as "rear side". Further, when the user of the toilet bowl device 3 is seated on the toilet bowl 30, the left side of the user is referred to as "left side" and the right side is referred to as "right side". Further, the side away from the floor surface on which the toilet bowl device 3 is installed is referred to as "upper side", and the side close to the floor surface is referred to as "lower side".

撮像装置4は、排泄行動に関する内容が撮像可能に設けられる。撮像装置4は、便器30の上側、例えば、便鉢32の後側の縁の内側などに、便鉢32の内部空間34の方向にレンズが向くように設置される。撮像装置4は、例えば、判定装置10の指示により撮像を行い、撮像した画像の画像情報を判定装置10に送信する。この場合、判定装置10は、通信部18を介して、撮像装置4に撮像の指示を示す制御情報を送信する。 The imaging device 4 is provided so that the contents related to the excretory behavior can be imaged. The image pickup device 4 is installed above the toilet bowl 30, for example, inside the rear edge of the toilet bowl 32 so that the lens faces the internal space 34 of the toilet bowl 32. For example, the image pickup device 4 takes an image according to the instruction of the determination device 10, and transmits the image information of the captured image to the determination device 10. In this case, the determination device 10 transmits control information indicating an imaging instruction to the imaging device 4 via the communication unit 18.

ここで、第1の実施形態に係る判定装置10が行う処理について、図4〜図6を用いて説明する。図4は第1の実施形態に係る判定装置10が行う処理の全体の流れ、図5は判定装置10が行う判定処理の流れを示すフローチャートである。図6は判定装置10が行う洗浄方法の判定処理の流れを示すフローチャートである。 Here, the processing performed by the determination device 10 according to the first embodiment will be described with reference to FIGS. 4 to 6. FIG. 4 is a flowchart showing the entire flow of processing performed by the determination device 10 according to the first embodiment, and FIG. 5 is a flowchart showing a flow of determination processing performed by the determination device 10. FIG. 6 is a flowchart showing the flow of the determination process of the cleaning method performed by the determination device 10.

まず、図4を用いて、判定装置10が行う処理の全体の流れを説明する。
判定装置10は、便器装置3との通信により、便器装置3の使用者が便器30に着座したか否かを判定し(ステップS10)、使用者が便器30に着座したと判定する場合、画像情報を取得する(ステップS11)。画像情報は、排泄に関する画像の画像情報である。判定装置10は、撮像装置4に撮像を指示する制御信号を送信し、撮像装置4に便鉢32の内部空間34を撮像させ、撮像させた画像の画像情報を送信させることにより、画像情報を取得する。
なお、図4に示すフローチャートでは、使用者による着座を判定した判定結果を、画像情報を取得するトリガーとして用いる場合を例示して説明したが、これに限定されることはない。画像情報を取得するトリガーとして、他の内容の判定結果が用いられてもよいし、着座を判定した判定結果と他の内容の判定結果との双方を用いて、複合的な条件充足した場合に、画像情報を取得するようにしてもよい。他の内容の判定結果とは、例えば、赤外線などを用いて人体の存在を検知する人体検知センサの検知結果である。この場合、例えば人体検知センサにより、使用者が便器30に近づいたことを検知した場合に、画像取得を開始する。
First, the entire flow of the process performed by the determination device 10 will be described with reference to FIG.
The determination device 10 determines whether or not the user of the toilet device 3 is seated on the toilet bowl 30 by communication with the toilet bowl device 3 (step S10), and when it is determined that the user is seated on the toilet bowl 30, an image. Acquire information (step S11). The image information is image information of an image related to excretion. The determination device 10 transmits the control signal instructing the image pickup to the image pickup device 4, causes the image pickup device 4 to image the internal space 34 of the toilet bowl 32, and transmits the image information of the captured image, thereby transmitting the image information. get.
In the flowchart shown in FIG. 4, the case where the determination result of determining the seating by the user is used as a trigger for acquiring image information has been described as an example, but the present invention is not limited to this. As a trigger for acquiring image information, a judgment result of other contents may be used, or when a complex condition is satisfied by using both the judgment result of seating judgment and the judgment result of other contents. , Image information may be acquired. The determination result of other contents is, for example, the detection result of the human body detection sensor that detects the existence of the human body using infrared rays or the like. In this case, for example, when the human body detection sensor detects that the user has approached the toilet bowl 30, image acquisition is started.

次に判定装置10は、判定処理を行う(ステップS12)。判定処理の内容については、図5を用いて説明する。判定装置10は、判定結果を判定結果記憶部17に記憶する(ステップS13)。
次に、判定装置10は、便器装置3との通信により、便器装置3の使用者が脱座したか否かを判定し(ステップS14)、使用者が脱座したと判定する場合、処理を終了する。一方、判定装置10は、使用者が脱座していないと判定する場合、一定時間待機し(ステップS15)、ステップS11に戻る。
Next, the determination device 10 performs a determination process (step S12). The content of the determination process will be described with reference to FIG. The determination device 10 stores the determination result in the determination result storage unit 17 (step S13).
Next, the determination device 10 determines whether or not the user of the toilet device 3 has left the toilet by communicating with the toilet device 3 (step S14), and if it determines that the user has left the toilet, the process is performed. finish. On the other hand, when the determination device 10 determines that the user has not left the seat, the determination device 10 waits for a certain period of time (step S15) and returns to step S11.

次に、図5を用いて、判定装置10が行う判定処理の流れを説明する。
判定装置10は、尿有無推定モデル161を用いて、画像における尿の有無を推定する(ステップS122)。
Next, the flow of the determination process performed by the determination device 10 will be described with reference to FIG.
The determination device 10 estimates the presence or absence of urine in the image using the urine presence / absence estimation model 161 (step S122).

また、判定装置10は、便有無推定モデル162を用いて、画像における便の有無を推定し(ステップS123)、推定結果に基づいて便の有無を判定する(ステップS124)。 Further, the determination device 10 estimates the presence or absence of stool in the image using the stool presence / absence estimation model 162 (step S123), and determines the presence / absence of stool based on the estimation result (step S124).

判定装置10は、ステップS124において便有りと推定した場合(ステップS124、YES)、便性状推定モデル163を用いて便の性状を推定する(ステップS125)。 When the determination device 10 estimates that there is stool in step S124 (step S124, YES), the determination device 10 estimates the stool properties using the stool property estimation model 163 (step S125).

また、判定装置10は、紙使用有無推定モデル165を用いて画像における紙の使用の有無を推定する(ステップS126)。 Further, the determination device 10 estimates whether or not paper is used in the image by using the paper use or absence estimation model 165 (step S126).

判定装置10は、ステップS126において紙の使用有りと推定した場合(ステップS127、YES)、使用紙量推定モデル166を用いて紙の使用量を推定する(ステップS128)。
判定装置10は、使用後の便器30の洗浄方法を判定する(ステップS129)。
When the determination device 10 estimates that paper is used in step S126 (step S127, YES), the determination device 10 estimates the amount of paper used using the paper usage estimation model 166 (step S128).
The determination device 10 determines the cleaning method of the toilet bowl 30 after use (step S129).

判定装置10が洗浄方法を判定する処理の内容について、図6を用いて説明する。図6に示すフローチャートでは、判定装置10は、洗浄方法を「大」、「中」、「小」、又は「無」の4つの何れかに判定する場合を例示して説明する。洗浄方法における「大」、「中」、「小」は、「大」、「中」、「小」の順に洗浄の強度が小さいことを意味する。洗浄の強度は、便鉢32を洗浄する強さの度合いであり、例えば、強度が小さいほど洗浄水Sの量が少なく、強度が大きいほど洗浄水Sの量が多くなる。或いは、強度が小さいほど洗浄する回数が少なく、強度が大きいほど洗浄する回数が多くなるものであってもよい。なお、洗浄方法が「無」である場合、便鉢32の洗浄を行わないことを意味する。 The content of the process in which the determination device 10 determines the cleaning method will be described with reference to FIG. In the flowchart shown in FIG. 6, the determination device 10 exemplifies and describes a case where the cleaning method is determined to be one of four, "large", "medium", "small", or "none". "Large", "medium", and "small" in the cleaning method mean that the cleaning intensity is small in the order of "large", "medium", and "small". The washing strength is the degree of strength for washing the toilet bowl 32. For example, the smaller the strength, the smaller the amount of washing water S, and the higher the strength, the larger the amount of washing water S. Alternatively, the smaller the strength, the smaller the number of washings, and the higher the strength, the larger the number of washings. If the cleaning method is "none", it means that the toilet bowl 32 is not washed.

判定装置10は、紙の使用の有無を判定し(ステップS130)、紙の使用が有ったと判定した場合、紙の使用量が多いか否かを判定する(ステップS131)。判定装置10は、ステップS126にて推定した紙の量が所定の閾値以上である場合に紙の使用量が多いと判定し、所定の閾値未満である場合に紙の使用量が少ないと判定する。判定装置10は、紙の使用量が多いと判定した場合(ステップS131、YES)、洗浄方法を「大」と判定する(ステップS132)。 The determination device 10 determines whether or not paper is used (step S130), and when it is determined that paper is used, determines whether or not the amount of paper used is large (step S131). The determination device 10 determines that the amount of paper used is large when the amount of paper estimated in step S126 is equal to or greater than a predetermined threshold value, and determines that the amount of paper used is small when the amount is less than the predetermined threshold value. .. When the determination device 10 determines that the amount of paper used is large (step S131, YES), the determination device 10 determines that the cleaning method is “large” (step S132).

判定装置10は、紙の使用量が少ないと判定した場合(ステップS131、NO)、便が有るか否かを判定する(ステップS133)。判定装置10は、ステップS123にて推定した便の有無の推定結果に応じて便の有無を判定する。判定装置10は、便が有ると判定した場合(ステップS133、YES)、便の量が多いか否かを判定する(ステップS134)。判定装置10は、ステップS125にて推定した便の性状において、便の量が所定の閾値以上であると推定された場合に便の量が多いと判定し、所定の閾値未満である場合に便の量が少ないと判定する。判定装置10は、便の量が多いと判定した場合(ステップS134、YES)、洗浄方法を「大」と判定する(ステップS132)。 When the determination device 10 determines that the amount of paper used is small (step S131, NO), the determination device 10 determines whether or not there is stool (step S133). The determination device 10 determines the presence or absence of stool according to the estimation result of the presence or absence of stool estimated in step S123. When the determination device 10 determines that there is stool (step S133, YES), the determination device 10 determines whether or not the amount of stool is large (step S134). In the stool properties estimated in step S125, the determination device 10 determines that the amount of stool is large when the amount of stool is estimated to be equal to or more than a predetermined threshold value, and determines that the amount of stool is less than the predetermined threshold value. It is judged that the amount of is small. When the determination device 10 determines that the amount of stool is large (step S134, YES), the determination device 10 determines that the cleaning method is “large” (step S132).

判定装置10は、便の量が少ないと判定した場合(ステップS134、NO)、便の形状が水様便以外であるか否かを判定する(ステップS135)。判定装置10は、ステップS125にて推定した便の性状において、便の形状が水様便ではない(つまり、硬便、普通便、軟便、泥状便の何れかである)と推定された場合に、便の形状が水様便以外であると判定し、便の形状が水様便であると推定された場合に便の形状が水様便であると判定する。判定装置10は、便の形状が水様便以外であると判定した場合(ステップS135、YES)、洗浄方法を「中」と判定する(ステップS136)。一方、判定装置10は、便の形状が水様便であると判定した場合(ステップS135、NO)、洗浄方法を「小」と判定する(ステップS138)。 When the determination device 10 determines that the amount of stool is small (step S134, NO), the determination device 10 determines whether or not the shape of the stool is other than watery stool (step S135). When the determination device 10 estimates that the shape of the stool is not watery stool (that is, any of hard stool, normal stool, loose stool, and muddy stool) in the properties of the stool estimated in step S125. In addition, it is determined that the shape of the stool is other than watery stool, and when the shape of the stool is estimated to be watery stool, the shape of the stool is determined to be watery stool. When the determination device 10 determines that the shape of the stool is other than watery stool (step S135, YES), the determination device 10 determines the cleaning method as "medium" (step S136). On the other hand, when the determination device 10 determines that the shape of the stool is watery stool (step S135, NO), the determination device 10 determines that the cleaning method is "small" (step S138).

判定装置10は、ステップS133にて便が無いと判定した場合(ステップS133、NO)、尿が有るか否かを判定する(ステップS137)。判定装置10は、ステップS122にて推定した尿の有無の推定結果に応じて尿の有無を判定する。判定装置10は、尿が有ると判定した場合(ステップS137、YES)、洗浄方法を「小」と判定する(ステップS138)。一方、判定装置10は、尿が無いと判定した場合(ステップS137、NO)、洗浄方法を「無」と判定する(ステップS139)。 When the determination device 10 determines in step S133 that there is no stool (step S133, NO), the determination device 10 determines whether or not there is urine (step S137). The determination device 10 determines the presence or absence of urine according to the estimation result of the presence or absence of urine estimated in step S122. When the determination device 10 determines that there is urine (step S137, YES), the determination device 10 determines that the washing method is "small" (step S138). On the other hand, when the determination device 10 determines that there is no urine (step S137, NO), the determination device 10 determines that the cleaning method is "absent" (step S139).

図6に示すフローチャートの例のように、判定装置10が、尿の有無、便の有無、紙の有無を推定した結果の組み合わせに応じて洗浄方法をそれぞれ判定することにより、洗浄水量を細かく制御することができ、十分な洗浄を行いつつ、水の無駄遣いを抑制して、適切な節水を行うことが可能である。 As in the example of the flowchart shown in FIG. 6, the determination device 10 finely controls the amount of cleaning water by determining the cleaning method according to the combination of the results of estimating the presence / absence of urine, the presence / absence of stool, and the presence / absence of paper. It is possible to suppress wasteful use of water and save water appropriately while performing sufficient cleaning.

なお、判定装置10は、使用者が排泄を行ったか否かを、ステップS122に示す尿の有無を推定した推定結果、及びステップS123に示す便の有無を推定した推定結果、を用いて使用者が排泄を行ったか否かを判定してもよい。この場合、判定装置10は、尿が無いと推定され、且つ便が無いと推定された場合に、使用者が排泄を行っていないと判定する。 In addition, the determination device 10 uses the estimation result of estimating the presence or absence of urine shown in step S122 and the estimation result of estimating the presence or absence of stool shown in step S123 to determine whether or not the user has excreted. May determine whether or not the patient has excreted. In this case, the determination device 10 determines that the user is not excreting when it is estimated that there is no urine and there is no stool.

以上説明したように、第1の実施形態の判定装置10は、画像情報取得部11と、解析部12と、判定部13とを備える。画像情報取得部11は、便鉢32の内部空間34を撮像した画像(対象画像)の画像情報を取得する。解析部12は、学習済みモデルに画像情報を入力させることにより、対象画像について排泄に関する判定事項の推定を行う。判定部13は、推定結果に基づいて画像について判定事項の判定を行う。学習済みモデルは、DLの手法を用いて学習されたモデルである。DLの手法を用いて学習を行う場合、画像における排泄の有無等の判定項目を判断した結果のラベリング(対応付け)のみすればよいため、画像から特徴量を抽出して学習データを作成する必要がない。このため、どのような特徴量をどのような手法により抽出すればよいかを検討する時間が必要ない。すなわち、第1の実施形態の判定装置10は、機械学習を用いた排泄行動に関する解析において、開発に要する時間を低減することができる。 As described above, the determination device 10 of the first embodiment includes an image information acquisition unit 11, an analysis unit 12, and a determination unit 13. The image information acquisition unit 11 acquires the image information of the image (target image) obtained by capturing the internal space 34 of the toilet bowl 32. The analysis unit 12 estimates the judgment items related to excretion of the target image by inputting the image information into the trained model. The determination unit 13 determines the determination items for the image based on the estimation result. The trained model is a model trained using the DL method. When learning is performed using the DL method, it is only necessary to label (associate) the result of judging the judgment items such as the presence or absence of excretion in the image, so it is necessary to extract the feature amount from the image and create the learning data. There is no. Therefore, there is no need for time to consider what kind of feature quantity should be extracted by what kind of method. That is, the determination device 10 of the first embodiment can reduce the time required for development in the analysis of the excretory behavior using machine learning.

また、第1の実施形態の判定装置10では、対象画像は、排泄後における便鉢32の内部空間34を撮像した画像である。これにより、例えば、排泄物が落下中の画像を連写することにより得られる、数百枚の画像を判定対象とする場合よりも、画像の枚数を抑えることが可能である。このため、推定や判定に要する負荷を低減させ、開発に要する時間を低減することができる。 Further, in the determination device 10 of the first embodiment, the target image is an image of the internal space 34 of the toilet bowl 32 after excretion. Thereby, for example, it is possible to reduce the number of images as compared with the case where hundreds of images obtained by continuously shooting images in which excrement is falling are targeted for determination. Therefore, the load required for estimation and determination can be reduced, and the time required for development can be reduced.

また、第1の実施形態の判定装置10では、判定事項は、尿の有無、便の有無、便の性状のうち少なくとも何れか一つを含む。これにより、第1の実施形態の判定装置10では、排泄物に関する判定を行うことができる。 Further, in the determination device 10 of the first embodiment, the determination item includes at least one of the presence / absence of urine, the presence / absence of stool, and the properties of stool. As a result, the determination device 10 of the first embodiment can determine the excrement.

また、第1の実施形態の判定装置10では、判定事項は、排泄における紙の使用の有無、及び紙が使用された場合における紙の使用量を含む。これにより、第1の実施形態の判定装置10では、排泄における紙の使用に関する判定を行うことができ、判定結果を用いて例えば、便器30の洗浄方法を判定するための指標に用いることが可能となる。 Further, in the determination device 10 of the first embodiment, the determination items include the presence or absence of paper used for excretion and the amount of paper used when paper is used. As a result, the determination device 10 of the first embodiment can determine the use of paper in excretion, and can be used as an index for determining, for example, a cleaning method of the toilet bowl 30 using the determination result. It becomes.

また、第1の実施形態の判定装置10では、判定部13は、対象画像に示された状況における便器30を洗浄する洗浄方法を判定する。これにより、第1の実施形態の判定装置10では、排泄物の判定だけでなく、便器30の洗浄方法の判定を行うことができる。 Further, in the determination device 10 of the first embodiment, the determination unit 13 determines a cleaning method for cleaning the toilet bowl 30 in the situation shown in the target image. As a result, the determination device 10 of the first embodiment can determine not only the excrement but also the cleaning method of the toilet bowl 30.

また、第1の実施形態の判定装置10では、判定事項は、便の性状、及び排泄において使用された紙の量のうち少なくとも一つを含み、解析部12は、対象画像における便の性状、及び排泄において使用された紙の量のうち少なくとも一つを推定し、判定部13は、解析部12による推定結果を用いて対象画像に示された状況における便器30を洗浄する洗浄方法を判定する。これにより、第1の実施形態の判定装置10では、排泄物や紙の使用量に応じた適切な洗浄方法を判定することができる。 Further, in the determination device 10 of the first embodiment, the determination item includes at least one of the stool properties and the amount of paper used for excretion, and the analysis unit 12 determines the stool properties in the target image. And at least one of the amount of paper used in excretion is estimated, and the determination unit 13 determines a cleaning method for cleaning the toilet bowl 30 in the situation shown in the target image using the estimation result by the analysis unit 12. .. As a result, the determination device 10 of the first embodiment can determine an appropriate cleaning method according to the amount of excrement and paper used.

なお、本実施形態では、排泄物の判定と洗浄方法の判定とを行う場合を例示して説明したが、排泄物の判定のみ、或いは洗浄方法の判定のみを行うようにしてもよい。 In this embodiment, the case where the determination of excrement and the determination of the cleaning method are performed has been described as an example, but only the determination of excrement or the determination of the cleaning method may be performed.

また、第1の実施形態の判定装置10では、判定事項は、排泄を行ったか否かの判定を含む。これにより、例えば、高齢者施設などにおいて、高齢者の見守りを行う場合において、高齢者が便器装置3にて排泄を行ったか否かを把握することが可能である。高齢者をトイレに誘導した場合に自力で排泄したのか、或いは排泄しなかったのか否かを基に、介護の内容を検討することもできる。
なお、排泄物に関する判定結果を用いて使用者の健康状態を判定するようにしてもよい。
Further, in the determination device 10 of the first embodiment, the determination item includes determination of whether or not excretion has been performed. Thereby, for example, in the case of watching over the elderly in a facility for the elderly, it is possible to grasp whether or not the elderly have excreted with the toilet bowl device 3. It is also possible to examine the content of long-term care based on whether or not the elderly were excreted by themselves when they were guided to the toilet.
In addition, the health condition of the user may be determined using the determination result regarding excrement.

(第2の実施形態)
次に、第2の実施形態について説明する。本実施形態では、紙の使用の有無などを判定対象とせず、便の性状のみを判定の対象とする点において上述した実施形態と異なる。また、対象画像に前処理を行う点において、上述した実施形態と異なる。ここでの前処理は、モデルに学習用の画像を機械学習させる前に、学習用の画像に対して行われる処理である。また、前処理は、学習済みモデルに未学習の画像を入力させる前に、未学習の画像に対して行われる処理である。以下の説明では、上述した実施形態と相違する構成のみ説明し、上述した実施形態と同等の構成については同じ符号を付してその説明を省略する。
(Second Embodiment)
Next, the second embodiment will be described. This embodiment is different from the above-described embodiment in that the presence or absence of the use of paper is not the subject of the determination, and only the properties of the stool are the subject of the determination. Further, it differs from the above-described embodiment in that the target image is preprocessed. The preprocessing here is a process performed on the image for learning before the model is machine-learned for the image for learning. Further, the pre-processing is a process performed on the unlearned image before the trained model is input with the unlearned image. In the following description, only configurations different from the above-described embodiment will be described, and the same reference numerals will be given to configurations equivalent to the above-described embodiments, and the description thereof will be omitted.

図7は、第2の実施形態の判定装置10が行う判定について説明する図である。図7には、特定の物をタイプA、B、Cの三種類に分類しようとする際の概念図が示されている。
一般に、便などの様々な性状を取り得る物を、その性状に基づいてタイプA、B、Cの三種類に分類しようとする場合、全ての物を明確に分類することは困難である。すなわち、タイプA、B、Cがそれぞれ混ざり合う状況が発生する場合が多い。例えば、図7に示すように、明確にタイプAと分類することができる領域E1、タイプA又はBと分類されるタイプAとBとが混ざる領域E2、明確にタイプBと分類することができる領域E3、タイプB又はCと分類されるタイプBとCとが混ざる領域E4、明確にタイプCと分類することができる領域E5、タイプC又はAと分類されるタイプCとAとが混ざる領域E6の領域が発生する。
FIG. 7 is a diagram for explaining the determination performed by the determination device 10 of the second embodiment. FIG. 7 shows a conceptual diagram when trying to classify a specific object into three types, types A, B, and C.
In general, when trying to classify things such as stools that can have various properties into three types A, B, and C based on the properties, it is difficult to clearly classify all the things. That is, there are many cases where types A, B, and C are mixed with each other. For example, as shown in FIG. 7, a region E1 that can be clearly classified as type A, a region E2 that is a mixture of types A and B classified as type A or B, and a region E2 that can be clearly classified as type B. Region E3, region E4 where types B and C classified as type B or C are mixed, region E5 which can be clearly classified as type C, region where type C and A classified as type C or A are mixed The region of E6 is generated.

DLにより、便の性状をタイプA、B、Cの三種類に分類するような学習済みモデルを構築した場合、タイプA、B、Cがそれぞれ混ざり合う領域において、推定の精度が低下することが考えられる。特に、水様便が便鉢32に溜められた洗浄水S(溜水面)に落下すると、落下した水様便から洗浄水Sに便の色が移り、拡散してしまう。これにより、水様便の前に排泄された水様便とは異なる性状の便がある場合であっても、水様便とは異なる性状の便と色が移った洗浄水Sとの色の差がほとんどなくなってしまう。この場合、学習済みモデルが、水様便とは異なる性状を有する便の性状を認識できなくなってしまい、水様便とは異なる性状の便があるにも関わらず、水様便と推定する等、推定誤りが生じることが考えられる。学習済みモデルによる推定に誤りがある場合、対象画像の判定に誤りが生じてしまう。 When a trained model that classifies stool properties into three types, types A, B, and C, is constructed by DL, the accuracy of estimation may decrease in the region where types A, B, and C are mixed. Conceivable. In particular, when watery stool falls on the washing water S (reservoir surface) stored in the toilet bowl 32, the color of the stool is transferred from the dropped watery stool to the washing water S and diffuses. As a result, even if there is a stool with a different property from the watery stool excreted before the watery stool, the color of the stool with a different property from the watery stool and the color of the washed water S that has been transferred There is almost no difference. In this case, the trained model cannot recognize the properties of stools that have properties different from those of watery stools, and even though there are stools that have properties different from those of watery stools, it is estimated to be watery stools. , It is possible that an estimation error will occur. If there is an error in the estimation by the trained model, an error will occur in the determination of the target image.

この対策として、本実施形態では、前処理により洗浄水Sの濁りなどの、推定誤りの要因となり得る要素(以下、ノイズ成分という)を除去する。これにより、学習済みモデルによる推定誤りを低減させ、対象画像の判定誤りを低減させることができる。 As a countermeasure, in the present embodiment, the pretreatment removes elements (hereinafter referred to as noise components) that may cause an estimation error, such as turbidity of the washing water S. As a result, it is possible to reduce the estimation error by the trained model and reduce the determination error of the target image.

図8は、第2の実施形態に係る判定装置10Aが適用される判定システム1Aの構成を示すブロック図である。判定システム1Aは、例えば、判定装置10A備える。判定装置10Aは、画像情報取得部11Aと、解析部12Aと、判定部13Aと、前処理部19を備える。 FIG. 8 is a block diagram showing a configuration of a determination system 1A to which the determination device 10A according to the second embodiment is applied. The determination system 1A includes, for example, a determination device 10A. The determination device 10A includes an image information acquisition unit 11A, an analysis unit 12A, a determination unit 13A, and a preprocessing unit 19.

画像情報取得部11Aは、排泄前における便鉢32の内部空間34を撮像した画像(基準画像)、及び、排泄後における便鉢32の内部空間34を撮像した画像(対象画像)それぞれの画像情報を取得する。排泄前とは、便器装置3の使用者が排泄をする前の任意の時点であり、例えば、使用者がトイレの個室に入った時や、便器30に着座した時である。 The image information acquisition unit 11A captures image information of the internal space 34 of the toilet bowl 32 before excretion (reference image) and an image of the internal space 34 of the toilet bowl 32 after excretion (target image). To get. The pre-excretion is an arbitrary time point before the user of the toilet bowl device 3 excretes, for example, when the user enters a private room of the toilet or when the user sits on the toilet bowl 30.

前処理部19は、基準画像と対象画像との画像情報を用いて、差分画像を生成する。差分画像は、基準画像と対象画像との差分を示す画像である。ここでの差分は、対象画像に撮像されており、基準画像に撮像されていない内容のことである。すなわち、差分画像は、排泄後の対象画像に撮像されており、排泄前の基準画像に撮像されていない、排泄物が表現された画像である。 The preprocessing unit 19 generates a difference image using the image information of the reference image and the target image. The difference image is an image showing the difference between the reference image and the target image. The difference here is the content that is captured in the target image and not captured in the reference image. That is, the difference image is an image expressing excrement, which is captured in the target image after excretion and not captured in the reference image before excretion.

前処理部19は、生成した差分画像の画像情報を、解析部12Aに出力する。また、前処理部19は、生成した差分画像の画像情報を画像情報記憶部15に記憶するようにしてもよい。解析部12Aは、学習済みモデルを用いて、差分画像における便の性状の推定を行う。解析部12Aが推定に用いる学習済みモデルは、排泄の前後の画像の差分を示す学習用の画像と、便の性状の評価の結果との対応関係を学習したモデルである。ここで、学習済みモデルを作成する際の学習に用いられた画像(排泄の前後の画像の差分を示す学習用の画像)は、「学習用差分画像」の一例である。 The preprocessing unit 19 outputs the image information of the generated difference image to the analysis unit 12A. Further, the preprocessing unit 19 may store the image information of the generated difference image in the image information storage unit 15. The analysis unit 12A estimates the properties of the stool in the difference image using the trained model. The trained model used by the analysis unit 12A for estimation is a model in which the correspondence between the learning image showing the difference between the images before and after excretion and the result of evaluation of the stool properties is learned. Here, the image used for learning when creating the trained model (the image for learning showing the difference between the images before and after excretion) is an example of the "difference image for learning".

判定部13Aは、解析部12Aにより推定された便の性状に基づいて、対象画像に示された便の性状を判定する。また、判定部13Aは、解析部12Aにより推定された便の性状に基づいて、使用者の排泄の状況を判定するようにしてもよい。判定部13Aが、使用者の排泄の状況を判定する方法については、後述する本実施形態のフローチャートにて説明する。 The determination unit 13A determines the properties of the stool shown in the target image based on the properties of the stool estimated by the analysis unit 12A. Further, the determination unit 13A may determine the excretion status of the user based on the stool properties estimated by the analysis unit 12A. The method by which the determination unit 13A determines the excretion status of the user will be described with reference to the flowchart of the present embodiment described later.

ここで、前処理部19が、差分画像を生成する方法について、基準画像と対象画像と差分画像との各画像の色がR(Red)G(Green)B(Blue)により表現されたRGB画像である場合を例に説明する。しかしながら、各画像はRGBにより色が表現された画像に限定されることはなく、RGB画像以外の画像(例えば、Lab画像や、YCbCr画像)である場合でも同様な方法で生成することができる。ここで、RGB値は、画像の色を示す情報であり、「色情報」の一例である。 Here, regarding the method for generating the difference image, the preprocessing unit 19 is an RGB image in which the colors of the reference image, the target image, and the difference image are expressed by R (Red) G (Green) B (Blue). This case will be described as an example. However, each image is not limited to an image whose color is expressed by RGB, and even if it is an image other than the RGB image (for example, a Lab image or a YCbCr image), it can be generated by the same method. Here, the RGB value is information indicating the color of the image, and is an example of "color information".

前処理部19は、基準画像における所定の画素のRGB値と、前記対象画像における当該所定の画素に対応する画素のRGB値との差分に基づき、前記差分画像における当該所定画素に対応する画素のRGB値を決定する。所定の画素に対応する画素とは、画像において同じ、或いは近傍の位置座標にある画素である。ここでの差分とは、二つの画素における色の差分を示しており、例えば、RGB値の相違に基づいて判定される。例えば、前処理部19は、RGB値が同じ色を示している場合には差分がなく、RGB値が同じ色を示していない場合には差分があると判定する。 The preprocessing unit 19 is based on the difference between the RGB value of the predetermined pixel in the reference image and the RGB value of the pixel corresponding to the predetermined pixel in the target image, and the preprocessing unit 19 of the pixel corresponding to the predetermined pixel in the difference image. Determine the RGB value. The pixel corresponding to a predetermined pixel is a pixel having the same or near position coordinates in the image. The difference here indicates the difference in color between the two pixels, and is determined based on, for example, the difference in RGB values. For example, the preprocessing unit 19 determines that there is no difference when the RGB values show the same color, and there is a difference when the RGB values do not show the same color.

例えば、前処理部19は、基準画像における所定画素のRGB値が(255、255、0)(黄色)であり、対象画像における所定画素のRGB値が(255、255、0)(黄色)である場合、二つの画素における色の差分がないため、差分画像における所定画素のRGB値を、差分がない旨を示す所定の色(例えば、白色)とするマスク処理を行う。 For example, in the preprocessing unit 19, the RGB value of the predetermined pixel in the reference image is (255, 255, 0) (yellow), and the RGB value of the predetermined pixel in the target image is (255, 255, 0) (yellow). In some cases, since there is no color difference between the two pixels, mask processing is performed so that the RGB values of the predetermined pixels in the difference image are set to a predetermined color (for example, white) indicating that there is no difference.

一方、前処理部19は、基準画像における所定画素のRGB値が(255、255、0)(黄色)であり、対象画像における所定画素のRGB値が(255、0、0)(赤色)である場合、二つの画素における色の差分があるため、差分画像における所定画素のRGB値を、対象画像における所定画素のRGB値(255、0、0)(赤色)とする。 On the other hand, in the preprocessing unit 19, the RGB value of the predetermined pixel in the reference image is (255, 255, 0) (yellow), and the RGB value of the predetermined pixel in the target image is (255, 0, 0) (red). In some cases, since there is a color difference between the two pixels, the RGB value of the predetermined pixel in the difference image is set to the RGB value (255, 0, 0) (red) of the predetermined pixel in the target image.

或いは、前処理部19は、二つの画素における色の差分がある場合、その旨を示す予め定めた所定の色(例えば、黒色)とするようにしてもよい。 Alternatively, if there is a color difference between the two pixels, the preprocessing unit 19 may use a predetermined color (for example, black) indicating that fact.

或いは、前処理部19は、二つの画素における色の差分がある場合、差分の度合いに応じて予め定めた所定の色とするようにしてもよい。差分の度合いは、例えば、色空間におけるRGB値のベクトル距離に応じて算出された値である。この場合、前処理部19は、二つの画素における色の差分を、その差分の度合いに応じて複数に分類する。例えば、差分の度合いが(大、中、小)の三種類に分類される場合、前処理部19は、差分の度合いが大きい画素については差分画像における当該画素のRGB値を黒色、差分の度合いが中程度の画素については差分画像における当該画素のRGB値を灰色、差分の度合いが小さい画素については差分画像における当該画素のRGB値を薄い灰色などとして、差分画像を生成するようにしてもよい。 Alternatively, if there is a color difference between the two pixels, the preprocessing unit 19 may use a predetermined color determined in advance according to the degree of the difference. The degree of difference is, for example, a value calculated according to the vector distance of the RGB values in the color space. In this case, the preprocessing unit 19 classifies the color difference between the two pixels into a plurality of colors according to the degree of the difference. For example, when the degree of difference is classified into three types (large, medium, and small), the preprocessing unit 19 sets the RGB value of the pixel in the difference image to black and the degree of difference for the pixel having a large degree of difference. For pixels with a medium value, the RGB value of the pixel in the difference image may be gray, and for pixels with a small degree of difference, the RGB value of the pixel in the difference image may be light gray to generate the difference image. ..

ここで、使用者の着座の加減などの影響により、被写体(便鉢32の内部空間34)に照射する光の光量が変化することが考えられる。光量が変化した場合、排泄の前後において変化がない箇所であっても、色の濃淡が変化する場合がある。このような場合、前処理部19が、色の濃淡の変化を色の差分があると判定してしまうことが考えられる。 Here, it is conceivable that the amount of light irradiating the subject (internal space 34 of the toilet bowl 32) changes depending on the influence of the user's seating. When the amount of light changes, the shade of color may change even in places where there is no change before and after excretion. In such a case, it is conceivable that the preprocessing unit 19 determines that the change in color shading has a color difference.

この対策として、前処理部19は、基準画像における所定画素の色の比率と、対象画像における所定画素の色の比率とに応じて、差分画像における所定画素の色を決定するようにしてもよい。色の比率は、RGBそれぞれの色の比率であり、例えば、所定の基準値に対する割合で示される。つまり、RGB値(R、G、B)の色の比率は、(R/L:G/L:B/L)である。ここで、Lは所定の基準値を示す。所定の基準値Lは、任意の値であってよい。また、所定の基準値Lは、RGB値によらず固定された値であってもよいし、RGB値により変動する値(例えばRGB値のR値など)であってもよい。 As a countermeasure, the preprocessing unit 19 may determine the color of the predetermined pixel in the difference image according to the color ratio of the predetermined pixel in the reference image and the color ratio of the predetermined pixel in the target image. .. The color ratio is the ratio of each color of RGB, and is shown, for example, as a ratio with respect to a predetermined reference value. That is, the color ratio of the RGB values (R, G, B) is (R / L: G / L: B / L). Here, L indicates a predetermined reference value. The predetermined reference value L may be any value. Further, the predetermined reference value L may be a fixed value regardless of the RGB value, or may be a value that varies depending on the RGB value (for example, the R value of the RGB value).

例えば、前処理部19は、基準画像における所定画素が灰色(RGB値(128、128、128))であり、対象画像における所定画素が薄い灰色(RGB値(192、192、192))である場合、二つの画素における色の比率が同じ比率であることから、二つの画素における色の差分がないと判定する。 For example, in the preprocessing unit 19, the predetermined pixels in the reference image are gray (RGB values (128, 128, 128)), and the predetermined pixels in the target image are light gray (RGB values (192, 192, 192)). In this case, since the color ratios of the two pixels are the same, it is determined that there is no color difference between the two pixels.

一方、前処理部19は、基準画像における所定画素が黄色(RGB値(255、255、0))であり、対象画像における所定画素が赤色(RGB値(255、0、0))である場合、二つの画素における色の比率が同じ比率でないことから、二つの画素における色の差分があると判定する。 On the other hand, in the preprocessing unit 19, when the predetermined pixel in the reference image is yellow (RGB value (255, 255, 0)) and the predetermined pixel in the target image is red (RGB value (255, 0, 0)). , Since the color ratios of the two pixels are not the same, it is determined that there is a color difference between the two pixels.

図9は、第2の実施形態に係る前処理部19が行う処理を説明する図である。図9の左側には基準画像の例として画像G1、中央には対象画像の例として画像G2、右側には差分画像の例として画像G3がそれぞれ示されている。
図9の画像G1に示すように、基準画像には、排泄前における、内部空間34が撮像されており、内部空間34の略中央にある開口部36に洗浄水Sが貯められた様子が撮像されている。
図9の画像G2に示すように、対象画像には、排泄後における、内部空間34が撮像されており、内部空間34の前側と後側との方向、洗浄水Sの上側に排泄物T1、T2がある様子が撮像されている。
図9の画像G3に示すように、差分画像には、基準画像と対象画像との差分である排泄物T1、T2が表現されている。
FIG. 9 is a diagram illustrating a process performed by the pretreatment unit 19 according to the second embodiment. The left side of FIG. 9 shows the image G1 as an example of the reference image, the center shows the image G2 as an example of the target image, and the right side shows the image G3 as an example of the difference image.
As shown in the image G1 of FIG. 9, in the reference image, the internal space 34 before excretion is imaged, and the state in which the washing water S is stored in the opening 36 substantially in the center of the internal space 34 is imaged. Has been done.
As shown in the image G2 of FIG. 9, in the target image, the internal space 34 after excretion is imaged, and the excrement T1 in the direction between the front side and the rear side of the internal space 34 and the upper side of the washing water S, The appearance of T2 is imaged.
As shown in the image G3 of FIG. 9, the excrement T1 and T2, which are the differences between the reference image and the target image, are represented in the difference image.

ここで、第2の実施形態に係る判定装置10Aが行う処理について、図10を用いて説明する。図10は第2の実施形態に係る判定装置10Aが行う処理の流れを示すフローチャートである。図10に示すフローチャートのうち、ステップS20、S22、S25〜S27、及びS29については、図4のフローチャートのS10、S11、S12〜S14、及びS15と同様であるため、その説明を省略する。 Here, the process performed by the determination device 10A according to the second embodiment will be described with reference to FIG. FIG. 10 is a flowchart showing a flow of processing performed by the determination device 10A according to the second embodiment. Of the flowcharts shown in FIG. 10, steps S20, S22, S25 to S27, and S29 are the same as S10, S11, S12 to S14, and S15 in the flowchart of FIG. 4, and thus the description thereof will be omitted.

ステップS21において、判定装置10Aは、使用者が便器30に着座したと判定する場合、基準画像を生成する。基準画像は、排泄前の便鉢32の内部空間34を示す画像である。判定装置10Aは、使用者が便器30に着座したと判定したら、撮像装置4に撮像を指示する制御信号を送信することにより、基準画像の画像情報を取得する。 In step S21, the determination device 10A generates a reference image when it is determined that the user is seated on the toilet bowl 30. The reference image is an image showing the internal space 34 of the toilet bowl 32 before excretion. When the determination device 10A determines that the user is seated on the toilet bowl 30, the determination device 10A acquires the image information of the reference image by transmitting a control signal instructing the image pickup to the image pickup device 4.

ステップS23において、判定装置10Aは、基準画像と対象画像とを用いて、マスク処理を行う。マスク処理は、基準画像と対象画像とに差分がない画素について、所定の色(例えば白色)とする処理である。
ステップS24において、判定装置10Aは、差分画像を生成する。差分画像は、例えば、基準画像と対象画像とに差分がない画素についてマスク処理がなされ、基準画像と対象画像とに差分がある画素について対象画像の画素値(RGB値)が反映された画像である。
In step S23, the determination device 10A performs mask processing using the reference image and the target image. The mask processing is a process of setting a predetermined color (for example, white) to pixels for which there is no difference between the reference image and the target image.
In step S24, the determination device 10A generates a difference image. The difference image is, for example, an image in which mask processing is performed on pixels for which there is no difference between the reference image and the target image, and the pixel value (RGB value) of the target image is reflected for pixels for which there is a difference between the reference image and the target image. is there.

ステップS28において、判定装置10Aは、使用者が便器30から脱座したと判定する場合、基準画像、対象画像、及び差分画像の画像情報を破棄する。具体的に、判定装置10Aは、画像情報記憶部15に記憶していた基準画像、対象画像、及び差分画像の画像情報を消去する。これにより、記憶容量が逼迫してしまうことを抑制することが可能である。 In step S28, when the determination device 10A determines that the user has left the toilet bowl 30, the determination device 10A discards the image information of the reference image, the target image, and the difference image. Specifically, the determination device 10A erases the image information of the reference image, the target image, and the difference image stored in the image information storage unit 15. As a result, it is possible to prevent the storage capacity from becoming tight.

なお、図10のステップS25に示す判定処理について、図4のステップS12に示す処理と同様である旨を説明したが、本実施形態では、少なくとも、便の性状を判定項目とした判定処理が行われればよい。 It has been explained that the determination process shown in step S25 of FIG. 10 is the same as the process shown in step S12 of FIG. 4, but in the present embodiment, at least the determination process using the properties of the stool as the determination item is performed. You just have to be.

また、図10のステップS25において、判定部13Aは、差分画像における便の性状の推定結果を用いて、使用者の排泄の状況を判定する。例えば、判定部13Aは、便の形状が、硬便であった場合は使用者の排便の状況が便秘傾向であると判定する。判定部13Aは、便の形状が、普通便であった場合は使用者の排便の状況が良好であると判定する。判定部13Aは、便の形状が、軟便であった場合は使用者の排便の状況が要観察状況であると判定する。判定部13Aは、便の形状が、泥状便、又は水様便であった場合は使用者の排便の状況が下痢傾向であると判定する。或いは、判定部13Aは、排便の状況から使用者の健康状態を判定しても良い。 Further, in step S25 of FIG. 10, the determination unit 13A determines the excretion status of the user by using the estimation result of the stool property in the difference image. For example, the determination unit 13A determines that the user's defecation status tends to be constipation when the shape of the stool is hard. The determination unit 13A determines that the defecation condition of the user is good when the shape of the stool is a normal stool. When the shape of the stool is loose, the determination unit 13A determines that the defecation status of the user is a condition requiring observation. When the shape of the stool is muddy stool or watery stool, the determination unit 13A determines that the defecation status of the user tends to be diarrhea. Alternatively, the determination unit 13A may determine the health condition of the user from the defecation status.

以上説明したように、第2の実施形態の判定装置10Aでは、前処理部19が基準画像と、対象画像との差分を示す差分画像を生成する。これにより、第2の実施形態の判定装置10Aでは、排泄の前後において差異がある部分を差分画像に示すことができるために、排泄物の性状をより精度よく把握して、その性状をより正確に判定することが可能となる。 As described above, in the determination device 10A of the second embodiment, the preprocessing unit 19 generates a difference image showing the difference between the reference image and the target image. As a result, in the determination device 10A of the second embodiment, since the portion having a difference before and after excretion can be shown in the difference image, the property of the excrement can be grasped more accurately and the property can be more accurately grasped. It becomes possible to judge.

また、第2の実施形態の判定装置10Aでは、前処理部19は、基準画像における所定画素の色を示す色情報と、対象画像の画素における当該所定画素に対応する画素の色情報との差分に基づいて、差分画像における当該所定画素に対応する画素の色情報を決定する。これにより、第2の実施形態の判定装置10Aでは、排泄の前後において、色に差異がある部分を差分画像に示すことができるため、上述した効果と同様な効果を奏する。 Further, in the determination device 10A of the second embodiment, the preprocessing unit 19 determines the difference between the color information indicating the color of the predetermined pixel in the reference image and the color information of the pixel corresponding to the predetermined pixel in the pixel of the target image. Based on, the color information of the pixel corresponding to the predetermined pixel in the difference image is determined. As a result, in the determination device 10A of the second embodiment, the portion having a color difference can be shown in the difference image before and after excretion, so that the same effect as the above-mentioned effect can be obtained.

また、第2の実施形態の判定装置10Aでは、前処理部19は、基準画像における所定画素のRGB値と、対象画像における当該所定画素に対応する画素のRGB値との差分を、差分画像における当該所定画素に対応する画素のRGB値とする。これにより、第2の実施形態の判定装置10Aでは、排泄の前後の色に差異を、RGB値の差異として認識することができるため、色の差異を定量的に算出でき、上述した効果と同様な効果を奏する。 Further, in the determination device 10A of the second embodiment, the preprocessing unit 19 sets the difference between the RGB value of the predetermined pixel in the reference image and the RGB value of the pixel corresponding to the predetermined pixel in the target image in the difference image. It is the RGB value of the pixel corresponding to the predetermined pixel. As a result, in the determination device 10A of the second embodiment, the difference in color before and after excretion can be recognized as the difference in RGB values, so that the color difference can be quantitatively calculated, and the same as the above-mentioned effect. It has a great effect.

また、第2の実施形態の判定装置10Aでは、前処理部19は、基準画像における所定画素のR値、G値、B値の比率を示す色比率と、対象画像における当該所定画素に対応する画素の色比率との差分に基づいて、差分画像における当該所定画素に対応する画素のRGB値を決定する。これにより、第2の実施形態の判定装置10Aでは、排泄の前後において被写体に照射される光量が異なるなどして、背景色に差異が生じた場合であっても、その差異を排泄物と誤認識することなく、排泄物の性状を抽出することができ、上述した効果と同様な効果を奏する。 Further, in the determination device 10A of the second embodiment, the preprocessing unit 19 corresponds to the color ratio indicating the ratio of the R value, the G value, and the B value of the predetermined pixel in the reference image and the predetermined pixel in the target image. The RGB value of the pixel corresponding to the predetermined pixel in the difference image is determined based on the difference from the color ratio of the pixel. As a result, in the determination device 10A of the second embodiment, even if there is a difference in the background color due to a difference in the amount of light applied to the subject before and after excretion, the difference is mistaken for excrement. The properties of excrement can be extracted without recognizing it, and the same effect as described above can be obtained.

なお、上記では、画像情報取得部11Aが基準画像の画像情報を取得する場合を例に説明したが、これに限定されない。例えば、基準画像の画像情報は任意の機能部により取得されてよいし、予め画像情報記憶部15に記憶されているものであってもよい。 In the above description, the case where the image information acquisition unit 11A acquires the image information of the reference image has been described as an example, but the present invention is not limited to this. For example, the image information of the reference image may be acquired by an arbitrary functional unit, or may be stored in the image information storage unit 15 in advance.

(第2の実施形態の変形例1)
次に、第2の実施形態の変形例1について説明する。本変形例では、前処理として、対象画像を分割した分割画像を生成する点において、上述した実施形態と異なる。以下の説明では、上述した実施形態と相違する構成のみ説明し、上述した実施形態と同等の構成については同じ符号を付してその説明を省略する。
(Modification 1 of the second embodiment)
Next, a modification 1 of the second embodiment will be described. This modification differs from the above-described embodiment in that a divided image obtained by dividing the target image is generated as a preprocessing. In the following description, only configurations different from the above-described embodiment will be described, and the same reference numerals will be given to configurations equivalent to the above-described embodiments, and the description thereof will be omitted.

一般に、便鉢32は、便鉢32の縁部から開口部36に向かうにしたがって下側に傾斜するように形成される。このため、便鉢32に落下した便が複数ある場合、先に落下したものが、後に落下したものに押されるようにして、便鉢32の傾斜面に沿って下側に移動すると考えられる。すなわち、先に落下したものが開口部36の前側に移動する性質がある。 Generally, the toilet bowl 32 is formed so as to incline downward from the edge of the toilet bowl 32 toward the opening 36. Therefore, when there are a plurality of stools that have fallen into the toilet bowl 32, it is considered that the one that has fallen first moves downward along the inclined surface of the toilet bowl 32 so as to be pushed by the one that has fallen later. That is, there is a property that the one that has fallen first moves to the front side of the opening 36.

この性質を利用して、本変形例では、排泄物の排出の時系列を考慮した推定を行う。具体的には、対象画像を前側と後側とに分割する。そして、対象画像の前側を分割した画像(前側分割画像)に撮像された排泄物を古い便、対象画像の後側を分割した画像(後側分割画像)に撮像された排泄物を新しい便とみなして、便の性状を判定する。これにより、使用者の排便の状況について、古い便を判定することで、現在の状態に近い便に基づく判定を行おうことができる。 Utilizing this property, in this modified example, estimation is performed in consideration of the time series of excrement discharge. Specifically, the target image is divided into a front side and a rear side. Then, the excrement captured in the image obtained by dividing the front side of the target image (front divided image) is referred to as old stool, and the excrement captured in the image obtained by dividing the rear side of the target image (rear divided image) is referred to as new stool. Determining the properties of the stool. As a result, it is possible to determine the defecation status of the user based on the stool that is close to the current state by determining the old stool.

本変形例において、前処理部19は、分割画像を生成する。分割画像は、対象画像の一部の領域が含まれている画像であって、例えば、前側分割画像、及び後側分割画像である。対象画像を前側分割画像と後側分割画像とに分割する境界は、任意に設定されてよいが、例えば、便鉢32に溜められた洗浄水Sの溜水面の中心を通る左右方向(左側と右側とを結ぶ方向)の線により分割される。 In this modification, the preprocessing unit 19 generates a divided image. The divided image is an image including a part of a region of the target image, and is, for example, a front divided image and a rear divided image. The boundary for dividing the target image into the front side divided image and the rear side divided image may be arbitrarily set. For example, in the left-right direction (left side) passing through the center of the water storage surface of the washing water S stored in the toilet bowl 32. It is divided by a line (in the direction connecting the right side).

なお、分割画像は、上記の前側分割画像と後側分割画像とに限定されることはない。分割画像は、対象画像の一部の領域が少なくとも含まれている画像であればよい。対象画像は、前後方向(前側と後側とを結ぶ方向)に三つの領域に分割された画像であってもよいし、前側分割画像が、更に左右方向に複数の領域に分割された画像であってもよい。また、対象画像から、一つの分割画像が生成されてもよいし、複数の分割画像が生成されてもよい。また、対象画像から複数の分割画像を生成する場合において、複数の分割画像に示される領域を結合した領域が、対象画像に示される領域の全部であってもよいし、一部の領域であってもよい。 The divided image is not limited to the above-mentioned front-side divided image and rear-side divided image. The divided image may be an image that includes at least a part of the target image. The target image may be an image divided into three regions in the front-rear direction (the direction connecting the front side and the rear side), or the front-side divided image may be an image further divided into a plurality of regions in the left-right direction. There may be. Further, one divided image may be generated from the target image, or a plurality of divided images may be generated. Further, when a plurality of divided images are generated from the target image, the region in which the regions shown in the plurality of divided images are combined may be the entire region shown in the target image, or may be a part of the region. You may.

前処理部19は、生成した分割画像の画像情報を解析部12Aに出力する。また、前処理部19は、生成した分割画像の画像情報を画像情報記憶部15に記憶するようにしてもよい。解析部12Aは、学習済みモデルを用いて、分割画像における便の性状の推定を行う。解析部12Aが推定に用いる学習済みモデルは、排泄における便鉢32の内部空間34を撮像した画像を分割した学習用の画像と、便の性状の評価の結果との対応関係を学習したモデルである。 The preprocessing unit 19 outputs the image information of the generated divided image to the analysis unit 12A. Further, the preprocessing unit 19 may store the image information of the generated divided image in the image information storage unit 15. The analysis unit 12A estimates the properties of the stool in the divided image using the trained model. The trained model used for estimation by the analysis unit 12A is a model that learns the correspondence between the training image obtained by dividing the image of the internal space 34 of the toilet bowl 32 in excretion and the result of evaluation of the stool properties. is there.

判定部13Aは、解析部12Aにより推定された分割画像における便の性状に基づいて、対象画像に示された状況における使用者の排泄の状況を判定する。判定部13Aは、対象画像から生成された分割画像が複数ある場合、分割画像それぞれの推定結果を総合的にみて使用者の排泄の状況を判定する。判定部13Aが総合的に使用者の排泄の状況を判定する方法については、後述する本変形例のフローチャートにて説明する。 The determination unit 13A determines the excretion status of the user in the situation shown in the target image based on the properties of the stool in the divided image estimated by the analysis unit 12A. When there are a plurality of divided images generated from the target image, the determination unit 13A comprehensively looks at the estimation results of each of the divided images and determines the excretion status of the user. The method by which the determination unit 13A comprehensively determines the excretion status of the user will be described with reference to the flowchart of this modification described later.

ここで、学習済みモデルを作成する際の学習に用いられる画像(排泄における便鉢32の内部空間34を撮像した画像を分割した学習用の画像)について説明する。本変形例における学習用の画像としての分割画像は、「学習用分割画像」の一例である。学習用の画像としての分割画像は、過去の排泄の際に撮像された、便鉢32の内部空間34の様々な画像の一部の領域を分割した画像である。前処理部23による画像を分割する方法は、任意であってよいが、前処理部19による分割と同様な方法であることが望ましい。同様な方法とすることにより、学習済みモデルを用いた推定の精度の向上が期待できる。また、学習済みモデルに対象画像の全体を学習させる場合よりも、対象画像の一部の領域、つまり対象画像よりも狭い領域を学習させるようにしたために、学習済みモデルを、より精度よく領域の状態を推定するモデルとすることが可能である。 Here, an image used for learning when creating a trained model (an image for learning obtained by dividing an image of the internal space 34 of the toilet bowl 32 in excretion) will be described. The divided image as the learning image in this modification is an example of the “learning divided image”. The divided image as the image for learning is an image obtained by dividing a part of various images of the internal space 34 of the toilet bowl 32, which was taken during the past excretion. The method of dividing the image by the preprocessing unit 23 may be arbitrary, but it is desirable that the method is the same as the method of dividing the image by the preprocessing unit 19. By using the same method, it is expected that the accuracy of estimation using the trained model will be improved. In addition, since the trained model is trained in a part of the target image, that is, a region narrower than the target image, the trained model can be trained more accurately than when the trained model is trained in the entire target image. It can be a model for estimating the state.

図11は、第2の実施形態の変形例1に係る前処理部19が行う処理を説明する図である。図11の左側には対象画像の例として画像G4、中央には前側分割画像の例として画像G5、右側には後側分割画像の例として画像G6がそれぞれ示されている。
図11の画像G4に示すように、対象画像には、内部空間34が撮像されており、内部空間34の略中央にある開口部36に洗浄水Sが貯められた様子を含む、内部空間34の全体が撮像されている。
図11の画像G5に示すように、前側分割画像には、内部空間34の前側の領域が抽出されており、開口部36に洗浄水Sが貯められた溜水面の中心を通る左右方向の境界線より前側の領域が抽出されている。
図11の画像G6に示すように、後側分割画像には、内部空間34の後側の領域が抽出されており、溜水面の中心を通る左右方向の境界線より後側の領域が抽出されている。
FIG. 11 is a diagram illustrating a process performed by the pretreatment unit 19 according to the first modification of the second embodiment. Image G4 is shown on the left side of FIG. 11 as an example of the target image, image G5 is shown as an example of the front split image in the center, and image G6 is shown as an example of the rear split image on the right side.
As shown in the image G4 of FIG. 11, in the target image, the internal space 34 is imaged, and the internal space 34 includes a state in which the washing water S is stored in the opening 36 substantially in the center of the internal space 34. The whole of is imaged.
As shown in the image G5 of FIG. 11, the front region of the internal space 34 is extracted from the front split image, and the boundary in the left-right direction passing through the center of the pool surface in which the wash water S is stored in the opening 36. The area in front of the line is extracted.
As shown in the image G6 of FIG. 11, the rear region of the internal space 34 is extracted from the rear split image, and the region posterior to the lateral boundary line passing through the center of the water reservoir surface is extracted. ing.

ここで、第2の実施形態の変形例1に係る判定装置10Aが行う処理について、図12を用いて説明する。図12は第2の実施形態の変形例1に係る判定装置10Aが行う処理の流れを示すフローチャートである。図12に示すフローチャートのうち、ステップS30、S31、S33、S37、及びS42については、図4のフローチャートのS10、S11、S14、S15、及びS13と同様であるため、その説明を省略する。 Here, the process performed by the determination device 10A according to the first modification of the second embodiment will be described with reference to FIG. FIG. 12 is a flowchart showing a flow of processing performed by the determination device 10A according to the first modification of the second embodiment. Of the flowcharts shown in FIG. 12, steps S30, S31, S33, S37, and S42 are the same as S10, S11, S14, S15, and S13 in the flowchart of FIG. 4, and thus the description thereof will be omitted.

ステップS32において、判定装置10Aは、対象画像を用いて、分割画像を生成する。分割画像は、例えば、対象画像に撮像された領域の前側の領域を示す前側分割画像、及び後側の領域を示す後側分割画像である。 In step S32, the determination device 10A generates a divided image using the target image. The divided image is, for example, a front divided image showing a region on the front side of the region captured in the target image, and a rear divided image showing the region on the rear side.

ステップS34において、判定装置10Aは、前側分割画像及び後側分割画像それぞれの分割画像について判定処理を行う。この判定処理の内容は、図10のフローチャートにおけるステップS25に示す処理と同様であるため、その説明を省略する。 In step S34, the determination device 10A performs determination processing for each of the front-side divided image and the rear-side divided image. Since the content of this determination process is the same as the process shown in step S25 in the flowchart of FIG. 10, the description thereof will be omitted.

ステップS35において、判定装置10Aは、使用者が便器30から脱座したと判定しない場合(ステップS33、NO)、便器30における局部洗浄の操作が行われたか否かを判定し、便器30における局部洗浄の操作が行われた場合には、ステップS34に示す処理を行う。
ステップS36において、判定装置10Aは、便器30における局部洗浄の操作が行われたと判定しない場合(ステップS35、NO)、便器30における便器洗浄の操作が行われたか否かを判定し、便器30における便器洗浄の操作が行われた場合には、ステップS34に示す処理を行う。
In step S35, if the determination device 10A does not determine that the user has left the toilet bowl 30 (steps S33, NO), the determination device 10A determines whether or not the local cleaning operation on the toilet bowl 30 has been performed, and determines whether or not the local cleaning operation on the toilet bowl 30 has been performed. When the cleaning operation is performed, the process shown in step S34 is performed.
In step S36, when the determination device 10A does not determine that the local cleaning operation on the toilet bowl 30 has been performed (step S35, NO), the determination device 10A determines whether or not the toilet bowl cleaning operation on the toilet bowl 30 has been performed, and the toilet bowl 30 When the toilet bowl cleaning operation is performed, the process shown in step S34 is performed.

ステップS38において、判定装置10Aは、前側分割画像及び後側分割画像の双方に判定結果があるか否かを判定する。双方に判定結果があるとは、双方に便の画像があり、それぞれの便の画像について性状についての判定結果があることを示す。
ステップS39において、判定装置10Aは、前側分割画像及び後側分割画像の双方に判定結果がある場合、前側分割画像の判定結果を古い便の判定結果、後側分割画像の判定結果を新しい便の判定結果とする。
In step S38, the determination device 10A determines whether or not there is a determination result in both the front-side divided image and the rear-side divided image. The fact that both sides have a judgment result means that both sides have an image of a stool and that each stool image has a judgment result regarding the properties.
In step S39, when the determination device 10A has a determination result in both the front divided image and the rear divided image, the determination result of the front divided image is the determination result of the old flight, and the determination result of the rear divided image is the determination result of the new flight. It is the judgment result.

ステップS40において、判定装置10Aは、判定部13Aにより確定処理を行う。確定処理は、新しい便の判定結果、及び古い便の判定結果を用いて、使用者の排泄の状況を確定する処理である。判定装置10Aは、例えば、古い便が現在の排泄の状況を反映するとみなして排泄の状況を確定する。確定処理において、判定部13Aは、例えば、古い便の性状が硬便と判定され、新しい便の性状が普通便と判定された場合には、排便の際に大腸に残っていた固い便が排出され、使用者の排泄の状況は便秘傾向であると判定する。一方、確定処理において、判定部13Aは、例えば、古い便の性状が普通便と判定され、新しい便の性状が泥状便と判定された場合には、使用者の排泄の状況は良好であると判定する。 In step S40, the determination device 10A performs a determination process by the determination unit 13A. The confirmation process is a process for determining the excretion status of the user by using the determination result of the new stool and the determination result of the old stool. The determination device 10A determines the excretion status by assuming that the old stool reflects the current excretion status, for example. In the confirmation process, for example, when the property of the old stool is determined to be hard stool and the property of the new stool is determined to be normal stool, the determination unit 13A discharges the hard stool remaining in the large intestine during defecation. It is determined that the user's excretion status tends to be constipation. On the other hand, in the confirmation process, when the property of the old stool is determined to be normal stool and the property of the new stool is determined to be muddy stool, for example, the determination unit 13A has a good excretion condition of the user. Is determined.

ステップS41において、判定装置10Aは、判定部13Aにより前側分割画像及び後側分割画像の一方しか判定結果がない場合、前側分割画像の判定結果が有るか否かを判定する。前側分割画像の判定結果が有る場合、前側分割画像の判定結果を用いてステップS40に示す処理を行う。前側分割画像の判定結果がない場合、後側分割画像の判定結果を用いてステップS40に示す処理を行う。前側分割画像の判定結果がない場合とは、例えば、前側分割画像に排泄物が撮像されておらず、便の性状を判定することができなかった場合である。 In step S41, when the determination unit 13A has a determination result of only one of the front side divided image and the rear side divided image, the determination device 10A determines whether or not there is a determination result of the front side divided image. If there is a determination result of the front split image, the process shown in step S40 is performed using the determination result of the front split image. If there is no determination result of the front split image, the process shown in step S40 is performed using the determination result of the rear split image. The case where there is no determination result of the front side divided image is, for example, a case where excrement is not imaged in the front side divided image and the property of stool cannot be determined.

以上説明したように、第2の実施形態の変形例1に係る判定装置10Aでは、前処理部19が対象画像の一部の領域を含む分割画像を生成する。これにより、第2の実施形態の変形例1に係る判定装置10Aでは、対象画像の一部の領域を判定の対象とすることができ、対象画像の全体を判定対象とする場合よりも、狭い領域を詳しく判定することができ、より精度よく判定を行うことが可能である。 As described above, in the determination device 10A according to the first modification of the second embodiment, the preprocessing unit 19 generates a divided image including a part of the target image. As a result, in the determination device 10A according to the first modification of the second embodiment, a part of the target image can be the target of the determination, which is narrower than the case where the entire target image is the target of the determination. The area can be determined in detail, and the determination can be made more accurately.

また、第2の実施形態の変形例1に係る判定装置10Aでは、前処理部19は、対象画像における便鉢の前側の領域を少なくとも示す前側分割画像を生成する。これにより、第2の実施形態の変形例1に係る判定装置10Aでは、対象画像において新しい便と古い便とが撮像されている場合には、新しい便が撮像されたとみなされる領域を分割画像とすることができる。また、対象画像において新しい便と古い便とが撮像されていない場合でも、便が撮像される可能性が高い領域を分割画像とすることができ、上述した効果と同様な効果を奏する。 Further, in the determination device 10A according to the first modification of the second embodiment, the preprocessing unit 19 generates a front side divided image showing at least the front side region of the toilet bowl in the target image. As a result, in the determination device 10A according to the first modification of the second embodiment, when the new stool and the old stool are imaged in the target image, the region considered to be the image of the new stool is regarded as the divided image. can do. Further, even when the new stool and the old stool are not imaged in the target image, the region where the stool is likely to be imaged can be a divided image, and the same effect as the above-mentioned effect can be obtained.

また、第2の実施形態の変形例1に係る判定装置10Aでは、前処理部19は、前側分割画像と、後側分割画像とを生成し、解析部12Aは、前側分割画像について判定事項に関する推定を行うと共に、後側分割画像について判定事項に関する推定を行い、判定部13Aは、前側分割画像についての推定結果と、後側分割画像についての推定結果を用いて、前記対象画像について前記判定事項に関する判定を行う。これにより、第2の実施形態の変形例1に係る判定装置10Aでは、前側分割画像と後側分割画像との推定結果とを用いて、総合的に使用者の排泄の状況を判定することが可能となり、前側分割画像又は後側分割画像の何れか一方の推定結果を用いる場合より、精度のよい判定を行うことが可能である。 Further, in the determination device 10A according to the first modification of the second embodiment, the preprocessing unit 19 generates a front-side divided image and a rear-side divided image, and the analysis unit 12A relates to the determination items for the front-side divided image. In addition to performing the estimation, the determination items are estimated for the rear divided image, and the determination unit 13A uses the estimation results for the front divided image and the estimation results for the rear divided image to determine the determination items for the target image. Make a judgment about. As a result, the determination device 10A according to the first modification of the second embodiment can comprehensively determine the excretion status of the user by using the estimation results of the front-side divided image and the rear-side divided image. This makes it possible to make a more accurate determination than when using the estimation result of either the front-side divided image or the rear-side divided image.

また、第2の実施形態の変形例1に係る判定装置10Aでは、前処理部19は、前側分割画像についての推定結果を、後側分割画像についての推定結果よりも時系列的に古い推定結果として、前記対象画像について前記判定事項に関する判定を行う。これにより、第2の実施形態の変形例1に係る判定装置10Aでは、前側分割画像についての推定結果を古い便の推定結果、後側分割画像についての推定結果を新しい便の推定結果とみなして、排泄の時系列を考慮した判定を行うことができ、使用者の排泄の状況についてより現在の状態に近い精度のよい判定を行うことが可能である。
なお、便鉢32の形状により先に落下した便が移動する方向が変わるため、前側分割画像及び後側分割画像に対応付ける時系列の関係性は逆転してもよい。すなわち、上記では前側分割画像が後側分割画像よりも時系列的に古いものとして説明したが、これに限定されることはなく、前側分割画像が後側分割画像よりも時系列的に新しいものみなして、判定(確定)に係る処理が行われてもよい。
Further, in the determination device 10A according to the first modification of the second embodiment, the preprocessing unit 19 sets the estimation result for the front split image to be older than the estimation result for the rear split image in time series. As a result, the target image is determined regarding the determination items. As a result, in the determination device 10A according to the first modification of the second embodiment, the estimation result for the front split image is regarded as the estimation result for the old stool, and the estimation result for the rear split image is regarded as the estimation result for the new stool. , It is possible to make a determination in consideration of the time series of excretion, and it is possible to make an accurate determination of the excretion status of the user closer to the current state.
Since the direction in which the previously dropped stool moves changes depending on the shape of the toilet bowl 32, the time-series relationship associated with the front-side divided image and the rear-side divided image may be reversed. That is, in the above, the front split image has been described as being older than the rear split image in time series, but the present invention is not limited to this, and the front split image is newer in time series than the rear split image. Assuming that, the process related to the determination (confirmation) may be performed.

(第2の実施形態の変形例2)
次に、第2の実施形態の変形例2について説明する。本変形例では、前処理として、対象画像の全体を示す全体画像、及び対象画像の一部を切り出した部分画像を生成する点において、上述した実施形態と異なる。以下の説明では、上述した実施形態と相違する構成のみ説明し、上述した実施形態と同等の構成については同じ符号を付してその説明を省略する。
(Modification 2 of the second embodiment)
Next, a modification 2 of the second embodiment will be described. This modification differs from the above-described embodiment in that, as preprocessing, an entire image showing the entire target image and a partial image obtained by cutting out a part of the target image are generated. In the following description, only configurations different from the above-described embodiment will be described, and the same reference numerals will be given to configurations equivalent to the above-described embodiments, and the description thereof will be omitted.

一般に、機械学習の手法を用いて、画像の全体から詳細な判定内容を推定させようとすると、高い演算能力が必要となり、装置コストが増大してしまう。例えば、モデルに用いるDNNの層の数を増やせば、ノードの数が増加するために一回の試行に要する演算の回数が増え処理負荷が増大する。また、モデルが詳細な内容を推定できるようになる(つまり、学習データの入力に対するモデルの出力と、学習データの出力との誤差が最小となる)には、重みWとバイアス成分bを変更させながら、試行を繰り返し何度も行う必要があり、このような繰り返しの試行を現実的な時間で収束させるためには、膨大な演算を高速に処理できる装置が必要となる。すなわち、対象画像の全体を詳細に解析しようとすると高性能の装置が必要となり、装置コストが増大してしまう。 In general, if a machine learning method is used to estimate detailed judgment contents from the entire image, high computing power is required and the device cost increases. For example, if the number of DNN layers used in the model is increased, the number of operations required for one trial increases because the number of nodes increases, and the processing load increases. Further, in order for the model to be able to estimate the detailed contents (that is, the error between the output of the model and the output of the training data with respect to the input of the training data is minimized), the weight W and the bias component b are changed. However, it is necessary to repeat the trials many times, and in order to converge such repeated trials in a realistic time, a device capable of processing a huge amount of operations at high speed is required. That is, if it is attempted to analyze the entire target image in detail, a high-performance device is required, and the device cost increases.

ところで、対象画像は、便鉢32の内部空間34の全体が撮像された画像である。すわち、対象画像には、排泄物が撮像された領域と、排泄物が撮像されていない領域とが存在する。このため、対象画像から、排泄物が落下することが多いと考えられる特定の領域(例えば、開口部36の近傍領域)を切り出し、切り出した領域について、詳細な判定内容を推定させ方法が考えられる。これにより、解析の対象とする画像の領域を狭めることができ、装置コストの増大を抑制することが可能となる。 By the way, the target image is an image obtained by capturing the entire internal space 34 of the toilet bowl 32. That is, the target image has a region in which excrement is imaged and a region in which excrement is not imaged. Therefore, a method is conceivable in which a specific region (for example, a region near the opening 36) where excrement is likely to fall is cut out from the target image, and detailed determination contents are estimated for the cut out region. .. As a result, the area of the image to be analyzed can be narrowed, and an increase in device cost can be suppressed.

しかしながら、本来、排泄物が、便鉢32の何処の領域に落下するか不明である。また、使用者の体調により便の性状は変化する。このため、排泄物が落下する領域が、便鉢32の特定の領域である場合が多かったとしても、常にその特定の領域のみに排泄物が落下するとも限らず、周囲に飛散する場合もあり得る。周囲に飛散しているにも関わらず、周囲の画像を用いることなく、特定の領域の画像のみを用いて判定を行うと、実態とは異なる判定をしてしまう可能性がある。 However, it is originally unknown where in the toilet bowl 32 the excrement falls. In addition, the properties of stool change depending on the physical condition of the user. Therefore, even if the area where the excrement falls is often a specific area of the toilet bowl 32, the excrement does not always fall only in the specific area and may be scattered around. obtain. If the judgment is made using only the image of a specific area without using the surrounding image even though it is scattered in the surroundings, the judgment may be different from the actual situation.

この対策として、本変形例では、前処理により、対象画像の全体を示す全体画像と、対象画像の一部を切り出した部分画像とを生成する。 As a countermeasure for this, in this modification, a whole image showing the entire target image and a partial image obtained by cutting out a part of the target image are generated by preprocessing.

全体画像については、詳細ではない大局的な判定を行うことにより、装置コストの増大の抑制を図る。大局的な判定とは、便の性状を判定することと比較して、全体的(大局的)な判定であり、例えば、便の飛散の有無を判定することである。便の飛散の有無は、飛散した便の性状を判定するものではないため、便の性状を判定する場合と比較して、比較的大まかで容易な判定であるということができる。ここで、全体画像について行う、便の飛散の有無に係る判定は、「第1判定事項」の一例である。 For the entire image, the increase in equipment cost is suppressed by making a global judgment that is not detailed. The global determination is an overall (global) determination as compared with determining the properties of the stool, and is, for example, determining the presence or absence of stool scattering. Since the presence or absence of scattered stools does not determine the properties of the scattered stools, it can be said that the determination is relatively rough and easy as compared with the case of determining the properties of the stools. Here, the determination regarding the presence or absence of stool scattering performed on the entire image is an example of the "first determination item".

一方、部分画像については、全体画像に係る判定よりも詳細な判定項目についての判定を行う。詳細な判定項目とは、例えば、便の性状を判定することである。画像の領域を狭めた部分画像を判定対象とすることにより、高性能な装置を用いなくとも、詳細な判定を行うことができ装置コストの増大の抑制を図る。ここで、部分画像について行う、便の性状に係る判定は、「第2判定事項」の一例である。 On the other hand, for the partial image, a judgment is made for more detailed judgment items than the judgment for the whole image. The detailed determination item is, for example, to determine the properties of the stool. By targeting a partial image in which the area of the image is narrowed, detailed judgment can be performed without using a high-performance device, and an increase in device cost can be suppressed. Here, the determination regarding the properties of the stool performed on the partial image is an example of the "second determination item".

本変形例において、前処理部19は、全体画像、及び部分画像を生成する。全体画像は、対象画像の全体を示す画像であり、例えば、対象画像そのものである。部分画像は、対象画像の一部の領域を切り出した画像であって、例えば、対象画像から開口部36の近傍領域を切り出した画像である。部分画像として、対象画像の何処の領域を切り出すかは任意に設定されてよく、例えば、便器30の形状に応じて出荷時などに決定された固定の領域である。 In this modification, the preprocessing unit 19 generates an entire image and a partial image. The whole image is an image showing the whole of the target image, for example, the target image itself. The partial image is an image obtained by cutting out a part of a region of the target image, for example, an image obtained by cutting out a region near the opening 36 from the target image. As a partial image, which region of the target image to be cut out may be arbitrarily set, and is, for example, a fixed region determined at the time of shipment according to the shape of the toilet bowl 30.

前処理部19は、生成した全体画像及び部分画像の画像情報を解析部12Aに出力する。また、前処理部19は、生成した全体画像及び部分画像の画像情報を画像情報記憶部15に記憶するようにしてもよい。 The preprocessing unit 19 outputs the image information of the generated whole image and partial image to the analysis unit 12A. Further, the preprocessing unit 19 may store the generated image information of the entire image and the partial image in the image information storage unit 15.

解析部12Aは、学習済みモデルを用いて、全体画像における便の飛散の有無の推定を行う。ここで、全体画像における便の飛散の有無の推定は、「第1推定」の一例である。 The analysis unit 12A estimates the presence or absence of stool scattering in the entire image using the trained model. Here, the estimation of the presence or absence of stool scattering in the entire image is an example of the "first estimation".

また、解析部12Aは、学習済みモデルを用いて、部分画像における便の性状の推定を行う。ここで、部分画像における便の性状の推定は、「第2推定」の一例である。 In addition, the analysis unit 12A estimates the properties of the stool in the partial image using the trained model. Here, the estimation of the stool properties in the partial image is an example of the "second estimation".

判定部13Aは、解析部12Aにより推定された全体画像における便の飛散の有無、及び部分画像における便の性状に基づいて、対象画像に示された状況における使用者の排泄の状況を判定する。判定部13Aが全体画像における推定結果、及び部分画像における推定結果に基づいて使用者の排泄の状況を判定する方法については、後述する本変形例のフローチャートにて説明する。 The determination unit 13A determines the excretion status of the user in the situation shown in the target image based on the presence or absence of stool scattering in the entire image estimated by the analysis unit 12A and the properties of the stool in the partial image. The method by which the determination unit 13A determines the excretion status of the user based on the estimation result in the whole image and the estimation result in the partial image will be described in the flowchart of this modification described later.

ここで、本変形例で用いる学習済みモデルに学習させる学習データについて説明する。
全体画像の推定に用いる学習済みモデルは、排泄における便鉢32の内部空間34の全体を撮像した学習用の全体画像と、便の飛散の有無を評価した評価結果との対応関係を学習したモデルである。学習用の全体画像は、過去の排泄の際に撮像された、便鉢32の内部空間34の全体を示す様々な画像である。学習用の全体画像(排泄における便鉢32の内部空間34の全体を撮像した学習用の画像)は、「学習用全体画像」の一例である。
部分画像の推定に用いる学習済みモデルは、排泄における便鉢32の内部空間34の全体を撮像した画像から一部を切り出した学習用の部分画像と、便の性状を評価した評価結果との対応関係を学習したモデルである。学習用の部分画像は、全体画像の一部を切り出した画像である。学習用の部分画像(排泄における便鉢32の内部空間34の全体を撮像した画像から一部を切り出した学習用の画像)は、「学習用部分画像」の一例である。
学習用の全体画像、及び学習用の部分画像を生成する方法は、任意であってよいが、前処理部19による全体画像及び部分画像の生成と同様な方法であることが望ましい。同様な方法とすることにより、学習済みモデルを用いた推定の精度の向上が期待できる。
Here, the training data to be trained by the trained model used in this modification will be described.
The trained model used for estimating the whole image is a model that learns the correspondence between the whole image for learning that images the entire internal space 34 of the toilet bowl 32 in excretion and the evaluation result that evaluates the presence or absence of stool scattering. Is. The whole image for learning is various images showing the whole internal space 34 of the toilet bowl 32 taken during the past excretion. The whole image for learning (an image for learning that captures the entire internal space 34 of the toilet bowl 32 in excretion) is an example of the “whole image for learning”.
The trained model used for estimating the partial image is a correspondence between the learning partial image obtained by cutting out a part of the entire internal space 34 of the toilet bowl 32 in excretion and the evaluation result of evaluating the properties of the stool. It is a model that learned the relationship. The partial image for learning is an image obtained by cutting out a part of the whole image. The learning partial image (a learning image obtained by cutting out a part of the entire internal space 34 of the toilet bowl 32 in excretion) is an example of the “learning partial image”.
The method for generating the whole image for learning and the partial image for learning may be arbitrary, but it is desirable that the method is the same as the method for generating the whole image and the partial image by the preprocessing unit 19. By using the same method, it is expected that the accuracy of estimation using the trained model will be improved.

図13は、第2の実施形態の変形例2に係る前処理部19が行う処理を説明する図である。図13の左側には対象画像の例として画像G7、中央には全体画像の例として画像G8、右側には部分画像の例として画像G9がそれぞれ示されている。
図13の画像G7に示すように、対象画像には、内部空間34が撮像されており、内部空間34の略中央にある開口部36に洗浄水Sが貯められた様子を含む、内部空間34の全体が撮像されている。
図13の画像G8に示すように、全体画像には、対象画像の全体が示されている。全体画像は対象画像そのものであってもよいし、対象画像からその全体を抽出したものであってもよい。
図13の画像G9に示すように、部分画像には、内部空間34の略中央、開口部36の近傍の領域が抽出されており、洗浄水Sが溜められた溜水面とその周辺の領域が抽出されている。
FIG. 13 is a diagram illustrating a process performed by the pretreatment unit 19 according to the second modification of the second embodiment. The left side of FIG. 13 shows an image G7 as an example of a target image, the center shows an image G8 as an example of an entire image, and the right side shows an image G9 as an example of a partial image.
As shown in the image G7 of FIG. 13, in the target image, the internal space 34 is imaged, and the internal space 34 includes a state in which the washing water S is stored in the opening 36 substantially in the center of the internal space 34. The whole of is imaged.
As shown in the image G8 of FIG. 13, the entire target image is shown in the overall image. The whole image may be the target image itself, or the whole image may be extracted from the target image.
As shown in the image G9 of FIG. 13, in the partial image, a region near the opening 36 at the substantially center of the internal space 34 is extracted, and the pool surface in which the wash water S is stored and the region around the pool surface are extracted. It has been extracted.

ここで、第2の実施形態の変形例2に係る判定装置10Aが行う処理について、図14を用いて説明する。図14は第2の実施形態の変形例2に係る判定装置10Aが行う処理の流れを示すフローチャートである。図14に示すフローチャートのうち、ステップS50、S51、S53、S57、及びS62については、図4のフローチャートのS10、S11、S14、S15、及びS13と同様であるため、その説明を省略する。また、図14に示すフローチャートのうち、ステップS55、及びS56については、図12のフローチャートのS35、及びS36と同様であるため、その説明を省略する。 Here, the process performed by the determination device 10A according to the second modification of the second embodiment will be described with reference to FIG. FIG. 14 is a flowchart showing a flow of processing performed by the determination device 10A according to the second modification of the second embodiment. Of the flowcharts shown in FIG. 14, steps S50, S51, S53, S57, and S62 are the same as S10, S11, S14, S15, and S13 in the flowchart of FIG. 4, and thus the description thereof will be omitted. Further, among the flowcharts shown in FIG. 14, steps S55 and S56 are the same as those of the flowcharts S35 and S36 of FIG. 12, so the description thereof will be omitted.

ステップS52において、判定装置10Aは、対象画像を用いて、全体画像及び部分画像を生成する。全体画像は、例えば、対象画像に撮像された領域の全体を示す画像である。部分画像は、例えば、対象画像に撮像された領域の特定の一部の領域を示す画像である。 In step S52, the determination device 10A generates a whole image and a partial image using the target image. The whole image is, for example, an image showing the whole area captured by the target image. The partial image is, for example, an image showing a specific part of a region captured in the target image.

ステップS54において、判定装置10Aは、全体画像及び部分画像それぞれについて判定処理を行う。
判定装置10Aは、全体画像について大局的な判定、例えば便の飛散の有無の判定を行う。判定装置10Aは、学習済みモデルを用いて全体画像における便の飛散の有無を推定し、推定した結果を全体画像における便の飛散の有無を判定した判定結果とする。ここでの学習済みモデルは、学習用の全体画像と便の飛散の有無を判定した判定結果とを対応付けた学習データを用いて学習することにより作成されたモデルである。
また、判定装置10Aは、部分画像について詳細な判定、例えば便の性状の判定を行う。判定装置10Aは、学習済みモデルを用いて部分画像における便の性状を推定し、推定した結果を部分画像における便の性状を判定した判定結果とする。ここでの学習済みモデルは、学習用の部分画像と便の性状を判定した判定結果とを対応付けた学習データを用いて学習することにより作成されたモデルである。
In step S54, the determination device 10A performs determination processing for each of the entire image and the partial image.
The determination device 10A performs a global determination on the entire image, for example, a determination of the presence or absence of stool scattering. The determination device 10A estimates the presence or absence of stool scattering in the entire image using the trained model, and uses the estimated result as the determination result for determining the presence or absence of stool scattering in the entire image. The trained model here is a model created by learning using learning data in which the entire image for learning and the determination result of determining the presence or absence of stool scattering are associated with each other.
Further, the determination device 10A performs detailed determination on the partial image, for example, determination of the property of the stool. The determination device 10A estimates the stool properties in the partial image using the trained model, and uses the estimated result as the determination result for determining the stool properties in the partial image. The trained model here is a model created by learning using learning data in which a partial image for learning and a determination result of determining the properties of stool are associated with each other.

ステップS58において、判定装置10Aは、全体画像及び部分画像の双方に判定結果があるか否かを判定する。双方に判定結果があるとは、全体画像に便の飛散の有無が判定されており、且つ部分画像について便の性状が判定されていることを示す。 In step S58, the determination device 10A determines whether or not there is a determination result in both the entire image and the partial image. The fact that both have determination results means that the presence or absence of stool scattering is determined in the entire image, and the stool properties are determined in the partial image.

ステップS59において、判定装置10Aは、判定部13Aにより全体画像及び部分画像の双方に判定結果がある場合、全体画像の判定結果を用いて、部分画像の判定結果を補正する。部分画像の判定結果を補正するとは、全体画像の判定結果を用いて、部分画像の判定結果を変更又は補足することをいう。
例えば、判定部13Aは、部分画像の判定結果として、便の性状が軟便であった場合において、全体画像の判定結果から便の飛散有りと判定された場合、排便の状況を下痢傾向であると補正する。一方、判定部13Aは、全体画像の判定結果から便の飛散なしと判定された場合、部分画像の判定結果としての排便の状況を補正しない。
In step S59, when the determination unit 13A has a determination result in both the entire image and the partial image, the determination device 10A corrects the determination result of the partial image by using the determination result of the entire image. Correcting the determination result of the partial image means changing or supplementing the determination result of the partial image by using the determination result of the whole image.
For example, the determination unit 13A determines that the condition of defecation is diarrhea when it is determined that the stool is loose and the stool is scattered from the determination result of the whole image as the determination result of the partial image. to correct. On the other hand, the determination unit 13A does not correct the defecation status as the determination result of the partial image when it is determined from the determination result of the entire image that there is no scattering of stool.

ステップS60において、判定装置10Aは、判定部13Aにより確定処理を行う。確定処理は、全体画像の判定結果、及び部分の判定結果を用いて、使用者の排便の状況等を判定する処理である。 In step S60, the determination device 10A performs a determination process by the determination unit 13A. The confirmation process is a process of determining the defecation status of the user by using the determination result of the entire image and the determination result of the portion.

ステップS61において、判定装置10Aは、判定部13Aにより全体画像及び部分画像の双方に判定結果がない場合、部分画像の判定結果が有るか否かを判定する。部分画像の判定結果が有る場合、部分画像の判定結果を用いてステップS60に示す処理を行う。部分画像の判定結果がない場合、全体画像の判定結果を用いてステップS60に示す処理を行う。部分画像の判定結果がない場合とは、例えば、部分画像に排泄物が撮像されておらず、便の性状を判定することができなかった場合である。 In step S61, when the determination unit 13A has no determination result in both the whole image and the partial image, the determination device 10A determines whether or not there is a determination result of the partial image. When there is a determination result of the partial image, the process shown in step S60 is performed using the determination result of the partial image. If there is no determination result of the partial image, the process shown in step S60 is performed using the determination result of the entire image. The case where there is no determination result of the partial image is, for example, a case where the excrement is not imaged in the partial image and the property of the stool cannot be determined.

以上説明したように、第2の実施形態の変形例2に係る判定装置10Aでは、前処理部19が対象画像から全体画像と部分画像とを生成する。解析部12Aは、学習済みモデルを用いて全体画像から大局的な推定(第1推定)を行うと共に、別の学習済みモデルを用いて部分画像から詳細な推定(第2推定)を行う。これにより、第2の実施形態の変形例2に係る判定装置10Aでは、画素数の多い全体画像を用いて、比較的安易な大局的な推定を行うことで、全体画像から比較的難解な詳細な推定を行う場合よりも、演算処理の負荷を低減させ、装置コストの増大を抑制することができる。また、比較的画素数の少ない部分画像を用いて、詳細な推定を行うことで、比較的画素数の多い全体画像から詳細な推定を行う場合よりも、演算処理の負荷を低減させ、装置コストの増大を抑制することができる。 As described above, in the determination device 10A according to the second modification of the second embodiment, the preprocessing unit 19 generates a whole image and a partial image from the target image. The analysis unit 12A makes a global estimation (first estimation) from the whole image using the trained model, and makes a detailed estimation (second estimation) from the partial image using another trained model. As a result, in the determination device 10A according to the second modification of the second embodiment, the overall image having a large number of pixels is used to perform a relatively easy global estimation, so that the details are relatively difficult to understand from the overall image. It is possible to reduce the load of arithmetic processing and suppress an increase in device cost as compared with the case of performing a simple estimation. Further, by performing detailed estimation using a partial image having a relatively small number of pixels, the load of arithmetic processing can be reduced and the device cost can be reduced as compared with the case of performing detailed estimation from the entire image having a relatively large number of pixels. Can be suppressed from increasing.

また、第2の実施形態の変形例2に係る判定装置10Aでは、前処理部19は、対象画像における便鉢32の開口部36を少なくとも含む部分画像を生成する。これにより、第2の実施形態の変形例2に係る判定装置10Aでは、排泄物が落下する可能性が高い領域を部分画像として切り出すことができ、部分画像を用いて排泄物に係る詳細な判定を行うことが可能となる。 Further, in the determination device 10A according to the second modification of the second embodiment, the preprocessing unit 19 generates a partial image including at least the opening 36 of the toilet bowl 32 in the target image. As a result, in the determination device 10A according to the second modification of the second embodiment, the region where the excrement is likely to fall can be cut out as a partial image, and the detailed determination regarding the excrement is made using the partial image. It becomes possible to do.

また、第2の実施形態の変形例2に係る判定装置10Aでは、前処理部19は、大局的な推定(第1推定)として便の飛散の有無を推定し、詳細な推定(第2推定)として便の性状を推定する。これにより、第2の実施形態の変形例2に係る判定装置10Aでは、便の性状とともに飛散の有無を推定することができ、双方の推定結果を用いて、より精度よく判定を行うことが可能となる。 Further, in the determination device 10A according to the second modification of the second embodiment, the preprocessing unit 19 estimates the presence or absence of stool scattering as a global estimation (first estimation), and makes a detailed estimation (second estimation). ) To estimate the properties of the stool. As a result, the determination device 10A according to the second modification of the second embodiment can estimate the presence or absence of scattering together with the properties of the stool, and can make a more accurate determination using the estimation results of both. It becomes.

また、第2の実施形態の変形例2に係る判定装置10Aでは、大局的な推定(第1推定)についての推定結果を用いて、詳細な推定(第2推定)の推定結果を補正する。これにより、第2の実施形態の変形例2に係る判定装置10Aでは、詳細な推定を補正することができ、より精度よく判定を行うことが可能となる。 Further, in the determination device 10A according to the second modification of the second embodiment, the estimation result of the global estimation (first estimation) is used to correct the estimation result of the detailed estimation (second estimation). As a result, the determination device 10A according to the second modification of the second embodiment can correct the detailed estimation and can perform the determination more accurately.

(第3の実施形態)
次に、第3の実施形態について説明する。本実施形態では、対象画像における対象領域を抽出する点において、上述した実施形態と相違する。対象領域は、本実施形態における判定の対象となる領域であり、排泄物の性状を判定する対象となる領域である。すなわち、判定領域は、対象画像において排泄物が撮像されていると推定される領域である。以下の説明では、上述した実施形態と相違する構成のみ説明し、上述した実施形態と同等の構成については同じ符号を付してその説明を省略する。
(Third Embodiment)
Next, a third embodiment will be described. This embodiment differs from the above-described embodiment in that a target region in the target image is extracted. The target area is an area to be determined in the present embodiment, and is an area to be determined for the properties of excrement. That is, the determination region is a region where excrement is presumed to be imaged in the target image. In the following description, only configurations different from the above-described embodiment will be described, and the same reference numerals will be given to configurations equivalent to the above-described embodiments, and the description thereof will be omitted.

図15は、第3の実施形態に係る判定装置10Bの構成を示すブロック図である。判定装置10Bは、解析部12Bと、判定部13Bとを備える。ここで、解析部12Bは、「抽出部」の一例である。 FIG. 15 is a block diagram showing a configuration of the determination device 10B according to the third embodiment. The determination device 10B includes an analysis unit 12B and a determination unit 13B. Here, the analysis unit 12B is an example of the “extraction unit”.

解析部12Bは、対象画像における画像の色が、排泄物に想定される所定の色(以下、想定色という)との違い(色差)に基づいて、想定色と近い色の領域を判定領域として抽出する。解析部12Bは、対象画像における色が想定色と近い色であるか否かを、双方の色における色空間上の距離(以下、空間距離という)に基づいて決定する。二つの色の空間距離が小さい場合、色差が小さいことを示しており、当該二つの色が互いに近い色であることを示している。一方、空間距離が大きい場合、色差が大きいことを示しており、当該二つの色が互いに遠い色であることを示している。ここで、空間距離は、「想定色の特性」の一例である。 The analysis unit 12B uses a region of a color close to the assumed color as a determination region based on the difference (color difference) between the color of the image in the target image and the predetermined color assumed for excrement (hereinafter referred to as the assumed color). Extract. The analysis unit 12B determines whether or not the color in the target image is close to the assumed color based on the distance in the color space of both colors (hereinafter, referred to as spatial distance). When the spatial distance between the two colors is small, it indicates that the color difference is small, indicating that the two colors are close to each other. On the other hand, when the spatial distance is large, it indicates that the color difference is large, and that the two colors are distant from each other. Here, the spatial distance is an example of "characteristics of assumed color".

ここで、解析部12Bが空間距離を算出する方法について説明する。以下では、対象画像がRGB画像であり、想定色がRGB値により示される色である場合を例示して説明するが、これに限定されることはない。対象画像がRGB画像以外の画像(例えば、Lab画像や、YCbCr画像)である場合や、想定色がRGB値以外の色(例えば、Lab値や、YCbCr値)で示される場合でも同様な方法で判定領域を抽出することが可能である。また、以下では、想定色が便の色である場合を例示して説明するが、これに限定されることはない。想定色は、排泄物に想定される色であればよく、例えば、尿の色であってもよい。 Here, a method in which the analysis unit 12B calculates the spatial distance will be described. Hereinafter, the case where the target image is an RGB image and the assumed color is a color indicated by an RGB value will be described as an example, but the present invention is not limited to this. The same method is used even when the target image is an image other than the RGB image (for example, a Lab image or a YCbCr image) or the assumed color is indicated by a color other than the RGB value (for example, a Lab value or a YCbCr value). It is possible to extract the determination area. Further, in the following, the case where the assumed color is the color of stool will be described as an example, but the present invention is not limited to this. The assumed color may be any color expected for excrement, and may be, for example, the color of urine.

解析部12Bは、空間距離として、例えば、色空間におけるユークリッド距離を算出する。解析部12Bは、以下の(1)式を用いて、ユークリッド距離を算出する。(1)式において、Z1はユークリッド距離、ΔRは対象画像における所定の画素Xと想定色YとのR値の差分、ΔGは画素Xと想定色YとのG値の差分、ΔBは画素Xと想定色YとのB値の差分である。対象画像における所定の画素XのRGB値は(red、green、blue)、想定色YのRGB値は(Rs、Gs、Bs)である。 The analysis unit 12B calculates, for example, the Euclidean distance in the color space as the spatial distance. The analysis unit 12B calculates the Euclidean distance using the following equation (1). In the equation (1), Z1 is the Euclidean distance, ΔR is the difference in R value between the predetermined pixel X and the assumed color Y in the target image, ΔG is the difference in G value between the pixel X and the assumed color Y, and ΔB is the pixel X. It is the difference between the B value and the assumed color Y. The RGB values of the predetermined pixels X in the target image are (red, green, blue), and the RGB values of the assumed color Y are (Rs, Gs, Bs).

Z1=(ΔR^2+ΔG^2+ΔB^2)^(1/2) …(1)
但し、
ΔR=red−Rs
ΔG=green−Gs
ΔB=blue−Bs
Z1 = (ΔR ^ 2 + ΔG ^ 2 + ΔB ^ 2) ^ (1/2)… (1)
However,
ΔR = red-Rs
ΔG = green-Gs
ΔB = blue-Bs

また、解析部12Bは、空間距離を算出する際に、重みづけを行ってもよい。重みづけは、色を構成する特定の要素の差異を強調するためのものであり、例えば、色を構成するR要素、G要素、及びB要素に互いに異なる係数(重み係数)を乗算することにより行う。重みづけを行うことにより、想定色との色差を要素に応じて強調させることができる。 Further, the analysis unit 12B may perform weighting when calculating the spatial distance. The weighting is for emphasizing the difference between specific elements that make up a color, for example, by multiplying the R, G, and B elements that make up a color by different coefficients (weighting coefficients). Do. By weighting, the color difference from the assumed color can be emphasized according to the element.

解析部12Bは、例えば、以下の(2)式を用いて、重みづけしたユークリッド距離を算出することができる。(2)式において、Z2は重みづけしたユークリッド距離、R_COEFはR要素の重み係数、G_COEFはG要素の係数、B_COEFはB要素の重み係数である。ΔRは画素Xと想定色YとのR値の差分、ΔGは画素Xと想定色YとのG値の差分、ΔBは画素Xと想定色YとのB値の差分である。対象画像における所定の画素XのRGB値は(red、green、blue)、想定色YのRGB値は(Rs、Gs、Bs)である。 The analysis unit 12B can calculate the weighted Euclidean distance by using, for example, the following equation (2). In the equation (2), Z2 is the weighted Euclidean distance, R_COEF is the weighting coefficient of the R element, G_COEF is the coefficient of the G element, and B_COEF is the weighting coefficient of the B element. ΔR is the difference in R value between the pixel X and the assumed color Y, ΔG is the difference in the G value between the pixel X and the assumed color Y, and ΔB is the difference in the B value between the pixel X and the assumed color Y. The RGB values of the predetermined pixels X in the target image are (red, green, blue), and the RGB values of the assumed color Y are (Rs, Gs, Bs).

Z2=(R_COEF×ΔR^2
+G_COEF×ΔG^2
+B_COEF×ΔB^2)^(1/2) …(2)
但し、
R_COEF>G_COEF>B_COEF
ΔR=red−Rs
ΔG=green−Gs
ΔB=blue−Bs
Z2 = (R_COEF × ΔR ^ 2
+ G_COEF × ΔG ^ 2
+ B_COEF × ΔB ^ 2) ^ (1/2)… (2)
However,
R_COEF>G_COEF> B_COEF
ΔR = red-Rs
ΔG = green-Gs
ΔB = blue-Bs

ここで、想定色Yとしての便の色の特性は、R要素がG要素よりも強く、G要素はB要素よりも強い傾向にある。このような色を構成する各要素の特徴に基づいて、解析部12Bは、R要素の重み係数を、G要素の重み係数より大きな値とする。つまり、(2)式において、係数R_COFE、係数G_COFE、及び係数B_COFEには、R_COEF>G_COEF>B_COEFの関係が成立する。 Here, as for the characteristics of the color of the stool as the assumed color Y, the R element tends to be stronger than the G element, and the G element tends to be stronger than the B element. Based on the characteristics of each element constituting such a color, the analysis unit 12B sets the weighting coefficient of the R element to a value larger than the weighting coefficient of the G element. That is, in the equation (2), the relationship of R_COEF> G_COEF> B_COEF is established for the coefficient R_COFE, the coefficient G_COFE, and the coefficient B_COFE.

ところで、使用者の着座の加減などの影響により、被写体(便鉢32の内部空間34)に照射する光の光量が変化することが考えられる。光量が変化した場合、同じような色の排泄物であっても、色の濃淡が異なるかのように撮像される場合がある。このような場合、同じ色にもかかわらず、空間距離が異なる距離として算出されてしまう。 By the way, it is conceivable that the amount of light irradiating the subject (internal space 34 of the toilet bowl 32) changes depending on the influence of the user's seating. When the amount of light changes, even excrement of the same color may be imaged as if the shade of the color is different. In such a case, the spatial distance is calculated as a different distance even though the colors are the same.

この対策として、解析部12Bは、空間距離として、色を構成する各要素の比率(以下、色比率という)のユークリッド距離を算出してもよい。色比率は、例えば、R値、G値、及びB値のうちの基準とする要素の値で、他の要素の値を除算することにより行う。色比率を用いることにより、色の濃淡に起因する差異を反映させないようにした空間距離を算出することが可能である。 As a countermeasure, the analysis unit 12B may calculate the Euclidean distance of the ratio of each element constituting the color (hereinafter referred to as the color ratio) as the spatial distance. The color ratio is determined by, for example, dividing the values of the other elements by the values of the reference element among the R value, the G value, and the B value. By using the color ratio, it is possible to calculate the spatial distance so as not to reflect the difference due to the shade of color.

色比率を導出する際に基準とする要素は、任意に決定されてよいが、例えば、その色の支配的な要素とすることが考えられる。例えば、便の色においては、R要素が支配的である。このため、本実施形態において色比率は、R値、G値、及びB値のそれぞれを、R値により除算することにより作成する。 The element to be used as a reference when deriving the color ratio may be arbitrarily determined, but for example, it can be considered to be the dominant element of the color. For example, in the color of stool, the R element is dominant. Therefore, in the present embodiment, the color ratio is created by dividing each of the R value, the G value, and the B value by the R value.

例えば、画素X(RGB値(red、green、blue))の色比率は、(red/red、green/red、blue/red)、つまり(1、green/red、blue/red)である。また、想定色Y(RGB値(Rs、Gs、Bs))の色比率は、(Rs/Rs、Gs/Rs、Bs/Rs)、つまり、(1、Gs/Rs、Bs/Rs)である。 For example, the color ratio of pixel X (RGB values (red, green, blue)) is (red / red, green / red, blue / red), that is, (1, green / red, blue / red). Further, the color ratio of the assumed color Y (RGB values (Rs, Gs, Bs)) is (Rs / Rs, Gs / Rs, Bs / Rs), that is, (1, Gs / Rs, Bs / Rs). ..

解析部12Bは、以下の(3)式を用いて、色比率のユークリッド距離を算出することができる。(3)式において、Z3は色比率のユークリッド距離、ΔRpは画素Xの色比率と想定色Yの色比率とのR要素の差分、ΔGpは画素Xの色比率と想定色Yの色比率とのG要素の差分、ΔBpは画素Xの色比率と想定色Yの色比率とのB要素の差分である。GR_RATEは想定色Yの色比率におけるG要素の比率、BR_RATEは想定色Yの色比率におけるB要素の比率である。対象画像における所定の画素XのRGB値は(red、green、blue)、想定色YのRGB値は(Rs、Gs、Bs)である。 The analysis unit 12B can calculate the Euclidean distance of the color ratio by using the following equation (3). In equation (3), Z3 is the Euclidean distance of the color ratio, ΔRp is the difference between the R elements between the color ratio of the pixel X and the color ratio of the assumed color Y, and ΔGp is the color ratio of the pixel X and the color ratio of the assumed color Y. The difference of the G element, ΔBp, is the difference of the B element between the color ratio of the pixel X and the color ratio of the assumed color Y. GR_RATE is the ratio of the G element in the color ratio of the assumed color Y, and BR_RATE is the ratio of the B element in the color ratio of the assumed color Y. The RGB values of the predetermined pixels X in the target image are (red, green, blue), and the RGB values of the assumed color Y are (Rs, Gs, Bs).

Z3=(ΔRp^2+ΔGp^2+ΔBp^2)^(1/2)
=(ΔGp^2+ΔBp^2)^(1/2) …(3)
但し、
ΔRp=red/red−Rs/Rs=0(ゼロ)
ΔGp=green/red−GR_RATE
ΔBp=blue/red−BR_RATE
GR_RATE=Gs/Rs
BR_RATE=Bs/Rs
1>GR_RATE>BR_RATE>0
Z3 = (ΔRp ^ 2 + ΔGp ^ 2 + ΔBp ^ 2) ^ (1/2)
= (ΔGp ^ 2 + ΔBp ^ 2) ^ (1/2)… (3)
However,
ΔRp = red / red-Rs / Rs = 0 (zero)
ΔGp = green / red-GR_RATE
ΔBp = blue / red-BR_RATE
GR_RATE = Gs / Rs
BR_RATE = Bs / Rs
1>GR_RATE>BR_RATE> 0

想定色Yとしての便の色の特性は、R要素がG要素よりも強く(Rs>Gs)、G要素はB要素よりも強い(Gs>Bs)傾向にある。比率GR_RATE、及び比率BR_RATEは、共に0(ゼロ)〜1までの間の値となる。また、比率GR_RATEより比率BR_RATEのほうが小さい値となる。つまり、(3)式において、比率GR_RATEと比率BR_RATEとに、1>GR_RATE>BR_RATE>0の関係が成立する。 The characteristic of the color of the stool as the assumed color Y tends to be that the R element is stronger than the G element (Rs> Gs) and the G element is stronger than the B element (Gs> Bs). The ratio GR_RATE and the ratio BR_RATE are both values between 0 (zero) and 1. Further, the ratio BR_RATE is smaller than the ratio GR_RATE. That is, in the equation (3), the relationship of 1> GR_RATE> BR_RATE> 0 is established between the ratio GR_RATE and the ratio BR_RATE.

また、解析部12Bは、色比率のユークリッド距離を算出する際に、色比率を構成する特定の要素に重みづけを行ってもよい。解析部12Bは、以下の(4)式を用いて、色比率の重みづけしたユークリッド距離を算出することができる。(4)式において、Z4は色比率の重みづけしたユークリッド距離である。ΔRpは画素Xと想定色YとのR値の差分、ΔGpは画素Xと想定色YとのG値の差分、ΔBpは画素Xと想定色YとのB値の差分である。GR_COEFは差分ΔGpの重み係数、BR_COEFは差分のΔBpの重み係数である。対象画像における所定の画素XのRGB値は(red、green、blue)、想定色YのRGB値は(Rs、Gs、Bs)である。 Further, the analysis unit 12B may weight a specific element constituting the color ratio when calculating the Euclidean distance of the color ratio. The analysis unit 12B can calculate the weighted Euclidean distance of the color ratio by using the following equation (4). In equation (4), Z4 is the Euclidean distance weighted by the color ratio. ΔRp is the difference between the R values of the pixel X and the assumed color Y, ΔGp is the difference between the G values of the pixel X and the assumed color Y, and ΔBp is the difference between the B values of the pixel X and the assumed color Y. GR_COEF is a weighting coefficient of the difference ΔGp, and BR_COEF is a weighting coefficient of the difference ΔBp. The RGB values of the predetermined pixels X in the target image are (red, green, blue), and the RGB values of the assumed color Y are (Rs, Gs, Bs).

Z4=(GR_COEF×ΔGp^2
+BR_COEF×ΔBp^2)^(1/2) …(4)
但し、
GP_COEF>BP_COEF
ΔGp=green/red−GR_RATE
ΔBp=blue/red−BR_RATE
GR_RATE=Gs/Rs
BR_RATE=Bs/Rs
1>GR_RATE>BR_RATE>0
Z4 = (GR_COEF × ΔGp ^ 2
+ BR_COEF × ΔBp ^ 2) ^ (1/2)… (4)
However,
GP_COEF> BP_COEF
ΔGp = green / red-GR_RATE
ΔBp = blue / red-BR_RATE
GR_RATE = Gs / Rs
BR_RATE = Bs / Rs
1>GR_RATE>BR_RATE> 0

(4)式において、(2)式における係数G_COFE、及び係数B_COFEの関係と同様に、係数GR_COFE、及び係数BR_COFEには、GP_COEF>BP_COEFの関係が成立する。また、(4)式において、(3)式と同様に、比率GR_RATEと比率BR_RATEとに、1>GR_RATE>BR_RATE>0の関係が成立する。例えば、比率GR_RATE=0.7、比率BR_RATE=0.3、係数GR_COFE=40、係数BR_COFE=1に設定される。 In the equation (4), the relationship of GP_COEF> BP_COEF is established for the coefficients GR_COFE and the coefficient BR_COFE in the same manner as the relationship of the coefficient G_COFE and the coefficient B_COFE in the equation (2). Further, in the equation (4), the relationship of 1> GR_RATE> BR_RATE> 0 is established between the ratio GR_RATE and the ratio BR_RATE, as in the equation (3). For example, the ratio GR_RATE = 0.7, the ratio BR_RATE = 0.3, the coefficient GR_COFE = 40, and the coefficient BR_COFE = 1 are set.

解析部12Bは、対象画像の画素ごとに算出した空間距離を、グレースケールとした画像(グレースケール対象画像)を作成する。例えば、解析部12Bは、(5)式を用いて、空間距離のスケールを調整し、グレースケール値に換算する。(5)式において、Valはグレースケール値、AMPはスケール調整用の係数、Zは空間距離である。空間距離Zは、RGB値のユークリッド距離Z1、RGB値の重みづけユークリッド距離Z2、色比率のユークリッド距離Z3、色比率の重みづけユークリッド距離Z4の何れであってもよい。また、Z_MAXは、対象画像の画素ごとに算出された空間距離の最大値、Val_MAXは、グレースケール値の最大値である。 The analysis unit 12B creates an image (grayscale target image) in which the spatial distance calculated for each pixel of the target image is grayscale. For example, the analysis unit 12B adjusts the scale of the spatial distance by using the equation (5) and converts it into a gray scale value. In equation (5), Val is a grayscale value, AMP is a coefficient for scale adjustment, and Z is a spatial distance. The spatial distance Z may be any of RGB value Euclidean distance Z1, RGB value weighted Euclidean distance Z2, color ratio Euclidean distance Z3, and color ratio weighted Euclidean distance Z4. Further, Z_MAX is the maximum value of the spatial distance calculated for each pixel of the target image, and Val_MAX is the maximum value of the gray scale value.

Val=AMP×Z …(5)
但し、
AMP=Val_MAX/Z_MAX
Val = AMP × Z… (5)
However,
AMP = Val_MAX / Z_MAX

例えば、グレースケール対象画像においてグレースケールの階調を0〜255の256段階で示す場合、グレースケール値の最大値Val_MAXは255である。この場合、(5)式により空間距離の最大値X_MAXが、グレースケールの最大値Val_MAX(255)となるように、空間距離Zがグレースケール値Valに変換される。これにより、解析部12Bは、想定色との空間距離を、0(白色)〜255(黒色)のグレースケール値により表現したグレースケール対象画像を作成する。 For example, when the grayscale gradation is shown in 256 steps from 0 to 255 in the grayscale target image, the maximum value Val_MAX of the grayscale value is 255. In this case, the spatial distance Z is converted to the grayscale value Val so that the maximum value X_MAX of the spatial distance becomes the maximum value Val_MAX (255) of the grayscale according to the equation (5). As a result, the analysis unit 12B creates a grayscale target image in which the spatial distance from the assumed color is expressed by a grayscale value of 0 (white) to 255 (black).

ここで、解析部12Bが判定領域を抽出する方法について、図16を用いて説明する。図16は、第3の実施形態に係る解析部12Bが行う処理を説明する図である。図16では、左右方向にグレースケール軸を示しており、グレースケール軸が左から右へ向かうにしたがって、グレースケール値が増加することを示している。 Here, a method in which the analysis unit 12B extracts the determination region will be described with reference to FIG. FIG. 16 is a diagram illustrating a process performed by the analysis unit 12B according to the third embodiment. In FIG. 16, the grayscale axis is shown in the left-right direction, and it is shown that the grayscale value increases as the grayscale axis moves from left to right.

図16に示すように、グレースケール対象画像において、空間距離が小さい画素が小さいグレースケール値で表現される。つまり、想定色としての便の色により近い色が小さいグレースケール値で表現され、グレースケール値が小さい領域を、便が撮像された領域とみなすことができる。一方、グレースケール対象画像において、空間距離が大きい画素が大きいグレースケール値で表現される。つまり、想定色としての便の色とは離れた色が大きいグレースケール値で表現され、グレースケール値が大きい領域を、便が撮像されていない「非便」の領域とみなすことができる。 As shown in FIG. 16, in a grayscale target image, pixels having a small spatial distance are represented by a small grayscale value. That is, a color closer to the color of the stool as the assumed color is represented by a small gray scale value, and a region having a small gray scale value can be regarded as a region in which the stool is imaged. On the other hand, in the grayscale target image, pixels having a large spatial distance are represented by a large grayscale value. That is, a color distant from the color of the stool as the assumed color is expressed by a large gray scale value, and a region having a large gray scale value can be regarded as a “non-stool” region in which the stool is not imaged.

この性質を利用して、解析部12Bは、判定領域を抽出する。具体的に、解析部12Bは、グレースケール対象画像における画素のグレースケール値が、所定の第1閾値(閾値1)未満である領域を排泄物がある領域とし、判定領域として当該排泄物がある領域を抽出する。第1閾値は、便鉢32に溜められた洗浄水Sの色と、水様便の色とを区別する境界に相当するグレースケール値である。 Utilizing this property, the analysis unit 12B extracts a determination region. Specifically, the analysis unit 12B sets a region in which the grayscale value of the pixel in the grayscale target image is less than a predetermined first threshold value (threshold value 1) as a region containing excrement, and has the excrement as a determination region. Extract the area. The first threshold value is a grayscale value corresponding to a boundary that distinguishes the color of the washing water S stored in the toilet bowl 32 from the color of the watery stool.

また、硬便と水様便との色を比較した場合、水様便は水(洗浄水S)に溶けているため、硬便より薄くなることが考えられる。この場合、水様便の色に対応するグレースケール値は、硬便に対応するグレースケール値よりも、想定色としての便の色から離れていることを示す濃い灰色で表現される。 Further, when comparing the colors of hard stool and watery stool, it is considered that the watery stool is thinner than the hard stool because it is dissolved in water (washing water S). In this case, the grayscale value corresponding to the color of watery stool is expressed in dark gray indicating that the color of the stool is farther from the assumed color than the grayscale value corresponding to hard stool.

この性質を利用して、解析部12Bは、判定領域から、水様便の領域と硬便の領域とを区別して抽出する。具体的に、解析部12Bは、グレースケール対象画像における判定領域のうち、グレースケール値が所定の第2閾値(閾値2)未満である領域を硬便の領域、第2閾値以上である領域を水溶便の領域とする。第2閾値は、第1閾値よりも小さい値に設定される。ここで、水溶便の領域は「判定領域」の一例である。また、硬便の領域は「判定領域」の一例である。 Utilizing this property, the analysis unit 12B extracts the watery stool region and the hard stool region separately from the determination region. Specifically, the analysis unit 12B sets the region where the grayscale value is less than a predetermined second threshold value (threshold value 2) as the hard stool region and the region where the grayscale value is equal to or higher than the second threshold value among the determination regions in the grayscale target image. Area of water-soluble stool. The second threshold value is set to a value smaller than the first threshold value. Here, the region of water-soluble stool is an example of a "determination region". The hard stool area is an example of a "judgment area".

或いは、解析部12Bは、判定領域に水様便の領域と硬便の領域とが混在している場合に、二つの領域(水様便の領域と硬便の領域)を区別して抽出するようにしてもよい。判定領域に二つ領域が混在している場合、判定領域に含まれる画素が取り得るグレースケールの範囲は、水溶便が取り得るグレースケールの範囲と硬便がとり得るグレースケールの範囲とを併せた範囲となるため、比較的広い範囲となる。一方、判定領域に一つの領域(水様便の領域、又は硬便の領域)のみが存在している場合、判定領域に含まれる画素がとり得るグレースケールの範囲は、比較的狭い範囲となる。 Alternatively, when the determination region contains a watery stool region and a hard stool region, the analysis unit 12B distinguishes and extracts the two regions (watery stool region and hard stool region). It may be. When two areas are mixed in the judgment area, the grayscale range that the pixels included in the judgment area can take is the combination of the grayscale range that water-soluble stool can take and the grayscale range that hard stool can take. Because it is a wide range, it is a relatively wide range. On the other hand, when only one region (watery stool region or hard stool region) exists in the determination region, the grayscale range that the pixels included in the determination region can take is a relatively narrow range. ..

この性質を利用して、解析部12Bは、判定領域に含まれる画素におけるグレースケールの範囲に応じて、判定領域に水様便の領域と硬便の領域とが混在しているか否かを判定する。解析部12Bは、例えば、判定領域に含まれる画素におけるグレースケールの最大値と最小値との差分を、グレースケールの範囲とする。解析部12Bは、判定領域におけるグレースケールの範囲が、所定の差分閾値未満である場合、判定領域に水様便の領域と硬便の領域とが混在していない(つまり、判定領域は、水様便の領域、又は硬便の領域のみである)と判定する。解析部12Bは、判定領域におけるグレースケールの範囲が、所定の差分閾値以上である場合、判定領域に水様便の領域と硬便の領域とが混在している。差分閾値は、水溶便が取り得るグレースケールの範囲と硬便がとり得るグレースケールの範囲とに応じて、例えば、何れか広い範囲、何れか狭い範囲、或いは二つの範囲の代表値に対応させた値に設定される。代表値は、二つの範囲の単純加算平均値、重みづけ平均値、中央値等、一般的に用いられる代表値の何れであってもよい。 Utilizing this property, the analysis unit 12B determines whether or not the region of watery stool and the region of hard stool are mixed in the determination region according to the grayscale range of the pixels included in the determination region. To do. For example, the analysis unit 12B sets the difference between the maximum value and the minimum value of the gray scale in the pixels included in the determination region as the range of the gray scale. When the grayscale range in the determination region is less than a predetermined difference threshold value, the analysis unit 12B does not mix the watery stool region and the hard stool region in the determination region (that is, the determination region is water. (Only the area of grayscale or the area of hard stool). When the grayscale range in the determination region is equal to or greater than a predetermined difference threshold value, the analysis unit 12B includes a watery stool region and a hard stool region in the determination region. The difference threshold corresponds to, for example, a wide range, a narrow range, or a representative value of two ranges, depending on the gray scale range that water-soluble stool can take and the gray scale range that hard stool can take. Is set to the value. The representative value may be any of commonly used representative values such as a simple addition mean value, a weighted mean value, and a median value in two ranges.

解析部12Bは、抽出した判定領域を示す画像(抽出画像)の情報を、判定部13Bに出力する。この場合、解析部12Bは、判定領域に水様便の領域と硬便の領域とが混在している場合、判定領域において水様便の領域を示す画像(水様部抽出画像)と、判定領域において硬便の領域を示す画像(硬部抽出画像)の情報を、判定部13Bに出力する。一方、解析部12Bは、判定領域に水様便の領域と硬便の領域とが混在していない場合、判定領域として水様便の領域を示す画像(水様便抽出画像)、又は判定領域として硬便の領域を示す画像(硬便抽出画像)の情報を、判定部13Bに出力する。 The analysis unit 12B outputs the information of the image (extracted image) indicating the extracted determination region to the determination unit 13B. In this case, when the determination region contains a watery stool region and a hard stool region, the analysis unit 12B determines that the determination region is an image showing the watery stool region (water-like region extracted image). The information of the image (hard part extraction image) showing the hard stool area in the area is output to the determination unit 13B. On the other hand, when the determination region does not include the watery stool region and the hard stool region, the analysis unit 12B has an image showing the watery stool region as the determination region (watery stool extraction image) or the determination region. The information of the image showing the region of hard stool (hard stool extraction image) is output to the determination unit 13B.

図15に戻り、判定部13Bは、解析部12Bにより取得した抽出画像に基づいて、判定事項に関する判定を行う。具体的に、判定部13Bは、水様便抽出画像を用いて、水様便の性状を判定する。判定部13Bは、硬便抽出画像を用いて、硬便の性状を判定する。判定部13Bは、水様部抽出画像を用いて、水様便の性状を判定する。判定部13Bは、硬部抽出画像を用いて、硬便の性状を判定する。 Returning to FIG. 15, the determination unit 13B determines the determination items based on the extracted image acquired by the analysis unit 12B. Specifically, the determination unit 13B determines the properties of the watery stool using the watery stool extract image. The determination unit 13B determines the properties of hard stool using the hard stool extract image. The determination unit 13B determines the properties of watery stool using the image extracted from the watery part. The determination unit 13B determines the properties of hard stool using the hard part extracted image.

判定部13Bは、上述した他の実施形態と同様に、機械学習による推定結果を用いて便の性状を判定してもよい。この場合、解析部12Bが、機械学習による推定を行なうようにしてもよいし、他の機能部が推定するようにしてもよい。また、判定部13Bは、他の画像解析の手法を用いて便の性状を判定してもよい。この場合、判定装置10Bは、学習済みモデル記憶部16を省略することができる。 The determination unit 13B may determine the properties of the stool using the estimation result by machine learning, as in the other embodiments described above. In this case, the analysis unit 12B may perform the estimation by machine learning, or another functional unit may perform the estimation. In addition, the determination unit 13B may determine the properties of the stool by using another image analysis method. In this case, the determination device 10B can omit the learned model storage unit 16.

判定部13Bは、解析部12Bにより判定領域が抽出され、範囲が絞り込まれた画像を解析の対象とすることができるため、対象画像の全体を解析する必要がない。また、判定部13Bは、水様便か硬便かが区別された画像を解析の対象とすることができるため、水様便か硬便かが区別されていない画像を解析の対象とする場合と比較して、性状を判定する処理が容易となる。 The determination unit 13B does not need to analyze the entire target image because the determination area is extracted by the analysis unit 12B and the image whose range is narrowed down can be the target of analysis. Further, since the determination unit 13B can analyze an image in which watery stool or hard stool is distinguished, a case where an image in which watery stool or hard stool is not distinguished is targeted for analysis. Compared with, the process of determining the properties becomes easier.

ここで、第3の実施形態の判定装置10Bが行う処理について、図17を用いて説明する。図17は、第3の実施形態に係る判定装置10Bが行う処理の流れを示すフローチャートである。本フローチャートでは、画像情報を取得する処理が行われた以降の処理の流れを示している。画像情報を取得する処理は、図4に示すフローチャートのステップS11に対応する処理であり、本フローチャートでは「カメラ画像」と記載している処理に相当する。 Here, the process performed by the determination device 10B of the third embodiment will be described with reference to FIG. FIG. 17 is a flowchart showing a flow of processing performed by the determination device 10B according to the third embodiment. This flowchart shows the flow of processing after the processing for acquiring image information is performed. The process of acquiring image information is a process corresponding to step S11 of the flowchart shown in FIG. 4, and corresponds to the process described as “camera image” in this flowchart.

解析部12Bは、対象画像をグレースケール化して、グレースケール対象画像を作成する(ステップS70)。
解析部12Bは、グレースケール対象画像における画素ごとのグレースケール値が第1閾値(閾値1)未満であるか否かを判定する(ステップS71)。
解析部12Bは、グレースケール対象画像において、グレースケール値が第1閾値(閾値1)未満である判定領域の画素群について、グレースケール値の最大値と最小値との差分Dを計算する(ステップS72)。
The analysis unit 12B grayscales the target image to create a grayscale target image (step S70).
The analysis unit 12B determines whether or not the grayscale value for each pixel in the grayscale target image is less than the first threshold value (threshold value 1) (step S71).
The analysis unit 12B calculates the difference D between the maximum value and the minimum value of the gray scale value for the pixel group in the determination region where the gray scale value is less than the first threshold value (threshold value 1) in the gray scale target image (step). S72).

解析部12Bは、差分Dが所定の差分閾値a未満であるか否かを判定し(ステップS73)、差分Dが所定の差分閾値a未満である場合、判定領域に水様便の領域と硬便の領域とが混在していないと判定し、ステップS74に示す処理に進む。ステップS74において、解析部12Bは、判定領域における画素ごとのグレースケール値が第2閾値(閾値2)未満であるか否かを判定する。
解析部12Bは、判定領域における画素ごとのグレースケール値が第2閾値(閾値2)未満である場合、硬便抽出画像を判定部13Bに出力する(ステップS75)。判定部13Bは、硬便抽出画像に基づいて、硬便だけの(硬便に特化した)便の性状を判定する(ステップS82)。
解析部12Bは、判定領域における画素ごとのグレースケール値が第2閾値(閾値2)以上である場合、水様便抽出画像を判定部13Bに出力する(ステップS76)。判定部13Bは、水様便抽出画像に基づいて、水様便だけの(水様便に特化した)便の性状を判定する(ステップS83)。
The analysis unit 12B determines whether or not the difference D is less than the predetermined difference threshold value a (step S73), and if the difference D is less than the predetermined difference threshold value a, the determination region includes the region of watery stool and the hardness. It is determined that the stool area is not mixed, and the process proceeds to the process shown in step S74. In step S74, the analysis unit 12B determines whether or not the grayscale value for each pixel in the determination region is less than the second threshold value (threshold value 2).
When the grayscale value for each pixel in the determination region is less than the second threshold value (threshold value 2), the analysis unit 12B outputs the hard stool extraction image to the determination unit 13B (step S75). The determination unit 13B determines the properties of stools containing only hard stools (specializing in hard stools) based on the hard stool extract image (step S82).
When the grayscale value for each pixel in the determination region is equal to or greater than the second threshold value (threshold value 2), the analysis unit 12B outputs the watery stool extract image to the determination unit 13B (step S76). The determination unit 13B determines the properties of stools containing only watery stools (specializing in watery stools) based on the extracted image of watery stools (step S83).

一方、解析部12Bは、差分Dが所定の差分閾値a以上である場合(ステップS73、NO)、判定領域に水様便の領域と硬便の領域とが混在していると判定する(ステップS77)。解析部12Bは、判定領域における画素ごとのグレースケール値が第2閾値(閾値2)未満であるか否かを判定する(ステップS78)。
解析部12Bは、判定領域における画素ごとのグレースケール値が第2閾値(閾値2)未満である場合、その領域を硬部画像として判定部13Bに出力する(ステップS79)。判定部13Bは、硬部抽出画像に基づいて、硬部(混在した状態における硬便の領域)の便の性状を判定する(ステップS84)。
解析部12Bは、判定領域における画素ごとのグレースケール値が第2閾値(閾値2)以上である場合、その領域を水様部抽出画像として判定部13Bに出力する(ステップS76)。判定部13Bは、水様部抽出画像に基づいて、水様部(混在した状態における水様便の領域)の便の性状を判定する(ステップS85)。
On the other hand, when the difference D is equal to or greater than the predetermined difference threshold value a (step S73, NO), the analysis unit 12B determines that the watery stool region and the hard stool region are mixed in the determination region (step). S77). The analysis unit 12B determines whether or not the grayscale value for each pixel in the determination region is less than the second threshold value (threshold value 2) (step S78).
When the grayscale value for each pixel in the determination region is less than the second threshold value (threshold value 2), the analysis unit 12B outputs the region as a hard portion image to the determination unit 13B (step S79). The determination unit 13B determines the stool properties of the hard portion (the region of the hard stool in the mixed state) based on the hard portion extracted image (step S84).
When the grayscale value for each pixel in the determination region is equal to or greater than the second threshold value (threshold value 2), the analysis unit 12B outputs the region as a watery portion extracted image to the determination unit 13B (step S76). The determination unit 13B determines the stool properties of the watery portion (region of the watery stool in a mixed state) based on the image extracted from the watery portion (step S85).

判定部13Bは、ステップS82〜S85による便の性状を判定した結果を用いて、対象画像における便の性状を総合的に判定する(ステップS86)。 The determination unit 13B comprehensively determines the stool properties in the target image by using the results of determining the stool properties in steps S82 to S85 (step S86).

なお、ステップS71において、グレースケール対象画像における画素ごとのグレースケール値が第1閾値(閾値1)以上である画素群について、便以外の画像であると判定し判定領域から除外する(ステップS81)。 In step S71, the pixel group in which the grayscale value for each pixel in the grayscale target image is equal to or higher than the first threshold value (threshold value 1) is determined to be an image other than stool and excluded from the determination area (step S81). ..

以上説明したように、第3の実施形態の判定装置10Bでは、解析部12Bが、想定色Yの色の特性に基づいて、対象画像から判定領域を抽出する。これにより、第3の実施形態の判定装置10Bでは、対象画像から排泄物がある領域を抽出することができる。便の性状を判定する領域を絞り込むことができるので、対象画像の全体を解析対象とする場合と比較して、判定に要する処理負荷を低減させることが可能である。処理負荷を低減させることにより、高い演算能力を有しない装置でも処理を行うことが可能となるために、装置コストの増大を抑制することができる。また、判定の対象となる排泄物の想定色Yの色の特性に基づいて判定領域を抽出することができるために、想定色Yの色に無関係に抽出された領域と比較して判定領域における判定が容易となる。 As described above, in the determination device 10B of the third embodiment, the analysis unit 12B extracts the determination region from the target image based on the color characteristics of the assumed color Y. As a result, the determination device 10B of the third embodiment can extract a region containing excrement from the target image. Since the area for determining the properties of the stool can be narrowed down, it is possible to reduce the processing load required for the determination as compared with the case where the entire target image is analyzed. By reducing the processing load, it is possible to perform processing even in an apparatus that does not have high computing power, so that an increase in apparatus cost can be suppressed. Further, since the determination region can be extracted based on the color characteristics of the assumed color Y of the excrement to be determined, the determination region is compared with the region extracted regardless of the color of the assumed color Y. Judgment becomes easy.

また、第3の実施形態の判定装置10Bでは、解析部12Bは、対象画像における画素ごとの色について、想定色Yとの色空間上における空間距離Zを算出し、算出した空間距離Zが所定の閾値未満である画素の集合を、判定領域として抽出する。これにより、第3の実施形態の判定装置10Bでは、空間距離Zにより想定色Yとの色の違い(色差)を算出して想定色Yとの色差が少ない領域を判定することができ、定量的な指標に基づいて判定領域を抽出することが可能となる。 Further, in the determination device 10B of the third embodiment, the analysis unit 12B calculates the spatial distance Z in the color space with the assumed color Y for each pixel color in the target image, and the calculated spatial distance Z is predetermined. A set of pixels that is less than the threshold value of is extracted as a determination region. As a result, in the determination device 10B of the third embodiment, the color difference (color difference) from the assumed color Y can be calculated from the space distance Z, and the region where the color difference from the assumed color Y is small can be determined, which is quantitative. It is possible to extract a determination area based on a specific index.

また、第3の実施形態の判定装置10Bでは、解析部12Bは、対象画像における画素ごとの色について、想定色Yとの色の要素ごとの差分に重みづけをした値を用いて、色空間上における空間距離を算出する。これにより、第3の実施形態の判定装置10Bでは、想定色Yとの違いが表れやすい要素(例えば、R要素)を強調させた空間距離を算出することが可能である。これにより、精度よく判定領域を抽出することが可能となる。 Further, in the determination device 10B of the third embodiment, the analysis unit 12B uses a value obtained by weighting the difference between the color of each pixel in the target image and the assumed color Y for each color element in the color space. Calculate the space distance above. Thereby, in the determination device 10B of the third embodiment, it is possible to calculate the spatial distance in which the element (for example, R element) in which the difference from the assumed color Y is likely to appear is emphasized. This makes it possible to extract the determination region with high accuracy.

また、第3の実施形態の判定装置10Bでは、対象画像はRGB画像であり、想定色はRGB値で示される色であり、解析部12Bは、対象画像における画素ごとのR値、G値、B値の比率を示す色比率と、想定色Yにおける色比率との、R要素における比率の差分、G要素における比率の差分、及びB要素における比率の差分に重みづけをした値を用いて、色空間上における空間距離を算出する。これにより、第3の実施形態の判定装置10Bでは、被写体に照射する光の光量の相違による、色の濃淡の違いに影響されずに空間距離を算出することが可能である。これにより、精度よく判定領域を抽出することが可能となる。 Further, in the determination device 10B of the third embodiment, the target image is an RGB image, the assumed color is a color indicated by an RGB value, and the analysis unit 12B has an R value, a G value, and a G value for each pixel in the target image. Using a weighted value of the difference in the ratio in the R element, the difference in the ratio in the G element, and the difference in the ratio in the B element between the color ratio indicating the ratio of the B value and the color ratio in the assumed color Y, Calculate the spatial distance on the color space. As a result, in the determination device 10B of the third embodiment, it is possible to calculate the spatial distance without being affected by the difference in the shade of color due to the difference in the amount of light irradiating the subject. This makes it possible to extract the determination region with high accuracy.

また、第3の実施形態の判定装置10Bでは、解析部12Bは、グレースケール対象画像を作成し、当該グレースケール対象画像における画素のグレースケール値が所定の第1閾値(閾値1)未満である領域を排泄物がある領域とし、判定領域として当該排泄物がある領域を抽出する。これにより、第3の実施形態の判定装置10Bでは、グレースケール対象画像における画素ごとのグレースケール値を閾値と比較するという容易な方法により判定領域を抽出することが可能となる。 Further, in the determination device 10B of the third embodiment, the analysis unit 12B creates a grayscale target image, and the grayscale value of the pixels in the grayscale target image is less than a predetermined first threshold value (threshold value 1). The area is defined as the area where the excrement is present, and the area where the excrement is present is extracted as the determination area. As a result, in the determination device 10B of the third embodiment, the determination region can be extracted by an easy method of comparing the grayscale value for each pixel in the grayscale target image with the threshold value.

また、第3の実施形態の判定装置10Bでは、解析部12Bは、グレースケール対象画像における画素のグレースケール値が前記第1閾値未満、且つ前記第1閾値より小さい所定の第2閾値以上である領域を水様便が示された領域とし、前記グレースケール対象画像における画素のグレースケール値が前記第2閾値未満である領域を硬便が示された領域とし、前記判定領域として、当該水様便が示された領域及び当該硬便が示された領域を抽出する。これにより、第3の実施形態の判定装置10Bでは、グレースケール対象画像における画素ごとのグレースケール値を閾値と比較するという容易な方法により、水様便が示された領域と、硬便が示された領域とを区別して判定領域を抽出することができ、より精度よく判定領域を抽出することが可能となる。また、水様便が示された領域と硬便が示された領域とを区別して判定領域を抽出することにより、区別されない場合と比較して、判定部13Bによる判定の処理負荷を低減させることが可能である。 Further, in the determination device 10B of the third embodiment, in the analysis unit 12B, the grayscale value of the pixels in the grayscale target image is less than the first threshold value and equal to or more than a predetermined second threshold value smaller than the first threshold value. The region is defined as the region where watery stool is shown, the region where the grayscale value of the pixels in the grayscale target image is less than the second threshold value is defined as the region where hard stool is shown, and the determination region is the watery stool. The area where stool is shown and the area where the hard stool is shown are extracted. As a result, in the determination device 10B of the third embodiment, the region where watery stool is shown and the hard stool are shown by an easy method of comparing the grayscale value for each pixel in the grayscale target image with the threshold value. The determination area can be extracted separately from the determined area, and the determination area can be extracted more accurately. Further, by extracting the determination region by distinguishing the region showing watery stool and the region showing hard stool, the processing load of the determination by the determination unit 13B can be reduced as compared with the case where the determination region is not distinguished. Is possible.

なお、上記では、解析部12Bが一つのグレースケール対象画像を用いて判定領域を抽出する場合を例示して説明したが、これに限定されることはない。解析部12Bは、複数の異なるグレースケール対象画像を用いて判定領域を抽出してもよい。例えば、解析部12Bは、色比率の重みづけしたユークリッド距離Z4をグレースケールに変換したグレースケール対象画像を用いて、第1閾値による判定領域を抽出する処理のみを行うようにしてもよい。そして、解析部12Bは、ユークリッド距離Z1をグレースケールに変換したグレースケール対象画像を用いて、第2閾値による水様便と硬便との領域を区別して抽出する処理のみを行うようにしてもよい。 In the above description, the case where the analysis unit 12B extracts the determination region using one grayscale target image has been described as an example, but the present invention is not limited to this. The analysis unit 12B may extract a determination region using a plurality of different grayscale target images. For example, the analysis unit 12B may only perform the process of extracting the determination region according to the first threshold value by using the grayscale target image obtained by converting the Euclidean distance Z4 weighted by the color ratio into grayscale. Then, the analysis unit 12B may only perform the process of distinguishing and extracting the regions of watery stool and hard stool according to the second threshold value using the grayscale target image obtained by converting the Euclidean distance Z1 into grayscale. Good.

また、上記では複数の実施形態について説明したが、各実施形態における構成は、当該実施形態の構成のみに限定されることはなく、他の実施形態の構成として用いられてもよい。例えば、第1の実施形態において便の性状を判定する処理に、第2の実施形態及びその変形例に係る差分画像、分割画像、或いは全体画像と部分画像とが用いられてもよい。また、第2の実施形態及びその変形例に係る差分画像等に、第3の実施形態おけるグレースケール対象画像が用いられてもよい。また、第3の実施形態の便の性状を判定する処理に第2の実施形態及びその変形例に係る差分画像、分割画像、或いは全体画像と部分画像とが用いられてもよい。 Further, although a plurality of embodiments have been described above, the configuration in each embodiment is not limited to the configuration of the embodiment, and may be used as the configuration of another embodiment. For example, in the process of determining the properties of stool in the first embodiment, a difference image, a divided image, or a whole image and a partial image according to the second embodiment and its modified examples may be used. Further, the grayscale target image in the third embodiment may be used for the difference image or the like according to the second embodiment and the modified example thereof. Further, the difference image, the divided image, or the whole image and the partial image according to the second embodiment and the modified example thereof may be used for the process of determining the property of the stool of the third embodiment.

上述した実施形態における判定装置10(10A、10B)が行う処理の全部または一部をコンピュータで実現するようにしてもよい。その場合、この機能を実現するためのプログラムをコンピュータ読み取り可能な記録媒体に記録して、この記録媒体に記録されたプログラムをコンピュータシステムに読み込ませ、実行することによって実現してもよい。なお、ここでいう「コンピュータシステム」とは、OSや周辺機器等のハードウェアを含むものとする。また、「コンピュータ読み取り可能な記録媒体」とは、フレキシブルディスク、光磁気ディスク、ROM、CD−ROM等の可搬媒体、コンピュータシステムに内蔵されるハードディスク等の記憶装置のことをいう。さらに「コンピュータ読み取り可能な記録媒体」とは、インターネット等のネットワークや電話回線等の通信回線を介してプログラムを送信する場合の通信線のように、短時間の間、動的にプログラムを保持するもの、その場合のサーバやクライアントとなるコンピュータシステム内部の揮発性メモリのように、一定時間プログラムを保持しているものも含んでもよい。また上記プログラムは、前述した機能の一部を実現するためのものであってもよく、さらに前述した機能をコンピュータシステムにすでに記録されているプログラムとの組み合わせで実現できるものであってもよく、FPGA等のプログラマブルロジックデバイスを用いて実現されるものであってもよい。 All or part of the processing performed by the determination device 10 (10A, 10B) in the above-described embodiment may be realized by a computer. In that case, the program for realizing this function may be recorded on a computer-readable recording medium, and the program recorded on the recording medium may be read by the computer system and executed. The term "computer system" as used herein includes hardware such as an OS and peripheral devices. Further, the "computer-readable recording medium" refers to a portable medium such as a flexible disk, a magneto-optical disk, a ROM, or a CD-ROM, or a storage device such as a hard disk built in a computer system. Further, a "computer-readable recording medium" is a communication line for transmitting a program via a network such as the Internet or a communication line such as a telephone line, and dynamically holds the program for a short period of time. It may also include a program that holds a program for a certain period of time, such as a volatile memory inside a computer system that serves as a server or a client in that case. Further, the above program may be for realizing a part of the above-mentioned functions, and may be further realized for realizing the above-mentioned functions in combination with a program already recorded in the computer system. It may be realized by using a programmable logic device such as FPGA.

以上、この発明の実施形態について図面を参照して詳述してきたが、具体的な構成はこの実施形態に限られるものではなく、この発明の要旨を逸脱しない範囲の設計等も含まれる。 Although the embodiments of the present invention have been described in detail with reference to the drawings, the specific configuration is not limited to this embodiment, and includes designs and the like within a range that does not deviate from the gist of the present invention.

1 判定システム
10 判定装置
11 画像情報取得部
12 解析部(推定部)(抽出部)
13 判定部
14 出力部
15 画像情報記憶部
16 学習済みモデル記憶部
17 判定結果記憶部
18 通信部
20 学習装置
21 通信部
22 学習部
3 便器装置
30 便器
32 便鉢
34 内部空間
36 開口部
S 洗浄水
4 撮像装置
1 Judgment system 10 Judgment device 11 Image information acquisition unit 12 Analysis unit (estimation unit) (extraction unit)
13 Judgment unit 14 Output unit 15 Image information storage unit 16 Learned model storage unit 17 Judgment result storage unit 18 Communication unit 20 Learning device 21 Communication unit 22 Learning unit 3 Toilet bowl device 30 Toilet bowl 32 Toilet bowl 34 Internal space 36 Opening S Cleaning Water 4 imager

Claims (8)

排泄物に関する判定事項を判定する判定装置であり、
排泄における便鉢の内部空間を撮像した対象画像の画像情報を取得する画像情報取得部と、
排泄物に想定される所定の想定色の特性を用いて、前記対象画像において前記判定事項に関する判定を行う判定領域を抽出する抽出部と、
前記抽出部により抽出された前記判定領域に示される画像について前記判定事項に関する判定を行う判定部と、
を備えることを特徴とする判定装置。
It is a judgment device that judges judgment items related to excrement.
An image information acquisition unit that acquires image information of a target image that captures the internal space of a toilet bowl during excretion,
An extraction unit that extracts a determination region for making a determination regarding the determination item in the target image using the characteristics of a predetermined assumed color assumed for excrement.
A determination unit that determines the determination items for the image shown in the determination area extracted by the extraction unit, and a determination unit.
A determination device comprising.
前記抽出部は、前記対象画像における画素ごとの色について、前記想定色との色空間上における空間距離を算出し、算出した前記空間距離が所定の閾値未満である画素の集合を、前記判定領域として抽出する、
請求項1に記載の判定装置。
The extraction unit calculates a spatial distance in the color space from the assumed color for each pixel color in the target image, and determines a set of pixels whose calculated spatial distance is less than a predetermined threshold. Extract as,
The determination device according to claim 1.
前記抽出部は、前記対象画像における画素ごとの色について、前記想定色との色の要素ごとの差分に重みづけをした値を用いて、色空間上における空間距離を算出する、
請求項2に記載の判定装置。
The extraction unit calculates the spatial distance in the color space for the color of each pixel in the target image by using a value obtained by weighting the difference between the color element and the assumed color.
The determination device according to claim 2.
前記対象画像は、RGB画像であり、
前記想定色は、RGB値で示される色であり、
前記抽出部は、前記対象画像における画素ごとのR値、G値、B値の比率を示す色比率と、前記想定色における前記色比率との、R要素における比率の差分、G要素における比率の差分、及びB要素における比率の差分に重みづけをした値を用いて、色空間上における空間距離を算出する、
請求項2に記載の判定装置。
The target image is an RGB image and
The assumed color is a color indicated by an RGB value, and is
The extraction unit is a difference between a color ratio indicating a ratio of R value, G value, and B value for each pixel in the target image and the color ratio in the assumed color, a ratio in the R element, and a ratio in the G element. The spatial distance on the color space is calculated using the weighted values of the difference and the difference of the ratio in the B element.
The determination device according to claim 2.
前記抽出部は、前記対象画像における画素ごとに算出した前記空間距離をグレースケールに対応させたグレースケール対象画像を作成し、当該グレースケール対象画像における画素のグレースケール値が所定の第1閾値未満である領域を排泄物がある領域とし、前記判定領域として当該排泄物がある領域を抽出する、
請求項2から請求項4の何れか一項に記載の判定装置。
The extraction unit creates a grayscale target image in which the spatial distance calculated for each pixel in the target image corresponds to a grayscale, and the grayscale value of the pixels in the grayscale target image is less than a predetermined first threshold value. The region where the excrement is present is defined as the region where the excrement is present, and the region where the excrement is present is extracted as the determination region.
The determination device according to any one of claims 2 to 4.
前記抽出部は、前記グレースケール対象画像における画素のグレースケール値が前記第1閾値未満、且つ前記第1閾値より小さい所定の第2閾値以上である領域を水様便がある領域とし、前記グレースケール対象画像における画素のグレースケール値が前記第2閾値未満である領域を硬便がある領域とし、前記判定領域として当該水様便がある領域及び当該硬便がある領域を抽出する、
請求項5に記載の判定装置。
In the extraction unit, a region in which the grayscale value of the pixels in the grayscale target image is less than the first threshold value and equal to or greater than a predetermined second threshold value smaller than the first threshold value is defined as a region where watery stool is present, and the gray scale. A region in which the grayscale value of the pixels in the scale target image is less than the second threshold value is defined as a region having hard stool, and a region having watery stool and a region having hard stool are extracted as the determination region.
The determination device according to claim 5.
排泄物に関する判定事項を判定する判定方法であり、
画像情報取得部が、排泄における便鉢の内部空間を撮像した対象画像の画像情報を取得し、
抽出部が、排泄物に想定される所定の想定色に基づいて、前記対象画像において、前記判定事項に関する判定を行う判定領域を抽出し、
判定部が、前記抽出部により抽出された前記判定領域に示される画像について前記判定事項に関する判定を行う、
判定方法。
It is a judgment method for judging judgment items related to excrement.
The image information acquisition unit acquires the image information of the target image that captures the internal space of the toilet bowl during excretion.
The extraction unit extracts a determination region for making a determination regarding the determination item in the target image based on a predetermined assumed color assumed for excrement.
The determination unit makes a determination regarding the determination item with respect to the image shown in the determination area extracted by the extraction unit.
Judgment method.
排泄物に関する判定事項を判定する判定装置のコンピュータを、
排泄における便鉢の内部空間を撮像した対象画像の画像情報を取得する画像情報取得手段、
排泄物に想定される所定の想定色に基づいて、前記対象画像において、前記判定事項に関する判定を行う判定領域を抽出する抽出手段、
前記抽出手段により抽出された前記判定領域に示される画像について前記判定事項に関する判定を行う判定手段、
として機能させるためのプログラム。
The computer of the judgment device that judges the judgment items related to excrement,
Image information acquisition means for acquiring image information of a target image obtained by capturing the internal space of a toilet bowl in excretion,
An extraction means for extracting a determination region for making a determination regarding the determination item in the target image based on a predetermined assumed color assumed for excrement.
A determination means for determining the determination items with respect to the image shown in the determination region extracted by the extraction means,
A program to function as.
JP2019093678A 2019-05-17 2019-05-17 Determination device, determination method, and program Pending JP2020187089A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2019093678A JP2020187089A (en) 2019-05-17 2019-05-17 Determination device, determination method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2019093678A JP2020187089A (en) 2019-05-17 2019-05-17 Determination device, determination method, and program

Publications (1)

Publication Number Publication Date
JP2020187089A true JP2020187089A (en) 2020-11-19

Family

ID=73221771

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2019093678A Pending JP2020187089A (en) 2019-05-17 2019-05-17 Determination device, determination method, and program

Country Status (1)

Country Link
JP (1) JP2020187089A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022149342A1 (en) * 2021-01-06 2022-07-14 パナソニックホールディングス株式会社 Excrement determination method, excrement determination device, and excrement determination program
WO2022163053A1 (en) * 2021-01-26 2022-08-04 パナソニックホールディングス株式会社 Urination analysis method, urination analysis device, and urination analysis program
WO2023074292A1 (en) * 2021-10-28 2023-05-04 Necプラットフォームズ株式会社 Excrement analysis device, excrement analysis method, pre-colonoscopy state confirmation device, state confirmation system, state confirmation method, and non-temporary computer-readable medium

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022149342A1 (en) * 2021-01-06 2022-07-14 パナソニックホールディングス株式会社 Excrement determination method, excrement determination device, and excrement determination program
WO2022163053A1 (en) * 2021-01-26 2022-08-04 パナソニックホールディングス株式会社 Urination analysis method, urination analysis device, and urination analysis program
WO2023074292A1 (en) * 2021-10-28 2023-05-04 Necプラットフォームズ株式会社 Excrement analysis device, excrement analysis method, pre-colonoscopy state confirmation device, state confirmation system, state confirmation method, and non-temporary computer-readable medium
JP7424651B2 (en) 2021-10-28 2024-01-30 Necプラットフォームズ株式会社 Excrement analysis device, excrement analysis method, and program

Similar Documents

Publication Publication Date Title
WO2020235473A1 (en) Determining device, determining method, and program
JP2020187089A (en) Determination device, determination method, and program
An et al. Application of computer vision in fish intelligent feeding system—A review
JP5848551B2 (en) Learning device, learning device control method, detection device, detection device control method, and program
US20220375080A1 (en) Determination device
US11087462B2 (en) System and method for determining a colonoscopy image
CN107145878A (en) Old man's anomaly detection method based on deep learning
Banhazi et al. Improved image analysis based system to reliably predict the live weight of pigs on farm: Preliminary results
Mousavi et al. Analysis of a robust edge detection system in different color spaces using color and depth images
CN112766040B (en) Method, device, apparatus and readable storage medium for detecting residual bait
JP4978227B2 (en) Image detection device
CN111652817B (en) Underwater image sharpening method based on human eye visual perception mechanism
JPWO2019198701A1 (en) Analyzers, analytical methods, programs and aquatic organism monitoring systems
JP7262301B2 (en) Determination device, determination method, and program
Brusey et al. Techniques for obtaining robust, real-time, colour-based vision for robotics
JP2020187692A (en) Determination device, determination method, and program
JP2020187691A (en) Determination device, determination method, and program
KR101976494B1 (en) Method And Potty for Analyzing Personal Health
KR102411765B1 (en) Correct posture estimation system and method using neural network
US20230009654A1 (en) Excrement management system, excretion information management method, computer program, edge server, and toilet seat device
Carnimeo et al. An intelligent system for improving detection of diabetic symptoms in retinal images
JP6945663B2 (en) Estimator program, estimation method and information processing device
KR102197620B1 (en) An apparatus for providing statistical information of outdoor wear, a method therefor and a computer readable recording medium on which a program for carrying out the method is recorded
GB2605580A (en) Apparatus and method of image processing to detect a substance spill on a solid surface
JP2021164628A (en) Excrement management system, excrement management method, program, edge server, and toilet seat device

Legal Events

Date Code Title Description
A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20210120