[go: up one dir, main page]

KR102156279B1 - Method and automated camera-based system for detecting and suppressing harmful behavior of pet - Google Patents

Method and automated camera-based system for detecting and suppressing harmful behavior of pet Download PDF

Info

Publication number
KR102156279B1
KR102156279B1 KR1020180136789A KR20180136789A KR102156279B1 KR 102156279 B1 KR102156279 B1 KR 102156279B1 KR 1020180136789 A KR1020180136789 A KR 1020180136789A KR 20180136789 A KR20180136789 A KR 20180136789A KR 102156279 B1 KR102156279 B1 KR 102156279B1
Authority
KR
South Korea
Prior art keywords
image data
companion animal
image
dangerous behavior
generating
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.)
Active
Application number
KR1020180136789A
Other languages
Korean (ko)
Other versions
KR20200055821A (en
Inventor
박대희
오스만 아티프
이준희
Original Assignee
고려대학교 세종산학협력단
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 고려대학교 세종산학협력단 filed Critical 고려대학교 세종산학협력단
Priority to KR1020180136789A priority Critical patent/KR102156279B1/en
Publication of KR20200055821A publication Critical patent/KR20200055821A/en
Application granted granted Critical
Publication of KR102156279B1 publication Critical patent/KR102156279B1/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A01AGRICULTURE; FORESTRY; ANIMAL HUSBANDRY; HUNTING; TRAPPING; FISHING
    • A01KANIMAL HUSBANDRY; AVICULTURE; APICULTURE; PISCICULTURE; FISHING; REARING OR BREEDING ANIMALS, NOT OTHERWISE PROVIDED FOR; NEW BREEDS OF ANIMALS
    • A01K29/00Other apparatus for animal husbandry
    • A01K29/005Monitoring or measuring activity, e.g. detecting heat or mating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Landscapes

  • Life Sciences & Earth Sciences (AREA)
  • Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Theoretical Computer Science (AREA)
  • Environmental Sciences (AREA)
  • Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Biomedical Technology (AREA)
  • Biodiversity & Conservation Biology (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Animal Husbandry (AREA)
  • Image Analysis (AREA)

Abstract

카메라에 의해 촬영된 반려 동물의 영상에 기반한 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 CNN에 대해 CNN 출력 값을 생성하는 CNN 출력 값을 생성하고, CNN 출력 값을 입력 값으로 하는 LSTM에 대해 LSTM 출력 값을 생성하며, LSTM 출력 값에 기반하여 반려 동물의 위험 행동을 검출하는 반려 동물의 위험 행동 검출 및 억제 시스템이 제공된다.For a CNN that uses each image data of an image data set based on the image of a companion animal captured by a camera as an input value of a multi-stream, a CNN output value is generated, and a CNN output value is used as an input value. An LSTM output value is generated for the LSTM, and a companion animal's dangerous behavior detection and suppression system is provided that detects the companion animal's dangerous behavior based on the LSTM output value.

Figure R1020180136789
Figure R1020180136789

Description

반려 동물의 위험 행동의 검출 및 억제 방법 및 이를 위한 자동화된 카메라-기반 시스템{METHOD AND AUTOMATED CAMERA-BASED SYSTEM FOR DETECTING AND SUPPRESSING HARMFUL BEHAVIOR OF PET}A method for detecting and inhibiting dangerous behavior of companion animals, and an automated camera-based system for the same{METHOD AND AUTOMATED CAMERA-BASED SYSTEM FOR DETECTING AND SUPPRESSING HARMFUL BEHAVIOR OF PET}

실시예들은 반려 동물의 위험 행동의 검출 및 억제 방법 및 시스템에 관한 것으로, 특히, 카메라에 의해 촬영된 반려 동물의 영상을 처리하여 상기 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하고, 생성된 영상 데이터 세트를 분석하는 것을 통해 반려 동물의 위험 행동을 검출하고 억제하기 위한 방법 및 시스템과 관련된다.The embodiments relate to a method and system for detecting and inhibiting dangerous behavior of a companion animal, and in particular, processing an image of a companion animal photographed by a camera to generate an image data set for analyzing the companion animal's behavior, and the generated It relates to methods and systems for detecting and suppressing dangerous behaviors in companion animals through analyzing image data sets.

반려 동물을 키우는 것은 인간의 육체적 및 정신적 건강에 있어서 도움이 되며, 반려 동물을 키우는 인구 역시 급속도로 증가하고 있다. 이러한 반려 동물을 키우는 인구가 증가와 함께, 반려 동물의 보호자(반려인)의 생활 패턴에 따라 보호자가 직장에 근무하거나 장시간 동안 자리를 비우는 동안 반려 동물이 혼자 방치되는 경우 역시 증가하고 있다. Raising companion animals is helpful for human physical and mental health, and the population raising companion animals is also increasing rapidly. Along with the increase in the number of companion animals, the number of cases in which the companion animal is left alone while the guardian works at work or is away for a long time is also increasing according to the life pattern of the guardian (companion) of the companion animal.

생활 공간 내에서 반려 동물을 장시간 동안 혼자 방치할 경우, 반려 동물은 분리 불안 증후군을 앓게 될 수 있고, 반려인의 부재 동안 반려 동물은 불안감을 느끼면서 심하게 짖거나, 기물 파손, 배변 실수 등의 부적절한 행동(즉, 위험 행동)을 할 수 있다. 이러한 반려 동물의 위험 행동은 반려 동물의 육체적 및 정신적 건강을 해치며, 반려인에게도 스트레스를 야기한다. If the companion animal is left alone for a long time in the living space, the companion animal may suffer from separation anxiety syndrome.During the absence of the companion animal, the companion animal feels anxious and barks severely, vandalism, and defecation. You can take action (i.e., dangerous action). These dangerous behaviors of companion animals harm the companion animal's physical and mental health and cause stress to the companion animal.

따라서, 이러한 위험 행동을 정확하게 검출할 수 있고, 위험 행동을 억제하기 위한 올바른 조치를 취할 수 있도록 하는 방법 및 시스템이 요구된다.Accordingly, there is a need for a method and system that can accurately detect such dangerous behavior and take correct actions to suppress the dangerous behavior.

한국공개특허 제10-2018-0067107호(공개일 2018년 06월 20일)는 반려 동물의 건강 관리 장치에 관한 것으로서, 급수부와 급식부 및 센싱 패드를 이용하는 반려 동물의 건강 관리 장치를 설명하고 있다. Korean Patent Publication No. 10-2018-0067107 (published on June 20, 2018) relates to a health management device for a companion animal, and describes a health management device for a companion animal using a water supply unit, a feeding unit, and a sensing pad. have.

상기에서 설명된 정보는 단지 이해를 돕기 위한 것이며, 종래 기술의 일부를 형성하지 않는 내용을 포함할 수 있으며, 종래 기술이 통상의 기술자에게 제시할 수 있는 것을 포함하지 않을 수 있다.The information described above is for illustrative purposes only, may include content that does not form part of the prior art, and may not include what the prior art may present to a person skilled in the art.

일 실시예는, 카메라에 의해 촬영된 반려 동물의 영상에 기반한 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 CNN에 대해 CNN 출력 값을 생성하는 CNN 출력 값을 생성하고, CNN 출력 값을 입력 값으로 하는 LSTM에 대해 LSTM 출력 값을 생성하며, LSTM 출력 값에 기반하여 반려 동물의 위험 행동을 검출하는 반려 동물의 위험 행동 검출 및 억제 시스템을 제공할 수 있다.In one embodiment, a CNN output value for generating a CNN output value is generated for a CNN using each image data of an image data set based on an image of a companion animal captured by a camera as an input value of a multi-stream, and a CNN output value An LSTM output value is generated for an LSTM having as an input value, and a dangerous behavior detection and suppression system of a companion animal can be provided that detects the dangerous behavior of the companion animal based on the LSTM output value.

일 실시예는, 반려 동물의 위험 행동이 검출된 때 이를 사용자 단말로 통지하고, 사용자 단말로부터의 명령에 따라 반려 동물의 위험 행동에 대한 적절한 조치를 취할 수 있도록 하는 방법 및 시스템을 제공할 수 있다. An embodiment may provide a method and system for notifying a dangerous behavior of a companion animal to a user terminal when a dangerous behavior of a companion animal is detected, and taking appropriate measures for the dangerous behavior of the companion animal according to a command from the user terminal. .

일 측면에 있어서, 카메라에 의해 촬영된 반려 동물의 영상을 처리하여 상기 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 영상 데이터 처리부, 상기 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 콘볼루션 신경망(Convolutional Neural Network; CNN)에 대해 CNN 출력 값을 생성하는 CNN 출력 값 생성부, 상기 CNN 출력 값을 입력 값으로 하는 장단기메모리(Long Short-Term Memory; LSTM)에 대해 LSTM 출력 값을 생성하는 LSTM 출력 값 생성부 및 상기 LSTM 출력 값에 기반하여 상기 반려 동물의 위험 행동을 검출하는 위험 행동 검출부를 포함하는, 반려 동물의 위험 행동 검출 및 억제 시스템이 제공된다. In one aspect, an image data processing unit that generates an image data set for analyzing the behavior of the companion animal by processing an image of a companion animal photographed by a camera, each image data of the image data set as an input value of a multi-stream A CNN output value generator that generates a CNN output value for a convolutional neural network (CNN), and an LSTM output value for a long short-term memory (LSTM) that uses the CNN output value as an input value. There is provided a system for detecting and inhibiting dangerous behavior of a companion animal, including an LSTM output value generator for generating a and a dangerous behavior detection unit for detecting a dangerous behavior of the companion animal based on the LSTM output value.

상기 영상 데이터 처리부는 상기 반려 동물의 영상이 포함하는 복수의 영상 클립들을 시간 파라미터 및 공간 파라미터에 기반하여 라벨링할 수 있다. The image data processor may label a plurality of image clips included in the image of the companion animal based on a temporal parameter and a spatial parameter.

상기 영상 데이터 세트는 상기 라벨링된 복수의 영상 클립들을 포함할 수 있다. The image data set may include the labeled image clips.

상기 영상 데이터 세트는 상기 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터를 포함할 수 있다. The image data set may include flipped image data for each of the labeled image clips.

상기 플립된 영상 데이터는 상기 라벨링된 복수의 영상 클립들의 각각에 대한 수평 플립(horizontal filpped) 영상 데이터, 수직 플립(vertical) 영상 데이터 및 수평 및 수직 플립(combined filpped) 영상 데이터를 포함할 수 있다. The flipped image data may include horizontally flipped image data, vertical flipped image data, and horizontal and vertically flipped image data for each of the plurality of labeled image clips.

상기 영상 데이터 처리부는 제1 영상 데이터에 해당하는 상기 라벨링된 복수의 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임에 대해, 상기 제1 영상 데이터에서 상기 반려 동물을 추적함으로써 상기 반려 동물을 포함하도록 크롭된 제2 영상 데이터를 생성하고, 상기 제1 영상 데이터와 연관된 광학 흐름(optical flow) 추출 영상인 제3 영상 데이터를 생성하고, 상기 제2 영상 데이터와 연관된 광학 흐름 추출 영상인 제4 영상 데이터를 생성하고, 상기 제1 영상 데이터, 상기 제2 영상 데이터, 상기 제3 영상 데이터 및 상기 제4 영상 데이터가 상기 CNN에 대해 멀티 스트림의 입력 값이 될 수 있다. The image data processor detects the companion animal by tracking the companion animal from the first image data for each video clip of the labeled plurality of video clips or each frame of each video clip corresponding to the first video data. Generates second image data cropped to include, generates third image data that is an optical flow extraction image associated with the first image data, and generates a fourth image that is an optical flow extraction image associated with the second image data Image data may be generated, and the first image data, the second image data, the third image data, and the fourth image data may be input values of a multi-stream for the CNN.

상기 제2 영상 데이터를 생성에 있어서의 상기 반려 동물의 추적은 YOLOv3 또는 YOLOv2 알고리즘을 사용하여 수행될 수 있다. In generating the second image data, tracking of the companion animal may be performed using a YOLOv3 or YOLOv2 algorithm.

상기 제3 영상 데이터 및 상기 제4 영상 데이터를 생성함에 있어서의 광학 흐름 추출은 Farneback 알고리즘, Pyflow 알고리즘, EpicFlow 알고리즘 또는 FlowNet 알고리즘을 사용하여 수행되고, 상기 CNN은 VGG16 모델을 사용하여 구현된 것일 수 있다. Optical flow extraction in generating the third image data and the fourth image data is performed using a Farneback algorithm, a Pyflow algorithm, an EpicFlow algorithm, or a FlowNet algorithm, and the CNN may be implemented using a VGG16 model. .

상기 카메라에 의해 촬영된 반려 동물의 영상은 탑-다운(top-down) 앵글을 갖는 카메라에 의해 촬영된 것이고, 상기 반려 동물의 영상은 공간 내에 혼자 있는 상기 반려 동물의 영상일 수 있다. The image of the companion animal photographed by the camera is photographed by a camera having a top-down angle, and the image of the companion animal may be an image of the companion animal alone in the space.

상기 위험 행동 검출부는 상기 LSTM 출력 값에 기반하여 상기 반려 동물의 활동을 결정하고 상기 활동을 입력 데이터로서, 상기 입력 데이터를 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로써 상기 반려 동물의 위험 행동을 검출할 수 있다. The dangerous behavior detection unit determines the activity of the companion animal based on the LSTM output value, uses the activity as input data, and analyzes the input data using Complex Event Processing (CEP). Dangerous behavior can be detected.

상기 위험 행동 검출부에 의한 검출에 따라, 상기 반려 동물의 위험 행동이 검출되었음을 나타내는 데이터는 사용자 단말로 출력될 수 있다. According to the detection by the dangerous behavior detection unit, data indicating that the dangerous behavior of the companion animal is detected may be output to the user terminal.

상기 위험 행동 검출 및 억제 시스템은 상기 사용자 단말을 통해 수신된 명령에 따라 상기 반려 동물의 위험 행동을 해소하기 위한 조치를 수행하기 위한 조치 명령을 생성하고, 상기 조치 명령을 적어도 하나의 외부 장치로 전송하는 위험 행동 조치부를 더 포함할 수 있다. The dangerous behavior detection and suppression system generates an action command for performing a measure to eliminate the dangerous behavior of the companion animal according to the command received through the user terminal, and transmits the action command to at least one external device. It may further include a risk action action unit.

상기 영상 데이터 처리부는 상기 반려 동물의 영상으로부터 상기 영상의 RGB 정보 및 광학 흐름 정보를 추출할 수 있다. The image data processor may extract RGB information and optical flow information of the image from the image of the companion animal.

상기 위험 행동 검출부는 투-스트림(Two-Stream) YOLOv2 알고리즘을 사용하여, 상기 RGB 정보로부터 상기 반려 동물의 형상 정보를 획득하고, 상기 광학 흐름 정보로부터 상기 반려 동물의 움직임 정보를 획득하며, 상기 형상 정보 및 상기 움직임 정보에 기반하여 상기 반려 동물의 활동을 결정할 수 있다. The dangerous behavior detection unit uses a two-stream YOLOv2 algorithm to obtain shape information of the companion animal from the RGB information, and obtains motion information of the companion animal from the optical flow information, and the shape An activity of the companion animal may be determined based on the information and the motion information.

상기 위험 행동 검출부는 상기 결정된 활동을 입력 데이터로서, 상기 입력 데이터를 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로써 상기 반려 동물의 위험 행동을 검출할 수 있다. The dangerous behavior detection unit may detect the dangerous behavior of the companion animal by analyzing the determined activity as input data and analyzing the input data using Complex Event Processing (CEP).

다른 일 측면에 있어서, 컴퓨터에 의해 수행되는 반려 동물의 위험 행동의 검출 및 억제 방법에 있어서, In another aspect, in a method for detecting and inhibiting dangerous behavior of a companion animal performed by a computer,

카메라에 의해 촬영된 반려 동물의 영상을 처리하여 상기 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 단계, 상기 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 콘볼루션 신경망(Convolutional Neural Network; CNN)에 대해 CNN 출력 값을 생성하는 단계, 상기 CNN 출력 값을 입력 값으로 하는 장단기메모리(Long Short-Term Memory; LSTM)에 대해 LSTM 출력 값을 생성하는 단계 및 상기 LSTM 출력 값에 기반하여 상기 반려 동물의 위험 행동을 검출하는 단계를 포함하는, 반려 동물의 위험 행동의 검출 및 억제 방법이 제공된다. Generating an image data set for analyzing the behavior of the companion animal by processing the image of the companion animal captured by the camera, a convolutional neural network using each image data of the image data set as an input value of a multi-stream. Generating a CNN output value for Network; CNN), generating an LSTM output value for a long short-term memory (LSTM) using the CNN output value as an input value, and based on the LSTM output value Thus, there is provided a method for detecting and inhibiting dangerous behavior of the companion animal, comprising the step of detecting the dangerous behavior of the companion animal.

상기 영상 데이터 세트를 생성하는 단계는, 상기 반려 동물의 영상이 포함하는 복수의 영상 클립들을 시간 파라미터 및 공간 파라미터에 기반하여 라벨링하는 단계 및 상기 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터를 추가적인 라벨링된 영상 클립으로서 생성하는 단계를 포함하고, 상기 영상 데이터 세트는 상기 플립된 영상 데이터를 포함할 수 있다. The generating of the image data set includes labeling a plurality of image clips included in the image of the companion animal based on a temporal parameter and a spatial parameter, and flipped image data for each of the labeled image clips. Generating as an additional labeled image clip, and the image data set may include the flipped image data.

상기 영상 데이터 세트를 생성하는 단계는, 제1 영상 데이터에 해당하는 상기 라벨링된 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임에 대해, 상기 제1 영상 데이터에서 상기 반려 동물을 추적함으로써 상기 반려 동물을 포함하도록 크롭된 영상인 제2 영상 데이터를 생성하는 단계, 상기 제1 영상 데이터와 연관된 광학 흐름(optical flow) 추출 영상인 제3 영상 데이터를 생성하는 단계 및 상기 제2 영상 데이터와 연관된 광학 흐름 추출 영상인 제4 영상 데이터를 생성하는 단계를 포함하고, 상기 제1 영상 데이터, 상기 제2 영상 데이터, 상기 제3 영상 데이터 및 상기 제4 영상 데이터가 상기 CNN에 대해 멀티 스트림의 입력 값이 될 수 있다. The generating of the image data set includes, for each image clip of the labeled image clips corresponding to the first image data or each frame of the image clip, by tracking the companion animal from the first image data. Generating second image data that is an image cropped to include a companion animal, generating third image data that is an image extracted from an optical flow associated with the first image data, and associated with the second image data Generating fourth image data that is an optical flow extraction image, wherein the first image data, the second image data, the third image data, and the fourth image data are input values of a multi-stream for the CNN Can be

상기 위험 행동의 검출 및 억제 방법은, 상기 반려 동물의 위험 행동이 검출되었음을 나타내는 데이터를 사용자 단말로 출력하는 단계, 상기 사용자 단말로부터 명령을 수신하는 단계, 상기 수신된 명령에 따라 상기 반려 동물의 위험 행동을 해소하기 위한 조치를 수행하기 위한 조치 명령을 생성하는 단계, 및 상기 조치 명령을 적어도 하나의 외부 장치로 전송하는 단계를 포함할 수 있다. The method of detecting and suppressing dangerous behavior includes outputting data indicating that the dangerous behavior of the companion animal is detected to a user terminal, receiving a command from the user terminal, and the risk of the companion animal according to the received command. It may include generating an action command for performing an action for resolving an action, and transmitting the action command to at least one external device.

상기 영상 데이터 세트를 생성하는 단계는, 상기 반려 동물의 영상으로부터 상기 영상의 RGB 정보 및 광학 흐름 정보를 추출하는 단계를 포함할 수 있다. The generating the image data set may include extracting RGB information and optical flow information of the image from the image of the companion animal.

상기 반려 동물의 위험 행동의 검출 및 억제 방법은, 투-스트림(Two-Stream) YOLOv2 알고리즘을 사용하여, 상기 RGB 정보로부터 상기 반려 동물의 형상 정보를 획득하고, 상기 광학 흐름 정보로부터 상기 반려 동물의 움직임 정보를 획득하는 단계, 상기 형상 정보 및 상기 움직임 정보에 기반하여 상기 반려 동물의 활동을 결정하는 단계, 및 상기 결정된 활동을 입력 데이터로서, 상기 입력 데이터를 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로써 상기 반려 동물의 위험 행동을 검출하는 단계를 더 포함할 수 있다.The method of detecting and inhibiting dangerous behavior of the companion animal is to obtain the shape information of the companion animal from the RGB information, using a two-stream YOLOv2 algorithm, and the companion animal from the optical flow information. Acquiring motion information, determining an activity of the companion animal based on the shape information and the motion information, and using the determined activity as input data, and processing the input data as complex event processing (CEP) It may further include the step of detecting the dangerous behavior of the companion animal by using the analysis.

실시예의 반려 동물의 위험 행동 검출 및 억제 시스템은, 카메라에 의해 촬영된 반려 동물의 영상을 처리함으로써 생성된 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 CNN에 대해 CNN 출력 값을 생성하고, 해당 CNN 출력 값을 입력 값으로 하는 LSTM의 LSTM 출력 값에 기반하여 반려 동물의 위험 행동을 검출함으로써 반려 동물의 위험 행동이 보다 정확하게 검출될 수 있다.The system for detecting and suppressing dangerous behavior of companion animals according to the embodiment generates a CNN output value for a CNN using each image data of an image data set generated by processing an image of a companion animal captured by a camera as an input value of a multi-stream. And, by detecting the dangerous behavior of the companion animal based on the LSTM output value of the LSTM using the corresponding CNN output value as an input value, the dangerous behavior of the companion animal may be more accurately detected.

실시예의 반려 동물의 위험 행동 검출 및 억제 시스템은, CNN 학습을 위한 반려 동물의 영상으로서, 라벨링된 클립들 각각에 대한 플립된 영상을 더 사용함으로써, 라벨링된 영상의 수를 늘릴 수 있고, 라벨링 과정에 소요되는 시간 및 자원을 절감할 수 있다. The system for detecting and suppressing dangerous behaviors of companion animals according to the embodiment may increase the number of labeled images by further using flipped images for each of the labeled clips as images of companion animals for CNN learning, and the labeling process You can reduce the time and resources required for operation.

실시예의 반려 동물의 위험 행동 검출 및 억제 시스템은, 반려 동물의 제1 영상 데이터, 제1 영상 데이터의 반려 동물을 추적함에 따라 크롭된 제2 영상 데이터, 제1 영상 데이터의 광학 흐름 추출 영상인 제3 영상 데이터 및 제2 영상 데이터의 광학 흐름 추출 영상인 제4 영상 데이터를 멀티 스트림 입력으로서 사용하는 CNN을 활용함으로써, 반려 동물의 위험 행동의 검출의 정확성을 높일 수 있다. The system for detecting and suppressing dangerous behavior of companion animals according to the embodiment includes: a first image data of a companion animal, second image data cropped by tracking a companion animal of the first image data, and a first image data extracted from the optical flow of the first image data. By using a CNN that uses the third image data and the fourth image data, which is an optical flow extraction image of the second image data, as a multi-stream input, it is possible to improve the accuracy of detection of dangerous behaviors of companion animals.

도 1은 일 실시예에 따른, 반려 동물의 위험 행동 검출 및 억제 시스템의 구조를 나타내는 블록도이다.
도 2는 일 예에 따른, 반려 동물의 영상을 처리하여 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 방법을 나타낸다.
도 3은 일 실시예에 따른, 반려 동물의 위험 행동을 검출하기 위한 CNN 출력 값 및 LSTM 출력 값을 생성하는 방법을 나타낸다.
도 4는 일 예에 따른, 반려 동물의 영상을 처리하여 멀티 스트림 CNN을 위한 입력 영상 데이터를 생성하는 방법을 나타낸다.
도 5는 일 실시예에 따른, 반려 동물의 영상에 기반하여 반려 동물의 활동을 결정하는 방법을 나타낸다.
도 6 및 도 7은 일 예에 따른, 인식된 반려 동물의 활동을 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로서 반려 동물의 행동을 파악하기 위해 사용되는 코드를 나타낸다.
도 8은 일 실시예에 따른, 반려 동물의 위험 행동 검출 및 억제 시스템에 의한 반려 동물의 위험 행동의 검출 및 억제 방법을 나타내는 흐름도이다.
도 9는 일 예에 따른, 반려 동물의 영상을 처리하여 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 방법을 나타내는 흐름도이다.
도 10은 일 예에 따른, 반려 동물의 영상을 처리하여 멀티 스트림 CNN을 위한 입력 영상 데이터를 생성하는 방법을 나타내는 흐름도이다.
도 11은 일 실시예에 따른, 반려 동물의 영상에 기반하여 반려 동물의 활동을 결정하는 방법을 나타내는 흐름도이다.
1 is a block diagram showing the structure of a system for detecting and inhibiting dangerous behavior of a companion animal according to an embodiment.
2 illustrates a method of generating an image data set for analyzing a companion animal's behavior by processing an image of a companion animal, according to an example.
3 illustrates a method of generating a CNN output value and an LSTM output value for detecting dangerous behavior of a companion animal, according to an embodiment.
4 illustrates a method of generating input image data for a multi-stream CNN by processing an image of a companion animal according to an example.
5 illustrates a method of determining an activity of a companion animal based on an image of the companion animal, according to an exemplary embodiment.
6 and 7 illustrate codes used to identify the behavior of the companion animal by analyzing the activity of the recognized companion animal using Complex Event Processing (CEP), according to an example.
8 is a flowchart illustrating a method of detecting and inhibiting dangerous behaviors of companion animals by a system for detecting and suppressing dangerous behaviors of companion animals according to an exemplary embodiment.
9 is a flowchart illustrating a method of generating an image data set for analyzing a companion animal's behavior by processing an image of a companion animal, according to an example.
10 is a flowchart illustrating a method of generating input image data for a multi-stream CNN by processing an image of a companion animal, according to an example.
11 is a flowchart illustrating a method of determining an activity of a companion animal based on an image of the companion animal, according to an exemplary embodiment.

이하에서, 첨부된 도면을 참조하여 실시예들을 상세하게 설명한다. 각 도면에 제시된 동일한 참조 부호는 동일한 부재를 나타낸다.Hereinafter, exemplary embodiments will be described in detail with reference to the accompanying drawings. The same reference numerals in each drawing indicate the same members.

도 1은 일 실시예에 따른, 반려 동물의 위험 행동 검출 및 억제 시스템의 구조를 나타내는 블록도이다. 1 is a block diagram showing the structure of a system for detecting and inhibiting dangerous behavior of a companion animal according to an embodiment.

도 1을 참조하여, 반려 동물(160)의 카메라(102)에 의해 촬영된 영상으로부터, 반려 동물(160)이 위험 행동을 하는지 여부를 모니터링하고, 반려 동물(160)의 위험 행동이 검출되는 경우 이에 대해 적절한 조치를 취할 수 있도록 하는 행동 검출 및 억제 시스템에 대해 설명한다.Referring to FIG. 1, from the image captured by the camera 102 of the companion animal 160, it is monitored whether the companion animal 160 has a dangerous behavior, and a dangerous behavior of the companion animal 160 is detected. It describes a behavior detection and suppression system that allows appropriate action to be taken.

반려 동물(160)은 도시된 것처럼, 개(강아지)일 수 있고, 또는, 고양이나 기타 반려 동물일 수 있다. 반려 동물(160)은 예컨대, 집과 같은 반려인이 함께 생활하는 공간에 있을 수 있다. 도시된 예시에서는 반려인은 부재중이며, 반려 동물(160) 만이 생활 공간 내에 있을 수 있다.As shown, the companion animal 160 may be a dog (dog), or may be a cat or other companion animal. The companion animal 160 may be in a space where the companion animal lives together, such as at home. In the illustrated example, the companion is absent, and only the companion animal 160 may be in the living space.

이러한 생활 공간 내에는 적어도 하나의 카메라(102)가 배치될 수 있고, 카메라(102)는 반려 동물(160)을 촬영함으로써 반려 동물(160)의 영상을 생성할 수 있다. 반려 동물(160)의 영상은 반려 동물(160)의 위험 행동을 검출하기 위해 분석될 수 있다. 카메라(102)에 의해 촬영된 반려 동물(160)의 영상은 탑-다운(top-down) 앵글을 갖는 카메라에 의해 촬영된 것일 수 있다(일례로, 카메라(102)는 천정에 배치되어 아래쪽의 앵글로 반려 동물(160)을 촬영하는 카메라일 수 있다). 카메라(102)가 복수인 경우 복수의 카메라들 중 적어도 하나의 카메라는 탑-다운 앵글을 갖는 카메라일 수 있다. 촬영된 반려 동물(160)의 영상은 공간(생활 공간) 내에 혼자 있는 반려 동물(160)의 영상일 수 있다.At least one camera 102 may be disposed in the living space, and the camera 102 may generate an image of the companion animal 160 by photographing the companion animal 160. The image of the companion animal 160 may be analyzed to detect the dangerous behavior of the companion animal 160. The image of the companion animal 160 photographed by the camera 102 may be photographed by a camera having a top-down angle (for example, the camera 102 is disposed on the ceiling and It may be a camera that photographs the companion animal 160 at an angle). When there are a plurality of cameras 102, at least one of the plurality of cameras may be a camera having a top-down angle. The captured image of the companion animal 160 may be an image of the companion animal 160 alone in the space (living space).

카메라(102)에 의해 촬영된 반려 동물(160)의 영상은 서버(100)에 의해 분석될 수 있고, 서버(100)는 반려 동물(160)의 영상을 분석하여 반려 동물(160)의 위험 행동을 검출할 수 있다. The image of the companion animal 160 photographed by the camera 102 may be analyzed by the server 100, and the server 100 analyzes the image of the companion animal 160 to conduct dangerous behavior of the companion animal 160 Can be detected.

서버(100)는 생활 공간의 외부(혹은 내부)에 존재하는 컴퓨터 장치일 수 있다. 서버(100)는 클라우드 서버일 수 있다. 반려 동물(160)이 위험 행동을 하고 있는 것으로 판정된 때, 서버(100)는 반려인의 사용자 단말(170)로 반려 동물(160)이 위험 행동을 나타내는 데이터를 송신할 수 있다.The server 100 may be a computer device that exists outside (or inside) a living space. The server 100 may be a cloud server. When it is determined that the companion animal 160 is performing dangerous behavior, the server 100 may transmit data indicating the dangerous behavior of the companion animal 160 to the user terminal 170 of the companion animal.

사용자 단말(170)은 반려 동물(160)의 위험 행동(즉, 위험 행동을 하고 있음)을 나타내는 알림(또는 경보)을 출력함으로써 반려인에게 반려 동물(160)의 상태를 통지할 수 있다.The user terminal 170 may notify the companion animal 160 of the status of the companion animal 160 by outputting a notification (or alarm) indicating the dangerous behavior (ie, dangerous behavior) of the companion animal 160.

반려인은, 사용자 단말(170)을 통해, 서버(100)에 반려 동물(160)의 위험 행동을 해소하기 위한 조치를 취하기 위한 명령을 송신할 수 있다. 서버(100)는 수신된 명령에 따라 생활 공간 내의 외부 장치에 대해 제어 명령을 송신할 수 있다. 예컨대, 제어 명령에 따라 TV와 같은 외부 장치(180)는 반려 동물(160)의 위험 행동을 해소하기 위해 도움이 되는 비디오 또는 사운드를 출력할 수 있고, 먹이 공급 장치와 같은 외부 장치(180)는 반려 동물(160)에게 먹이를 제공할 수 있다.The companion may transmit a command to the server 100 through the user terminal 170 to take measures to eliminate the dangerous behavior of the companion animal 160. The server 100 may transmit a control command to an external device in the living space according to the received command. For example, according to a control command, the external device 180 such as a TV may output a video or sound that is helpful to eliminate the dangerous behavior of the companion animal 160, and the external device 180 such as a food supply device Food may be provided to the companion animal 160.

반려 동물(160)의 위험 행동은 예컨대, 심하게 짖거나, 하울링하거나 우는(낑낑거리는) 행동, 기물 파손 또는 물어 뜯기와 같은 파괴적 행동, 배변/배뇨 실수와 같은 배설 행동일 수 있다. 반려 동물(160)의 위험 행동은 반려 동물(160)의 분리 불안에 의해 야기될 수 있는 반려 동물(160)의 이상 행동일 수 있다. 또는, 반려 동물(160)의 위험 행동은 반려 동물(160)의 건강 상태에 문제가 있거나, 반려 동물(160)의 행동이 반려 동물(160)의 건강 상태에 문제를 야기할 가능성이 있게 되는 반려 동물(160)의 해당 행동을 나타낼 수 있다.The dangerous behavior of the companion animal 160 may be, for example, a violent barking, howling, or crying (whipped) behavior, a destructive behavior such as vandalism or biting, and an excretory behavior such as a defecation/urination error. The dangerous behavior of the companion animal 160 may be an abnormal behavior of the companion animal 160 that may be caused by separation anxiety of the companion animal 160. Alternatively, the risky behavior of the companion animal 160 is a companion in which there is a problem in the health condition of the companion animal 160, or the behavior of the companion animal 160 may cause a problem in the health state of the companion animal 160 The corresponding behavior of the animal 160 may be indicated.

도 1을 참조하여 설명한 것과 같은 서버(100)를 포함하는 반려 동물(160)의 위험 행동 검출 및 억제 시스템에 의해서는, 카메라(102)로부터의 영상을 분석하는 것을 통해 반려 동물(160)이 위험 행동을 하는지 여부가 실시간으로 파악될 수 있고, 그에 대한 조치 역시 실시간으로 이루어질 수 있다.By the system for detecting and suppressing the dangerous behavior of the companion animal 160 including the server 100 as described with reference to FIG. 1, the companion animal 160 is at risk by analyzing the image from the camera 102. Whether or not to act can be identified in real time, and actions can be taken in real time.

아래에서, 서버(100)의 구성에 대해 보다 자세하게 설명한다. In the following, the configuration of the server 100 will be described in more detail.

서버(100)는 카메라(102)에 의해 촬영된 반려 동물(160)의 영상을 처리하여 반려 동물(160)의 행동 분석을 위한 영상 데이터 세트를 생성하는 영상 데이터 처리부(110)와, 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 콘볼루션 신경망(Convolutional Neural Network; CNN)에 대해 CNN 출력 값을 생성하는 CNN 출력 값 생성부(120)와, 이러한 CNN 출력 값을 입력 값으로 하는 장단기메모리(Long Short-Term Memory; LSTM)에 대해 LSTM 출력 값을 생성하는 LSTM 출력 값 생성부(130) 및 LSTM 출력 값에 기반하여 반려 동물(160)의 위험 행동을 검출하는 위험 행동 검출부(140)를 포함할 수 있다.The server 100 processes the image of the companion animal 160 captured by the camera 102 to generate an image data set for analyzing the behavior of the companion animal 160, and an image data set. A CNN output value generator 120 that generates a CNN output value for a convolutional neural network (CNN) that uses each image data of as an input value of a multi-stream, and a short-term long-term using such CNN output values as input values. An LSTM output value generator 130 that generates an LSTM output value for a memory (Long Short-Term Memory (LSTM)) and a dangerous behavior detection unit 140 that detects a dangerous behavior of the companion animal 160 based on the LSTM output value. It may include.

영상 데이터 처리부(110)는 카메라(102)로부터 수신된 반려 동물(160)의 영상에 기반하여 멀티 스트림 CNN을 위한 입력으로서 적합한 영상 데이터 세트를 생성할 수 있다. 카메라(102)로부터 수신된 반려 동물(160)의 영상은 복수의 영상 클립들을 포함할 수 있다. 각 영상 클립은 소정의 길이의 단위 영상일 수 있다. 영상 데이터 처리부(110)는 반려 동물(160)의 영상이 포함하는 복수의 영상 클립들을 라벨링할 수 있다. 예컨대, 영상 데이터 처리부(110)는 복수의 영상 클립들을 시간 파라미터 및 공간 파라미터에 기반하여(즉, 시간 파라미터 및 공간 파라미터에 따라) 라벨링할 수 있다. 영상 데이터 처리부(110)에 의해 생성되는 영상 데이터 세트는 이러한 라벨링된 복수의 영상 클립들을 포함할 수 있다. The image data processing unit 110 may generate an image data set suitable as an input for a multi-stream CNN based on the image of the companion animal 160 received from the camera 102. The image of the companion animal 160 received from the camera 102 may include a plurality of image clips. Each image clip may be a unit image of a predetermined length. The image data processing unit 110 may label a plurality of image clips included in the image of the companion animal 160. For example, the image data processing unit 110 may label a plurality of image clips based on a temporal parameter and a spatial parameter (ie, according to a temporal parameter and a spatial parameter). The image data set generated by the image data processing unit 110 may include a plurality of such labeled image clips.

영상 데이터 처리부(110)는 영상 데이터 세트를 확장하고, 라벨링된 영상 클립들의 수를 증가시키기 위해, 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터를 추가적인 라벨링된 영상 클립으로서 생성할 수 있다. 따라서, 영상 데이터 세트는 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터를 또한 포함할 수 있다. 플립된 영상 데이터는 예컨대, 라벨링된 복수의 영상 클립들의 각각에 대한 수평 플립(horizontal filpped) 영상 데이터, 수직 플립(vertical) 영상 데이터 및 수평 및 수직 플립(combined filpped) 영상 데이터를 포함할 수 있다. 영상 데이터 처리부(110)는 이러한 플립핑을 수행함으로써 라벨링된 영상 클립의 수를 증가(상기의 예시에서는 4배 증가)시킬 수 있다.The image data processing unit 110 may generate flipped image data for each of a plurality of labeled image clips as an additional labeled image clip in order to expand the image data set and increase the number of labeled image clips. . Thus, the image data set may also include flipped image data for each of a plurality of labeled image clips. The flipped image data may include horizontally flipped image data, vertical flipped image data, and combined horizontal and vertical flipped image data for each of a plurality of labeled image clips. The image data processing unit 110 may increase the number of labeled image clips (in the above example, 4 times) by performing such flipping.

영상 클립에 대한 플립핑에 대해서는 후술될 도 2를 참조하여 더 자세하게 설명된다. Flipping for the image clip will be described in more detail with reference to FIG. 2 to be described later.

영상 데이터 처리부(110)는 라벨링된 복수의 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임을 처리함으로써 처리된 영상 데이터를 생성하여 멀티 스트림 CNN을 위한 입력으로서 제공할 수 있다. The image data processing unit 110 may generate processed image data by processing each image clip of a plurality of labeled image clips or each frame of each image clip and provide it as input for a multi-stream CNN.

예컨대, 영상 데이터 처리부(110)는 제1 영상 데이터에 해당하는 라벨링된 복수의 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임에 대해, 제1 영상 데이터에서 반려 동물(160)을 추적함으로써 반려 동물(160)을 포함하도록 크롭된 제2 영상 데이터를 생성할 수 있다. 또한, 영상 데이터 처리부(110)는 제1 영상 데이터와 연관된 광학 흐름(optical flow) 추출 영상인 제3 영상 데이터를 생성할 수 있다. 또한, 영상 데이터 처리부(110)는 제2 영상 데이터와 연관된 광학 흐름 추출 영상인 제4 영상 데이터를 생성할 수 있다. 이러한, 제1 영상 데이터, 제2 영상 데이터, 제3 영상 데이터 및 제4 영상 데이터는 CNN에 대해 멀티 스트림의 입력 값이 될 수 있다. For example, the image data processing unit 110 tracks the companion animal 160 from the first image data for each image clip of a plurality of labeled image clips corresponding to the first image data or each frame of each image clip. The second image data cropped to include the companion animal 160 may be generated. Also, the image data processing unit 110 may generate third image data that is an image extracted from an optical flow associated with the first image data. Also, the image data processing unit 110 may generate fourth image data that is an optical flow extraction image associated with the second image data. The first image data, the second image data, the third image data, and the fourth image data may be multi-stream input values for the CNN.

영상 데이터 처리부(110)가 제2 영상 데이터, 제3 영상 데이터 및 제4 영상 데이터를 생성하는 보다 자세한 방법에 대해서는 후술될 도 4를 참조하여 더 자세하게 설명된다.A more detailed method of generating the second image data, the third image data, and the fourth image data by the image data processing unit 110 will be described in more detail with reference to FIG. 4 to be described later.

CNN 출력 값 생성부(120)는 영상 데이터 처리부(110)에 의해 생성된 영상 데이터 세트의 각 영상 데이터(예컨대, 전술된 제1 내지 제4 영상 데이터)를 멀티 스트림의 입력 값으로 하는 CNN에 대해 CNN 출력 값을 생성할 수 있다. CNN은 멀티 스트림(multi stream) CNN일 수 있다. CNN은 복수의 CNN들을 나타낼 수 있다. 일례로, 멀티 스트림의 각 영상 데이터는 각각의 CNN의 입력이 될 수 있다. 또한, CNN은 DNN 또는 RNN으로 대체될 수도 있다.The CNN output value generation unit 120 uses the image data (eg, the first to fourth image data described above) of the image data set generated by the image data processing unit 110 as an input value of a multi-stream. CNN output values can be generated. The CNN may be a multi-stream CNN. CNN may represent a plurality of CNNs. As an example, each image data of a multi-stream may be an input of each CNN. In addition, CNN may be replaced with DNN or RNN.

CNN은 반려 동물(160)과 관련된 영상 데이터에 대응하는 영상 데이터(예컨대, 샘플 데이터(학습을 위한 데이터))를 학습함으로써 구축된 것일 수 있다. 학습을 위한 데이터는 외부의 데이터베이스(예컨대, 데이터베이스(104))로부터 획득될 수 있다. CNN의 학습은 서버(100) 내에서 수행되거나, 서버(100)가 아닌 다른 서버 기타 컴퓨팅 장치에 의해 수행되는 것일 수 있다.The CNN may be constructed by learning image data (eg, sample data (data for learning)) corresponding to image data related to the companion animal 160. Data for learning may be obtained from an external database (eg, database 104). Learning of the CNN may be performed within the server 100 or may be performed by a server other than the server 100 and other computing devices.

CNN 출력 값 생성부(120)는, 카메라(102)에 의해 촬영된 연속적인(또는 시계열에 따라 획득되는(sequential)) 반려 동물(160)의 영상에 기반하여 영상 데이터 처리부(110)에 의해 생성된 영상 데이터 세트의 영상 데이터를 입력 값으로 하는 CNN에 대한 CNN 출력 값을 생성할 수 있다. CNN 출력 값은 입력된 영상 데이터의 반려 동물(160)의 움직임에 관한 특징 벡터를 포함하는 것일 수 있다. The CNN output value generation unit 120 is generated by the image data processing unit 110 based on the image of the companion animal 160 photographed by the camera 102 continuously (or acquired according to a time series (sequential)). A CNN output value for a CNN using the image data of the generated image data set as an input value may be generated. The CNN output value may include a feature vector related to the motion of the companion animal 160 of the input image data.

CNN 출력 값 생성부(120)에 의해 생성된 CNN 출력 값은 LSTM에 대한 입력 값이 될 수 있다. LSTM 출력 값 생성부(130)는 이러한 CNN 출력 값을 입력 값으로 하는 LSTM)에 대해 LSTM 출력 값을 생성할 수 있다. LSTM은 복수의 CNN들에 대응하여 복수일 수 있다. 일례로, 멀티 스트림의 각 영상 데이터가 각 CNN의 입력이 되는 경우에 있어서, 각 CNN의 출력 값은 복수의 LSTM들 중 대응하는 LSTM으로 입력되어 LSTM 출력 값이 생성될 수 있다. The CNN output value generated by the CNN output value generator 120 may be an input value for LSTM. The LSTM output value generator 130 may generate an LSTM output value for an LSTM) using the CNN output value as an input value. There may be a plurality of LSTMs corresponding to a plurality of CNNs. As an example, when each image data of a multi-stream is input to each CNN, an output value of each CNN may be input as a corresponding LSTM among a plurality of LSTMs to generate an LSTM output value.

LSTM 출력 값은 입력된 영상 데이터의 반려 동물(160)의 움직임에 관한 특징 벡터를 포함하는 것일 수 있다. 예컨대, LSTM 출력 값은 입력된 특정 영상 데이터와 그 이전(이전 시퀀스)에 입력된 복수의 영상 데이터의 반려 동물(160)의 움직임에 관한 특징 벡터를 포함하는 것일 수 있다.The LSTM output value may include a feature vector related to the motion of the companion animal 160 of the input image data. For example, the LSTM output value may include a feature vector related to the motion of the companion animal 160 of the input specific image data and a plurality of image data input before the (previous sequence).

위험 행동 검출부(140)는 LSTM 출력 값 생성부(130)에 의해 생성된 LSTM 출력 값에 기반하여 반려 동물(160)의 위험 행동을 검출할 수 있다. 일례로, 위험 행동 검출부(140)는 LSTM 출력 값에 기반하여 반려 동물(160)의 활동을 결정할 수 있고 해당 활동을 입력 데이터로서, 입력 데이터를 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로써 반려 동물(160)의 위험 행동을 검출할 수 있다. LSTM 출력 값에 기반하여 검출되는 반려 동물(160)의 활동은 예컨대, 걷기, 서있기, 앉기, 또는 눕기를 포함하는 반려 동물(160)의 자세 활동; 머리 올리기, 머리 내리기 또는 머리 좌우 이동을 포함하는 반려 동물(160)의 머리 움직임 활동; 하울링, 짖기 또는 울기를 포함하는 반려 동물(160)의 음성 활동; 먹기, 물어 뜯기, 땅파기(digging) 또는 점프하기를 포함하는 반려 동물(160)의 움직임 활동; 또는, 배뇨/배설 활동일 수 있다. The dangerous behavior detection unit 140 may detect the dangerous behavior of the companion animal 160 based on the LSTM output value generated by the LSTM output value generation unit 130. As an example, the dangerous behavior detection unit 140 may determine the activity of the companion animal 160 based on the LSTM output value, and use the activity as input data, and the input data using Complex Event Processing (CEP). By analyzing, it is possible to detect the dangerous behavior of the companion animal 160. The activity of the companion animal 160 detected based on the LSTM output value may include, for example, a posture activity of the companion animal 160 including walking, standing, sitting, or lying down; A head movement activity of the companion animal 160 including raising the head, lowering the head, or moving the head left and right; Voice activity of companion animal 160, including howling, barking or crying; Movement activities of the companion animal 160, including eating, biting, digging or jumping; Alternatively, it may be a urination/excretion activity.

위험 행동 검출부(140)는 LSTM 출력 값에 기반하여 반려 동물(160)의 연속적인(시계열에 따른) 활동들을 인식할 수 있고, CEP를 사용하여, 이러한 활동들의 발생 순서 및 발생 빈도나, 특정 패턴의 활동들의 발생 빈도에 기반하여 반려 동물(160)이 위험 행동을 하고 있는지 여부를 결정할 수 있고, 따라서, 반려 동물(160)의 위험 행동을 검출할 수 있다. The dangerous behavior detection unit 140 can recognize the continuous (time series) activities of the companion animal 160 based on the LSTM output value, and by using the CEP, the order and frequency of occurrence of these activities, or a specific pattern. It is possible to determine whether the companion animal 160 is performing dangerous behavior based on the frequency of occurrence of the activities of the companion animal 160, and thus, the dangerous behavior of the companion animal 160 may be detected.

따라서, 카메라(102)를 통해 실시간으로 수집되는 반려 동물(160)의 영상에 기반하여 반려 동물(160)의 위험 행동이 실시간으로 검출 및 모니터링될 수 있다. Accordingly, the dangerous behavior of the companion animal 160 may be detected and monitored in real time based on the image of the companion animal 160 collected in real time through the camera 102.

위험 행동 검출부(140)에 의해 반려 동물(160)의 위험 행동이 있는 것으로 판정된 때, 반려 동물(160)의 위험 행동이 검출되었음을 나타내는 데이터는 사용자 단말(170)로 출력될 수 있다. When it is determined that there is a dangerous behavior of the companion animal 160 by the dangerous behavior detection unit 140, data indicating that the dangerous behavior of the companion animal 160 is detected may be output to the user terminal 170.

사용자 단말(170)는 예컨대, 스마트 폰, PC(personal computer), 노트북 컴퓨터(laptop computer), 랩탑 컴퓨터(laptop computer), 태블릿(tablet), 사물 인터넷(Internet Of Things) 기기, 또는 웨어러블 컴퓨터(wearable computer) 등의 사용자가 사용하는 단말일 수 있다.The user terminal 170 is, for example, a smart phone, a personal computer (PC), a laptop computer, a laptop computer, a tablet, an Internet of Things (Internet Of Things) device, or a wearable computer. computer) may be a terminal used by a user.

사용자 단말(170)은 서버(100)로부터 반려 동물(160)의 위험 행동이 검출되었음을 나타내는 데이터가 수신됨에 따라, 반려인에게 반려 동물(160)에 위험 행동이 발생하였음을 알리기 위한 경보를 발생시키는 경보 발생부(172)를 포함할 수 있다. 경보 발생부(172)는 사용자 단말(170)이 사운드를 출력하도록 하거나, 사용자 단말(170)의 디스플레이에 반려 동물(160)의 위험 행동이 검출되었음을 나타내는 정보를 표시하도록 함으로써 경보를 발생시킬 수 있다. As the user terminal 170 receives data indicating that the dangerous behavior of the companion animal 160 has been detected from the server 100, the user terminal 170 generates an alarm to inform the companion that a dangerous behavior has occurred in the companion animal 160. It may include an alarm generator 172. The alarm generator 172 may generate an alarm by allowing the user terminal 170 to output sound or by displaying information indicating that dangerous behavior of the companion animal 160 is detected on the display of the user terminal 170. .

사용자 단말(170)는 또한 반려 동물(160)의 위험 행동에 대한 조치를 위한 명령을 생성하고, 생성된 명령을 서버(100)로 출력하는 원격 제어부(174)를 더 포함할 수 있다. 상기 명령은 사용자 단말(170)에 대한 반려인의 조작에 따라 생성될 수 있고, 외부 장치(180)를 제어하기 위한 명령일 수 있다.The user terminal 170 may further include a remote control unit 174 for generating a command for action on dangerous behavior of the companion animal 160 and outputting the generated command to the server 100. The command may be generated according to a companion's manipulation of the user terminal 170 and may be a command for controlling the external device 180.

한편, 서버(100)는 사용자 단말(170)에 의해 출력된 명령을 수신하고, 반려 동물(160)의 위험 행동을 해소하기 위한 조치를 수행하기 위한 조치 명령을 생성하고, 조치 명령을 외부 장치(180)로 전송하는 위험 행동 조치부(150)를 더 포함할 수 있다. 위험 행동 조치부(150)로부터의 조치 명령에 따라 외부 장치(180)는 제어될 수 있다. 위험 행동 조치부(150)로부터의 조치 명령은 반려 동물(160)의 위험 행동에 대한 교정적 조치(corrective measure)을 명령하는 것이거나, 예방적 조치(proactive measure)를 명령하는 것일 수 있다. 조치 명령은 이러한 교정적 조치 또는 예방적 조치의 수행을 위한 외부 장치(180)에 대한 제어 명령일 수 있다.On the other hand, the server 100 receives the command output by the user terminal 170, generates an action command for performing an action to eliminate the dangerous behavior of the companion animal 160, and sends the action command to an external device ( It may further include a risk action measures unit 150 transmitted to 180). The external device 180 may be controlled according to an action command from the dangerous action action unit 150. The order of action from the dangerous behavior measure unit 150 may be to order a corrective measure for the dangerous behavior of the companion animal 160 or to order a proactive measure. The action command may be a control command for the external device 180 for performing such a corrective action or a preventive action.

조치 명령에 따라 제어되는 외부 장치(180)는 스피커, TV와 같은 디스플레이 장치 및 먹이 공급 장치 중 적어도 하나를 포함할 수 있다. 예컨대, 조치 명령에 따라 TV(또는 스피커)는 반려 동물(160)의 위험 행동을 해소하기 위해 도움이 되는 오디오 또는 사운드를 출력할 수 있고, 먹이 공급 장치는 반려 동물(160)에게 먹이를 제공할 수 있다. 말하자면, 외부 장치(180)는 위험 행동 조치부(150)로부터의 조치 명령에 따라 반려 동물(160)의 위험 행동을 해소하기 위한 조치를 수행할 수 있다. The external device 180 controlled according to the action command may include at least one of a speaker, a display device such as a TV, and a food supply device. For example, according to an action command, the TV (or speaker) may output audio or sound that is helpful to solve the dangerous behavior of the companion animal 160, and the feeding device may provide food to the companion animal 160. I can. In other words, the external device 180 may perform a measure to eliminate the dangerous behavior of the companion animal 160 in accordance with a measure command from the dangerous behavior measure unit 150.

전술된 서버(100)의 구성들(110 내지 150) 각각은 서버(100)의 프로세서의 일부로서 소프트웨어 및/또는 하드웨어 모듈일 수 있고, 프로세서에 의해 구현되는 기능(기능 블록)을 나타낼 수 있다. 유사하게, 전술된 사용자 단말(170)의 구성들(172 및 174) 각각 또한 사용자 단말(170)의 프로세서의 일부로서 소프트웨어 및/또는 하드웨어 모듈일 수 있고, 프로세서에 의해 구현되는 기능(기능 블록)을 나타낼 수 있다. Each of the components 110 to 150 of the server 100 described above may be a software and/or hardware module as part of the processor of the server 100, and may represent functions (functional blocks) implemented by the processor. Similarly, each of the configurations 172 and 174 of the user terminal 170 described above may also be a software and/or hardware module as part of the processor of the user terminal 170, and functions implemented by the processor (function blocks) Can represent.

한편, 도시되지는 않았으나, 서버(100) 및 사용자 단말(170)은 다른 서버/장치와 정보 및 데이터를 송수신하기 위한 통신부를 더 포함할 수 있다. 전술된 센서 데이터, 명령 및 위험 행동을 나타내는 데이터는 이러한 통신부를 통해 카메라(102), 서버(100) 및 사용자 단말(170)(즉, 이들의 구성들) 사이에서 통신될 수 있다. 정보 및 데이터의 송수신에 사용되는 네트워크는 특별히 제한되지 않으며 일례로, 이동통신망, 유선 인터넷, 무선 인터넷, 방송망 및 위성망을 비롯하여 기기들 간의 근거리 무선 통신 역시 포함할 수 있다.Meanwhile, although not shown, the server 100 and the user terminal 170 may further include a communication unit for transmitting and receiving information and data with other servers/devices. The above-described sensor data, commands, and data representing dangerous behavior may be communicated between the camera 102, the server 100 and the user terminal 170 (ie, components thereof) through this communication unit. A network used for transmitting and receiving information and data is not particularly limited, and for example, may include a mobile communication network, a wired Internet, a wireless Internet, a broadcasting network, and a satellite network, as well as short-range wireless communication between devices.

도 2는 일 예에 따른, 반려 동물의 영상을 처리하여 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 방법을 나타낸다. 2 illustrates a method of generating an image data set for analyzing a companion animal's behavior by processing an image of a companion animal, according to an example.

도시된 영상 데이터(210)는 카메라(102)에 의해 촬영된 반려 동물(160)의 라벨링된 영상 클립(또는 프레임)을 캡쳐한 것이다. 도시된 것처럼, 영상 데이터(210)는 탑-다운 앵글을 갖는 카메라(102)에 의해 촬영된 것일 수 있다. The illustrated image data 210 is a capture of a labeled image clip (or frame) of the companion animal 160 photographed by the camera 102. As shown, the image data 210 may be captured by the camera 102 having a top-down angle.

영상 데이터 처리부(110)는 라벨링된 영상 클립(또는 프레임)을 포함하는 영상 데이터 세트를 확장하고, 라벨링된 영상 클립들의 수를 증가시키기 위해, 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터를 추가적인 라벨링된 영상 클립으로서 생성할 수 있다.The image data processing unit 110 expands an image data set including a labeled image clip (or frame), and flips image data for each of a plurality of labeled image clips to increase the number of labeled image clips. Can be created as additional labeled video clips.

영상 데이터(220)는 영상 데이터(210)가 수평 플립된 것일 수 있다. 영상 데이터(230)는 영상 데이터(210)가 수직 플립된 것일 수 있다. 영상 데이터(240)는 영상 데이터(210)가 수평 및 수직 플립된 것일 수 있다. 영상 데이터 처리부(110)는 이러한 플립핑을 수행함으로써 라벨링된 영상 클립의 수를 4배로 증가시킬 수 있다. 따라서, 영상 클립들에 대한 라벨링 과정에 소요되는 시간 및 자원을 절감하면서 더 많은 라벨링된 영상 클립들이 획득될 수 있다. 이는 보다 정확한 반려 동물(160)의 위험 행동 검출로 이어질 수 있다. The image data 220 may be the image data 210 horizontally flipped. The image data 230 may be the image data 210 vertically flipped. The image data 240 may be obtained by flipping the image data 210 horizontally and vertically. The image data processing unit 110 may increase the number of labeled image clips by four by performing such flipping. Accordingly, more labeled image clips can be obtained while saving time and resources required for the labeling process for the image clips. This may lead to more accurate detection of dangerous behavior of the companion animal 160.

이상, 도 1을 참조하여 전술된 기술적 특징에 대한 설명은, 도 2에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIG. 1 may be applied to FIG. 2 as they are, and thus, overlapping descriptions will be omitted.

도 3은 일 실시예에 따른, 반려 동물의 위험 행동을 검출하기 위한 CNN 출력 값 및 LSTM 출력 값을 생성하는 방법을 나타낸다.3 illustrates a method of generating a CNN output value and an LSTM output value for detecting dangerous behavior of a companion animal, according to an embodiment.

도시된 영상 데이터(310 내지 340)은 도 1을 참조하여 전술된 제1 영상 데이터 내지 제4 영상 데이터에 각각 대응할 수 있다. 말하자면, 영상 데이터(320)는 원본 영상 클립 또는 프레임에 대응하는 영상 데이터(310)에서 반려 동물(160)을 추적함으로써 반려 동물(160)을 포함하도록 영상 데이터(310)를 크롭한 것일 수 있다. 영상 데이터(330)는 영상 데이터(310)의 광학 흐름 추출 영상일 수 있다. 영상 데이터(340)는 영상 데이터(320)의 광학 흐름 추출 영상일 수 있다.The illustrated image data 310 to 340 may respectively correspond to the first to fourth image data described above with reference to FIG. 1. In other words, the image data 320 may be a cropped image data 310 to include the companion animal 160 by tracking the companion animal 160 from the image data 310 corresponding to the original image clip or frame. The image data 330 may be an optical flow extraction image of the image data 310. The image data 340 may be an optical flow extraction image of the image data 320.

영상 데이터(310 내지 340) 각각은 복수의 CNN들(또는 멀티 스트림 CNN)(350) 각각으로 입력될 수 있다. 광학 흐름 추출 영상인 영상 데이터(330 및 340)가 입력되는 CNN은 CNN-T일 수 있다. CNN-T는 Tubelet CNN(T-CNN)일 수 있다. Each of the image data 310 to 340 may be input to each of a plurality of CNNs (or multi-stream CNNs) 350. The CNN to which the image data 330 and 340 which are optical flow extraction images are input may be CNN-T. CNN-T may be Tubelet CNN (T-CNN).

CNN들(350)에 대한 CNN 출력 값은 LSTM(360)의 입력 값이 될 수 있다. MSN은 Multi Stream Network를 의미할 수 있다. LSTM(360)은 도시된 바와 같이 LSTM들로 구성될 수 있다.The CNN output values for the CNNs 350 may be input values of the LSTM 360. MSN may mean Multi Stream Network. The LSTM 360 may be composed of LSTMs as shown.

LSTM(360)에 대한 LSTM 출력 값이 반려 동물(160)의 위험 행동을 검출하기 위해 사용될 수 있다.The LSTM output value for the LSTM 360 may be used to detect the dangerous behavior of the companion animal 160.

이상, 도 1 및 도 2를 참조하여 전술된 기술적 특징에 대한 설명은, 도 3에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 and 2 may be applied to FIG. 3 as they are, and thus redundant descriptions will be omitted.

도 4는 일 예에 따른, 반려 동물의 영상을 처리하여 멀티 스트림 CNN을 위한 입력 영상 데이터를 생성하는 방법을 나타낸다.4 illustrates a method of generating input image data for a multi-stream CNN by processing an image of a companion animal according to an example.

도 4에서는, 도 3을 참조하여 전술된 영상 데이터(310 내지 340)가 생성되는 방법이 보다 자세하게 설명된다. In FIG. 4, a method of generating the image data 310 to 340 described above with reference to FIG. 3 will be described in more detail.

후술될 추적부(410) 및 광학 흐름 추출부(420)는 영상 데이터 처리부(110)의 구성으로서 하드웨어 모듈 및/또는 소프트웨어 모듈로 구현될 수 있다. The tracking unit 410 and the optical flow extracting unit 420 to be described later may be implemented as a hardware module and/or a software module as a configuration of the image data processing unit 110.

추적부(410)는 영상 데이터(310)로부터 반려 동물(160)을 추적할 수 있다. 반려 동물(160)이 추적됨에 따라, 반려 동물(160) 중심으로(target centric) 크롭된 영상 데이터(320)가 생성될 수 있다. 추적부(410)는 다양한 알고리즘, 예컨대, YOLOv3 또는 YOLOv2 알고리즘을 사용하여 영상 데이터(310)에서 반려 동물(160)의 추적을 수행할 수 있다. 도시된 예시에서는, YOLOv3 알고리즘이 사용되었다.The tracking unit 410 may track the companion animal 160 from the image data 310. As the companion animal 160 is tracked, the image data 320 cropped toward the target centric of the companion animal 160 may be generated. The tracking unit 410 may perform tracking of the companion animal 160 on the image data 310 using various algorithms, for example, YOLOv3 or YOLOv2 algorithm. In the illustrated example, the YOLOv3 algorithm was used.

광학 흐름 추출부(420)는 영상 데이터(310) 및 영상 데이터(320)로부터 광학 흐름을 추출함으로써 광학 흐름 추출 영상인 영상 데이터(330) 및 영상 데이터(340)를 생성할 수 있다. 광학 흐름 추출부(420)는 다양한 알고리즘, 예컨대, 추출은 Farneback 알고리즘, Pyflow 알고리즘, EpicFlow 알고리즘 또는 FlowNet 알고리즘을 사용하여 영상 데이터(310) 및 영상 데이터(320)로부터 광학 흐름을 추출함으로써 광학 흐름 추출 영상인 영상 데이터(330) 및 영상 데이터(340)를 생성할 수 있다. 도시된 예시에서는, Pyflow 알고리즘이 사용되었다.The optical flow extractor 420 may generate image data 330 and image data 340 which are optical flow extraction images by extracting an optical flow from the image data 310 and the image data 320. The optical flow extraction unit 420 extracts optical flow from the image data 310 and image data 320 using various algorithms, for example, the Farneback algorithm, the Pyflow algorithm, the EpicFlow algorithm, or the FlowNet algorithm. Phosphorus image data 330 and image data 340 may be generated. In the illustrated example, the Pyflow algorithm was used.

영상 데이터(310 내지 340)는 멀티 스트림 CNN(350)의 입력 값으로서 사용될 수 있다. 멀티 스트림 CNN(350)은 예컨대, AlexNet, ResNet, VGG, 또는 Inception-V1과 같은 모델로 구현될 수 있다. 실시예에서는, 시간, 오류 및 복잡성의 요인을 고려하여 VGG16 모델을 사용하여 멀티 스트림 CNN(350)이 구현되었다.The image data 310 to 340 may be used as an input value of the multi-stream CNN 350. The multi-stream CNN 350 may be implemented with a model such as AlexNet, ResNet, VGG, or Inception-V1, for example. In the embodiment, the multi-stream CNN 350 is implemented using the VGG16 model in consideration of time, error, and complexity factors.

이상, 도 1 내지 도 3을 참조하여 전술된 기술적 특징에 대한 설명은, 도 4에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 to 3 may be applied to FIG. 4 as they are, and thus redundant descriptions will be omitted.

도 5는 일 실시예에 따른, 반려 동물의 영상에 기반하여 반려 동물의 활동을 결정하는 방법을 나타낸다.5 illustrates a method of determining an activity of a companion animal based on an image of the companion animal, according to an exemplary embodiment.

도 5를 참조하여 설명된 반려 동물의 활동을 결정하는 방법은 전술된 영상 데이터 처리부(110), CNN 출력 값 생성부(120) 및 LSTM 출력 값 생성부(130)의 동작에 기반한 반려 동물(160)의 위험 행동 검출 방법에 대해 추가로 또는 대체적으로 수행될 수 있는 반려 동물의 활동을 결정하는 방법에 대해 설명한다.The method of determining the activity of the companion animal described with reference to FIG. 5 is the companion animal 160 based on the operation of the image data processing unit 110, the CNN output value generation unit 120, and the LSTM output value generation unit 130 described above. Describes how to determine the companion animal's activity, which can be performed in addition to or alternatively to the method of detecting dangerous behaviors.

후술될 RGB 데이터 추출부(510) 및 광학 흐름 데이터 추출부(520)는 영상 데이터 처리부(110)의 구성으로서 하드웨어 모듈 및/또는 소프트웨어 모듈로 구현될 수 있다. RGB 데이터 추출부(510)는 전술된 추적부(410) 또는 그 일부로서 구현될 수도 있다. 또한, 광학 흐름 데이터 추출부(520)는 전술된 광학 흐름 추출부(420) 또는 그 일부로서 구현될 수도 있다.The RGB data extracting unit 510 and the optical flow data extracting unit 520 to be described later are components of the image data processing unit 110 and may be implemented as a hardware module and/or a software module. The RGB data extraction unit 510 may be implemented as the above-described tracking unit 410 or a part thereof. In addition, the optical flow data extraction unit 520 may be implemented as the above-described optical flow extraction unit 420 or a part thereof.

한편, 형상 정보 획득부(530), 움직임 정보 획득부(540) 및 활동 결정부(550)는 위험 행동 검출부(140)의 구성으로서 하드웨어 모듈 및/또는 소프트웨어 모듈로 구현될 수 있다.Meanwhile, the shape information acquisition unit 530, the motion information acquisition unit 540, and the activity determination unit 550 may be implemented as a hardware module and/or a software module as components of the dangerous behavior detection unit 140.

영상 데이터(500)는 전술된 카메라(102)에 의해 촬영된 영상이거나, 해당 영상에 기반하여 생성된 영상 데이터 세트이거나, 해당 영상의 라벨링된 클립들 또는 프레임들일 수 있다. The image data 500 may be an image captured by the above-described camera 102, an image data set generated based on the image, or labeled clips or frames of the image.

영상 데이터 처리부(110)의 RGB 데이터 추출부(510)는 반려 동물(160)의 영상(또는 이에 기반하여 생성된 영상 데이터 세트)으로부터 반려 동물(160)의 영상의 RGB 정보를 추출할 수 있다. 영상 데이터 처리부(110)의 광학 흐름 데이터 추출부(520)는 반려 동물(160)의 영상(또는 이에 기반하여 생성된 영상 데이터 세트)으로부터 반려 동물(160)의 영상의 광학 흐름 정보를 추출할 수 있다. The RGB data extraction unit 510 of the image data processing unit 110 may extract RGB information of the image of the companion animal 160 from the image of the companion animal 160 (or an image data set generated based thereon). The optical flow data extraction unit 520 of the image data processing unit 110 may extract optical flow information of the image of the companion animal 160 from the image of the companion animal 160 (or an image data set generated based thereon). have.

위험 행동 검출부(140)의 형상 정보 획득부(530)는 추출된 RGB 정보로부터 반려 동물(160)의 형상 정보를 획득할 수 있다. 한편, 위험 행동 검출부(140)의 움직임 정보 획득부(540)는 추출된 광학 흐름 정보로부터 반려 동물(160)의 움직임 정보를 획득할 수 있다. 위험 행동 검출부(140)의 활동 결정부(550)는 획득된 형상 정보와 움직임 정보에 기반하여 반려 동물(160)의 활동을 결정할 수 있다.The shape information acquisition unit 530 of the dangerous behavior detection unit 140 may obtain shape information of the companion animal 160 from the extracted RGB information. Meanwhile, the motion information acquisition unit 540 of the dangerous behavior detection unit 140 may acquire motion information of the companion animal 160 from the extracted optical flow information. The activity determination unit 550 of the dangerous behavior detection unit 140 may determine the activity of the companion animal 160 based on the acquired shape information and motion information.

일례로, 위험 행동 검출부(140)는 투-스트림(Two-Stream) YOLOv2 알고리즘을 사용하여, RGB 정보로부터 반려 동물(160)의 형상 정보를 획득할 수 있고 광학 흐름 정보로부터 반려 동물(160)의 움직임 정보를 획득할 수 있으며, 획득된 형상 정보 및 움직임 정보에 기반하여 반려 동물(160)의 활동을 결정할 수 있다. As an example, the dangerous behavior detection unit 140 may obtain the shape information of the companion animal 160 from RGB information using a two-stream YOLOv2 algorithm, and the companion animal 160 from the optical flow information Motion information may be acquired, and an activity of the companion animal 160 may be determined based on the acquired shape information and motion information.

결정되는 반려 동물(160)의 활동은 예컨대, 걷기, 서있기, 앉기, 또는 눕기를 포함하는 반려 동물(160)의 자세 활동; 머리 올리기, 머리 내리기 또는 머리 좌우 이동을 포함하는 반려 동물(160)의 머리 움직임 활동; 하울링, 짖기 또는 울기를 포함하는 반려 동물(160)의 음성 활동; 물어 뜯기, 땅파기(digging) 또는 점프하기를 포함하는 반려 동물(160)의 움직임 활동; 또는, 배뇨/배설 활동일 수 있다. 도시된 예시에서는 반려 동물(160)의 '점프하기'가 활동으로서 결정되었다.The determined activity of the companion animal 160 may include, for example, a posture activity of the companion animal 160 including walking, standing, sitting, or lying down; A head movement activity of the companion animal 160 including raising the head, lowering the head, or moving the head left and right; Voice activity of companion animal 160, including howling, barking or crying; Movement activities of the companion animal 160, including biting, digging or jumping; Alternatively, it may be a urination/excretion activity. In the illustrated example,'jumping' of the companion animal 160 was determined as an activity.

이러한 활동의 결정에 있어서는, 전술된 CNN 출력 값 생성부(120) 및 LSTM 출력 값 생성부(130)의 동작이 개입될 수도 있다. 예컨대, 획득된 형상 정보 및 움직임 정보가 CNN에 대한 입력이 되도록 구현될 수도 있다.In determining such an activity, the operations of the CNN output value generation unit 120 and the LSTM output value generation unit 130 described above may be intervened. For example, the obtained shape information and motion information may be implemented to be input to the CNN.

위험 행동 검출부(140)는 결정된 활동을 입력 데이터로서, 입력 데이터를 CEP를 사용하여 분석함으로써 반려 동물(160)의 위험 행동을 검출할 수 있다. 예컨대, 위험 행동 검출부(140)는 결정된 반려 동물(160)의 연속적인(시계열에 따른) 활동들을 인식할 수 있고, CEP를 사용하여, 이러한 활동들의 발생 순서 및 발생 빈도나, 특정 패턴의 활동들의 발생 빈도에 기반하여 반려 동물(160)이 위험 행동을 하고 있는지 여부를 결정할 수 있으며, 따라서, 반려 동물(160)의 위험 행동을 검출할 수 있다. The dangerous behavior detection unit 140 may detect the dangerous behavior of the companion animal 160 by analyzing the determined activity as input data and the input data using CEP. For example, the dangerous behavior detection unit 140 may recognize continuous (time series) activities of the determined companion animal 160, and, using CEP, the order and frequency of occurrence of these activities, or activities of a specific pattern. It is possible to determine whether the companion animal 160 is performing dangerous behavior based on the frequency of occurrence, and thus, the dangerous behavior of the companion animal 160 may be detected.

이상, 도 1 내지 도 4를 참조하여 전술된 기술적 특징에 대한 설명은, 도 5에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 to 4 may be applied to FIG. 5 as they are, and thus redundant descriptions will be omitted.

도 6 및 도 7은 일 예에 따른, 인식된 반려 동물의 활동을 CEP를 사용하여 분석함으로서 반려 동물의 행동을 파악하기 위해 사용되는 코드를 나타낸다.6 and 7 illustrate codes used to grasp the behavior of the companion animal by analyzing the activity of the recognized companion animal using CEP, according to an example.

도 6에서는 결정된 반려 동물(160)의 "걷기" 활동에 대해, 반려 동물(160)의 위험 행동이 검출되는 방법이 도시되었다. 도시된 바와 같이, 반려 동물(160)의 "걷기" 활동이 파악됨에 따라, 반려 동물(160)의 건강을 위해 더 운동이 필요한지 여부가 판정될 수 있다. 이러한 반려 동물(160)이 더 운동이 필요한지 여부는 사용자 단말(170)로 전달되어 경보 생성부(172)에 의해 사용자 단말(170)에서 출력될 수 있다.In FIG. 6, a method of detecting a dangerous behavior of the companion animal 160 with respect to the determined “walking” activity of the companion animal 160 is illustrated. As illustrated, as the “walking” activity of the companion animal 160 is recognized, it may be determined whether further exercise is required for the health of the companion animal 160. Whether the companion animal 160 needs more exercise may be transmitted to the user terminal 170 and output from the user terminal 170 by the alarm generator 172.

도 7에서는 결정된 반려 동물(160)의 "먹기" 활동에 대해, 반려 동물(160)의 위험 행동이 검출되는 방법이 도시되었다. 도시된 바와 같이, 반려 동물(160)의 "먹기" 활동이 파악됨에 따라, 반려 동물(160)의 건강을 위해 더 먹는 것이 필요한지 여부가 판정될 수 있다. 이러한 반려 동물(160)이 더 먹는 것이 필요한지 여부는 사용자 단말(170)로 전달되어 경보 생성부(172)에 의해 사용자 단말(170)에서 출력될 수 있다.In FIG. 7, a method of detecting a dangerous behavior of the companion animal 160 with respect to the determined “eat” activity of the companion animal 160 is illustrated. As shown, as the “eating” activity of the companion animal 160 is recognized, it may be determined whether it is necessary to eat more for the health of the companion animal 160. Whether it is necessary for the companion animal 160 to eat more may be transmitted to the user terminal 170 and output from the user terminal 170 by the alarm generator 172.

이상, 도 1 내지 도 5를 참조하여 전술된 기술적 특징에 대한 설명은, 도 6 및 7에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 to 5 may be applied to FIGS. 6 and 7 as they are, and thus redundant descriptions will be omitted.

도 8은 일 실시예에 따른, 반려 동물의 위험 행동 검출 및 억제 시스템에 의한 반려 동물의 위험 행동의 검출 및 억제 방법을 나타내는 흐름도이다. 8 is a flowchart illustrating a method of detecting and inhibiting dangerous behaviors of companion animals by a system for detecting and suppressing dangerous behaviors of companion animals according to an exemplary embodiment.

단계(810)에서, 영상 데이터 처리부(110)는 카메라(102)에 의해 촬영된 반려 동물(160)의 영상을 처리하여 반려 동물(160)의 행동 분석을 위한 영상 데이터 세트를 생성할 수 있다. In step 810, the image data processing unit 110 may process an image of the companion animal 160 captured by the camera 102 to generate an image data set for analyzing the behavior of the companion animal 160.

단계(820)에서, CNN 출력 값 생성부(120)는 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 CNN에 대해 CNN 출력 값을 생성할 수 있다. In step 820, the CNN output value generator 120 may generate a CNN output value for a CNN using each image data of the image data set as an input value of a multi-stream.

단계(830)에서, LSTM 출력 값 생성부(130)는 CNN 출력 값을 입력 값으로 하는 장단기메모리(Long Short-Term Memory; LSTM)에 대해 LSTM 출력 값을 생성할 수 있다. In step 830, the LSTM output value generation unit 130 may generate an LSTM output value for a long short-term memory (LSTM) using the CNN output value as an input value.

단계(840)에서, 위험 행동 검출부(140)는 LSTM 출력 값에 기반하여 반려 동물(160)의 위험 행동을 검출할 수 있다.In step 840, the dangerous behavior detection unit 140 may detect the dangerous behavior of the companion animal 160 based on the LSTM output value.

단계(850)에서, 위험 행동 검출부(140)는 반려 동물(160)의 위험 행동이 검출되었음을 나타내는 데이터를 사용자 단말(170)로 출력할 수 있다.In step 850, the dangerous behavior detection unit 140 may output data indicating that the dangerous behavior of the companion animal 160 is detected to the user terminal 170.

단계(860)에서, 위험 행동 조치부(150)는 사용자 단말(170)로부터 출력된 명령을 수신할 수 있다. In step 860, the dangerous action action unit 150 may receive a command output from the user terminal 170.

단계(870)에서, 위험 행동 조치부(150)는 수신된 명령에 따라 반려 동물(160)의 위험 행동을 해소하기 위한 조치를 수행하기 위한 조치 명령을 생성할 수 있다. In step 870, the dangerous action action unit 150 may generate an action command for performing an action for resolving the dangerous action of the companion animal 160 according to the received command.

단계(880)에서, 위험 행동 조치부(150)는 생성된 조치 명령을 적어도 하나의 외부 장치(180)로 전송할 수 있다. 외부 장치(180)는 위험 행동 조치부(150)로부터의 조치 명령에 따라 반려 동물(260)의 위험 행동을 해소하기 위한 조치를 수행할 수 있다. In step 880, the dangerous action action unit 150 may transmit the generated action command to at least one external device 180. The external device 180 may perform a measure for resolving the dangerous behavior of the companion animal 260 in accordance with a measure command from the dangerous behavior measure unit 150.

이상, 도 1 내지 도 7을 참조하여 전술된 기술적 특징에 대한 설명은, 도 8에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 to 7 may be applied to FIG. 8 as they are, and thus redundant descriptions will be omitted.

도 9는 일 예에 따른, 반려 동물의 영상을 처리하여 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 방법을 나타내는 흐름도이다.9 is a flowchart illustrating a method of generating an image data set for analyzing a companion animal's behavior by processing an image of a companion animal, according to an example.

도 9를 참조하여, 반려 동물(160)의 위험 행동 검출을 위해 사용되는 영상 데이터 세트를 생성하는 방법을 더 자세하게 설명한다. Referring to FIG. 9, a method of generating an image data set used to detect dangerous behavior of the companion animal 160 will be described in more detail.

단계(910)에서, 영상 데이터 처리부(110)는 반려 동물(160)의 영상이 포함하는 복수의 영상 클립들을 시간 파라미터 및 공간 파라미터에 기반하여 라벨링할 수 있다. In step 910, the image data processing unit 110 may label a plurality of image clips included in the image of the companion animal 160 based on a temporal parameter and a spatial parameter.

단계(920)에서, 영상 데이터 처리부(110)는 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터를 추가적인 라벨링된 영상 클립으로서 생성할 수 있다. 따라서, 반려 동물(160)의 위험 행동 검출을 위해 사용되는 영상 데이터 세트는 플립된 영상 데이터를 포함하게 된다. In step 920, the image data processing unit 110 may generate flipped image data for each of a plurality of labeled image clips as an additionally labeled image clip. Accordingly, the image data set used to detect dangerous behavior of the companion animal 160 includes flipped image data.

플립된 영상 데이터는 예컨대, 라벨링된 복수의 영상 클립들의 각각에 대한 수평 플립 영상 데이터, 수직 플립 영상 데이터 및 수평 및 수직 플립 영상 데이터를 포함할 수 있다. 영상 데이터 처리부(110)는 이러한 플립핑을 수행함으로써 라벨링된 영상 클립의 수를 증가시킬 수 있다.The flipped image data may include horizontal flip image data, vertical flip image data, and horizontal and vertical flip image data for each of a plurality of labeled image clips. The image data processing unit 110 may increase the number of labeled image clips by performing such flipping.

이상, 도 1 내지 도 8을 참조하여 전술된 기술적 특징에 대한 설명은, 도 9에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 to 8 may be applied to FIG. 9 as they are, and thus redundant descriptions will be omitted.

도 10은 일 예에 따른, 반려 동물의 영상을 처리하여 멀티 스트림 CNN을 위한 입력 값이 되는 영상 데이터를 생성하는 방법을 나타내는 흐름도이다.10 is a flowchart illustrating a method of generating image data serving as an input value for a multi-stream CNN by processing an image of a companion animal, according to an example.

도 10을 참조하여, 반려 동물(160)의 위험 행동 검출을 위해 사용되는 멀티 스트림 CNN의 입력 값으로의 영상 데이터를 생성하는 방법에 대해 더 자세하게 설명된다. With reference to FIG. 10, a method of generating image data as an input value of a multi-stream CNN used to detect dangerous behavior of the companion animal 160 will be described in more detail.

단계(1010)에서, 영상 데이터 처리부(110)는 제1 영상 데이터에 해당하는 라벨링된 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임에 대해, 상기 제1 영상 데이터에서 반려 동물(160)을 추적함으로써 반려 동물(160)을 포함하도록 크롭된 영상인 제2 영상 데이터를 생성할 수 있다. 반려 동물(160)의 추적에는 YOLOv3 알고리즘이 사용될 수 있다. In step 1010, the image data processing unit 110 determines the companion animal 160 from the first image data for each image clip of the labeled image clips corresponding to the first image data or each frame of each image clip. The second image data, which is an image cropped to include the companion animal 160, may be generated by tracking. The YOLOv3 algorithm may be used to track the companion animal 160.

단계(1020)에서, 영상 데이터 처리부(110)는 제1 영상 데이터와 연관된 광학 흐름(optical flow) 추출 영상인 제3 영상 데이터를 생성할 수 있다. In step 1020, the image data processing unit 110 may generate third image data that is an image extracted from an optical flow associated with the first image data.

단계(1030)에서, 영상 데이터 처리부(110)는 제2 영상 데이터와 연관된 광학 흐름 추출 영상인 제4 영상 데이터를 생성할 수 있다. In step 1030, the image data processing unit 110 may generate fourth image data, which is an optical flow extraction image associated with the second image data.

광학 흐름의 추출에는 Pyflow 알고리즘이 사용될 수 있다. Pyflow algorithm can be used for optical flow extraction.

단계들(1010 내지 1030)에 의한 제1 영상 데이터 내지 제4 영상 데이터는 멀티 스트림 CNN을 위한 입력 값이 될 수 있다. The first to fourth image data according to steps 1010 to 1030 may be input values for a multi-stream CNN.

이상, 도 1 내지 도 9를 참조하여 전술된 기술적 특징에 대한 설명은, 도 10에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.As described above, the description of the technical features described above with reference to FIGS. 1 to 9 may be applied to FIG. 10 as it is, and thus a duplicate description will be omitted.

도 11은 일 실시예에 따른, 반려 동물의 영상에 기반하여 반려 동물의 활동을 결정하는 방법을 나타내는 흐름도이다.11 is a flowchart illustrating a method of determining an activity of a companion animal based on an image of the companion animal, according to an exemplary embodiment.

도 1에서는, 도 5를 참조하여 전술된 반려 동물의 활동을 결정하는 방법이 더 자세하게 설명된다.In FIG. 1, a method of determining an activity of a companion animal described above with reference to FIG. 5 will be described in more detail.

후술될 단계들(1110 내지 1140)은 도 8을 참조하여 전술된 단계들(810 내지 840)에 대해 추가로(및 보조적으로) 또는 대체적으로 수행될 수 있다.Steps 1110 to 1140 to be described later may be additionally (and auxiliary) or alternatively performed with respect to the steps 810 to 840 described above with reference to FIG. 8.

단계(1110)에서, 영상 데이터 처리부(110)는 반려 동물(160)의 영상으로부터 상기 영상의 RGB 정보 및 광학 흐름 정보를 추출할 수 있다. 단계(1110)에서의 추출 대상이되는 반려 동물(160)의 영상은 전술된 카메라(102)에 의해 촬영된 영상이거나, 해당 영상에 기반하여 생성된 영상 데이터 세트이거나, 해당 영상의 라벨링된 클립들 또는 프레임들일 수 있다.In step 1110, the image data processing unit 110 may extract RGB information and optical flow information of the image from the image of the companion animal 160. The image of the companion animal 160 to be extracted in step 1110 is an image captured by the above-described camera 102, an image data set generated based on the image, or labeled clips of the image Or frames.

단계(1120)에서, 위험 행동 검출부(140)는 예컨대, 투-스트림(Two-Stream) YOLOv2 알고리즘을 사용하여, 단계(1110)에서 추출된 RGB 정보로부터 반려 동물(160)의 형상 정보를 획득할 수 있고, 단계(1110)에서 추출된 광학 흐름 정보로부터 반려 동물(160)의 움직임 정보를 획득할 수 있다.In step 1120, the dangerous behavior detection unit 140 uses, for example, a two-stream YOLOv2 algorithm to obtain shape information of the companion animal 160 from the RGB information extracted in step 1110. In addition, motion information of the companion animal 160 may be obtained from the optical flow information extracted in step 1110.

단계(1130)에서, 위험 행동 검출부(140)는 획득된 형상 정보 및 움직임 정보에 기반하여 반려 동물(160)의 활동을 결정할 수 있다. 활동은 도 5를 참조하여 예시된 바와 같을 수 있다. In step 1130, the dangerous behavior detection unit 140 may determine the activity of the companion animal 160 based on the acquired shape information and motion information. The activity may be as illustrated with reference to FIG. 5.

단계(1130)에서, 위험 행동 검출부(140)는 상기 결정된 활동을 입력 데이터로서, 해당 입력 데이터를 CEP를 사용하여 분석함으로써 반려 동물의 위험 행동을 검출할 수 있다. 예컨대, 위험 행동 검출부(140)는 결정된 반려 동물(160)의 연속적인(시계열에 따른) 활동들을 인식할 수 있고, CEP를 사용하여, 이러한 활동들의 발생 순서 및 발생 빈도나, 특정 패턴의 활동들의 발생 빈도에 기반하여 반려 동물(160)이 위험 행동을 하고 있는지 여부를 결정할 수 있고, 따라서, 반려 동물(160)의 위험 행동을 검출할 수 있다. In step 1130, the dangerous behavior detection unit 140 may detect the dangerous behavior of the companion animal by analyzing the determined activity as input data and analyzing the input data using the CEP. For example, the dangerous behavior detection unit 140 may recognize continuous (time-series) activities of the determined companion animal 160, and, using the CEP, the order and frequency of occurrence of these activities, Based on the frequency of occurrence, it is possible to determine whether the companion animal 160 is performing dangerous behavior, and thus, the dangerous behavior of the companion animal 160 may be detected.

이상, 도 1 내지 도 10을 참조하여 전술된 기술적 특징에 대한 설명은, 도 11에 대해서도 그대로 적용될 수 있으므로 중복되는 설명은 생략한다.In the above, descriptions of the technical features described above with reference to FIGS. 1 to 10 may be applied to FIG. 11 as they are, and thus, overlapping descriptions are omitted.

아래 표 1에서는, 반려 동물(160)의 행동 분석을 위한 영상 데이터 세트의 일 예를 도시한다.In Table 1 below, an example of an image data set for behavior analysis of the companion animal 160 is shown.

[표 1] [Table 1]

Figure 112018111081544-pat00001
Figure 112018111081544-pat00001

아래에서는, 영상 클립의 라벨링의 예시가 도시되었다. 라벨링에는 ViTBAT 소프트웨어가 사용되었다. 아래 표 2는 공간적 파라미터에 따른 라벨링을, 표 3은 시간적 파라미터에 따른 라벨링을 나타낸다. Below, an example of labeling of video clips is shown. ViTBAT software was used for labeling. Table 2 below shows labeling according to spatial parameters, and Table 3 shows labeling according to temporal parameters.

[표 2][Table 2]

Figure 112018111081544-pat00002
Figure 112018111081544-pat00002

[표 3][Table 3]

Figure 112018111081544-pat00003
Figure 112018111081544-pat00003

이상에서 설명된 장치는 하드웨어 구성요소, 소프트웨어 구성요소, 및/또는 하드웨어 구성요소 및 소프트웨어 구성요소의 조합으로 구현될 수 있다. 예를 들어, 실시예들에서 설명된 장치 및 구성요소는, 예를 들어, 프로세서, 콘트롤러, ALU(arithmetic logic unit), 디지털 신호 프로세서(digital signal processor), 마이크로컴퓨터, FPA(field programmable array), PLU(programmable logic unit), 마이크로프로세서, 또는 명령(instruction)을 실행하고 응답할 수 있는 다른 어떠한 장치와 같이, 하나 이상의 범용 컴퓨터 또는 특수 목적 컴퓨터를 이용하여 구현될 수 있다. 처리 장치는 운영 체제(OS) 및 상기 운영 체제 상에서 수행되는 하나 이상의 소프트웨어 애플리케이션을 수행할 수 있다. 또한, 처리 장치는 소프트웨어의 실행에 응답하여, 데이터를 접근, 저장, 조작, 처리 및 생성할 수도 있다. 이해의 편의를 위하여, 처리 장치는 하나가 사용되는 것으로 설명된 경우도 있지만, 해당 기술분야에서 통상의 지식을 가진 자는, 처리 장치가 복수 개의 처리 요소(processing element) 및/또는 복수 유형의 처리 요소를 포함할 수 있음을 알 수 있다. 예를 들어, 처리 장치는 복수 개의 프로세서 또는 하나의 프로세서 및 하나의 콘트롤러를 포함할 수 있다. 또한, 병렬 프로세서(parallel processor)와 같은, 다른 처리 구성(processing configuration)도 가능하다.The apparatus described above may be implemented as a hardware component, a software component, and/or a combination of a hardware component and a software component. For example, the devices and components described in the embodiments include, for example, a processor, a controller, an arithmetic logic unit (ALU), a digital signal processor, a microcomputer, a field programmable array (FPA), It may be implemented using one or more general purpose computers or special purpose computers, such as a programmable logic unit (PLU), a microprocessor, or any other device capable of executing and responding to instructions. The processing device may execute an operating system (OS) and one or more software applications executed on the operating system. In addition, the processing device may access, store, manipulate, process, and generate data in response to the execution of software. For the convenience of understanding, although it is sometimes described that one processing device is used, one of ordinary skill in the art, the processing device is a plurality of processing elements and/or a plurality of types of processing elements. It can be seen that it may include. For example, the processing device may include a plurality of processors or one processor and one controller. In addition, other processing configurations are possible, such as a parallel processor.

소프트웨어는 컴퓨터 프로그램(computer program), 코드(code), 명령(instruction), 또는 이들 중 하나 이상의 조합을 포함할 수 있으며, 원하는 대로 동작하도록 처리 장치를 구성하거나 독립적으로 또는 결합적으로(collectively) 처리 장치를 명령할 수 있다. 소프트웨어 및/또는 데이터는, 처리 장치에 의하여 해석되거나 처리 장치에 명령 또는 데이터를 제공하기 위하여, 어떤 유형의 기계, 구성요소(component), 물리적 장치, 가상 장치(virtual equipment), 컴퓨터 저장 매체 또는 장치, 또는 전송되는 신호 파(signal wave)에 영구적으로, 또는 일시적으로 구체화(embody)될 수 있다. 소프트웨어는 네트워크로 연결된 컴퓨터 시스템 상에 분산되어서, 분산된 방법으로 저장되거나 실행될 수도 있다. 소프트웨어 및 데이터는 하나 이상의 컴퓨터 판독 가능 기록 매체에 저장될 수 있다.The software may include a computer program, code, instructions, or a combination of one or more of these, configuring the processing unit to behave as desired or processed independently or collectively. You can command the device. Software and/or data may be interpreted by a processing device or to provide instructions or data to a processing device, of any type of machine, component, physical device, virtual equipment, computer storage medium or device. , Or may be permanently or temporarily embodyed in a transmitted signal wave. The software may be distributed over networked computer systems and stored or executed in a distributed manner. Software and data may be stored on one or more computer-readable recording media.

실시예에 따른 방법은 다양한 컴퓨터 수단을 통하여 수행될 수 있는 프로그램 명령 형태로 구현되어 컴퓨터 판독 가능 매체에 기록될 수 있다. 상기 컴퓨터 판독 가능 매체는 프로그램 명령, 데이터 파일, 데이터 구조 등을 단독으로 또는 조합하여 포함할 수 있다. 상기 매체에 기록되는 프로그램 명령은 실시예를 위하여 특별히 설계되고 구성된 것들이거나 컴퓨터 소프트웨어 당업자에게 공지되어 사용 가능한 것일 수도 있다. 컴퓨터 판독 가능 기록 매체의 예에는 하드 디스크, 플로피 디스크 및 자기 테이프와 같은 자기 매체(magnetic media), CD-ROM, DVD와 같은 광기록 매체(optical media), 플롭티컬 디스크(floptical disk)와 같은 자기-광 매체(magneto-optical media), 및 롬(ROM), 램(RAM), 플래시 메모리 등과 같은 프로그램 명령을 저장하고 수행하도록 특별히 구성된 하드웨어 장치가 포함된다. 프로그램 명령의 예에는 컴파일러에 의해 만들어지는 것과 같은 기계어 코드뿐만 아니라 인터프리터 등을 사용해서 컴퓨터에 의해서 실행될 수 있는 고급 언어 코드를 포함한다. 상기된 하드웨어 장치는 실시예의 동작을 수행하기 위해 하나 이상의 소프트웨어 모듈로서 작동하도록 구성될 수 있으며, 그 역도 마찬가지이다.The method according to the embodiment may be implemented in the form of program instructions that can be executed through various computer means and recorded in a computer-readable medium. The computer-readable medium may include program instructions, data files, data structures, and the like alone or in combination. The program instructions recorded on the medium may be specially designed and configured for the embodiment, or may be known and usable to those skilled in computer software. Examples of computer-readable recording media include magnetic media such as hard disks, floppy disks, and magnetic tapes, optical media such as CD-ROMs and DVDs, and magnetic media such as floptical disks. -A hardware device specially configured to store and execute program instructions such as magneto-optical media, and ROM, RAM, flash memory, and the like. Examples of the program instructions include not only machine language codes such as those produced by a compiler, but also high-level language codes that can be executed by a computer using an interpreter or the like. The hardware device described above may be configured to operate as one or more software modules to perform the operation of the embodiment, and vice versa.

이상과 같이 실시예들이 비록 한정된 실시예와 도면에 의해 설명되었으나, 해당 기술분야에서 통상의 지식을 가진 자라면 상기의 기재로부터 다양한 수정 및 변형이 가능하다. 예를 들어, 설명된 기술들이 설명된 방법과 다른 순서로 수행되거나, 및/또는 설명된 시스템, 구조, 장치, 회로 등의 구성요소들이 설명된 방법과 다른 형태로 결합 또는 조합되거나, 다른 구성요소 또는 균등물에 의하여 대치되거나 치환되더라도 적절한 결과가 달성될 수 있다.As described above, although the embodiments have been described by the limited embodiments and drawings, various modifications and variations are possible from the above description by those of ordinary skill in the art. For example, the described techniques are performed in a different order from the described method, and/or components such as a system, structure, device, circuit, etc. described are combined or combined in a form different from the described method, or other components Alternatively, even if substituted or substituted by an equivalent, an appropriate result can be achieved.

Claims (10)

카메라에 의해 촬영된 반려 동물의 영상을 처리하여 상기 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 영상 데이터 처리부;
상기 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 콘볼루션 신경망(Convolutional Neural Network; CNN)에 대해 CNN 출력 값을 생성하는 CNN 출력 값 생성부;
상기 CNN 출력 값을 입력 값으로 하는 장단기메모리(Long Short-Term Memory; LSTM)에 대해 LSTM 출력 값을 생성하는 LSTM 출력 값 생성부; 및
상기 LSTM 출력 값에 기반하여 상기 반려 동물의 위험 행동을 검출하는 위험 행동 검출부
를 포함하고,
상기 영상 데이터 처리부는 상기 반려 동물의 영상이 포함하는 복수의 영상 클립들을 시간 파라미터 및 공간 파라미터에 기반하여 라벨링하고,
상기 영상 데이터 세트는 상기 라벨링된 복수의 영상 클립들을 포함하고,
상기 영상 데이터 세트는 상기 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터로서 상기 라벨링된 복수의 영상 클립들의 각각에 대한 수평 플립(horizontal filpped) 영상 데이터, 수직 플립(vertical) 영상 데이터 및 수평 및 수직 플립(combined filpped) 영상 데이터를 각각 추가적인 라벨링된 영상 클립으로서 더 포함하고,
상기 영상 데이터 처리부는 제1 영상 데이터에 해당하는 상기 라벨링된 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임에 대해,
상기 제1 영상 데이터에서 상기 반려 동물을 추적함으로써 상기 반려 동물을 포함하도록 크롭된 제2 영상 데이터를 생성하고,
상기 제1 영상 데이터와 연관된 광학 흐름(optical flow) 추출 영상인 제3 영상 데이터를 생성하고,
상기 제2 영상 데이터와 연관된 광학 흐름 추출 영상인 제4 영상 데이터를 생성하고,
상기 제1 영상 데이터, 상기 제2 영상 데이터, 상기 제3 영상 데이터 및 상기 제4 영상 데이터가 상기 CNN에 대해 멀티 스트림의 입력 값이 되는, 반려 동물의 위험 행동 검출 및 억제 시스템.
An image data processing unit for processing an image of a companion animal captured by a camera to generate an image data set for analyzing the companion animal's behavior;
A CNN output value generator for generating a CNN output value for a convolutional neural network (CNN) using each image data of the image data set as an input value of a multi-stream;
An LSTM output value generator for generating an LSTM output value for a long short-term memory (LSTM) using the CNN output value as an input value; And
Dangerous behavior detection unit for detecting the dangerous behavior of the companion animal based on the LSTM output value
Including,
The image data processing unit labels a plurality of image clips included in the image of the companion animal based on a temporal parameter and a spatial parameter,
The image data set includes the labeled plurality of image clips,
The image data set is flipped image data for each of the plurality of labeled image clips, and horizontally flipped image data, vertical flipped image data, and horizontal image data for each of the labeled plurality of image clips. And vertical flipped (combined filpped) image data, respectively, as additional labeled image clips,
The image data processing unit for each image clip of the labeled image clips corresponding to the first image data or each frame of each image clip,
Generating second image data cropped to include the companion animal by tracking the companion animal from the first image data,
Generating third image data that is an optical flow extracted image associated with the first image data,
Generating fourth image data, which is an optical flow extraction image associated with the second image data,
The first image data, the second image data, the third image data, and the fourth image data are multi-stream input values for the CNN.
삭제delete 삭제delete 제1항에 있어서,
상기 제2 영상 데이터를 생성에 있어서의 상기 반려 동물의 추적은 YOLOv3 또는 YOLOv2 알고리즘을 사용하여 수행되고,
상기 제3 영상 데이터 및 상기 제4 영상 데이터를 생성함에 있어서의 광학 흐름 추출은 Farneback 알고리즘, Pyflow 알고리즘, EpicFlow 알고리즘 또는 FlowNet 알고리즘을 사용하여 수행되고,
상기 CNN은 VGG16 모델을 사용하여 구현된 것인, 반려 동물의 위험 행동 검출 및 억제 시스템.
The method of claim 1,
The tracking of the companion animal in generating the second image data is performed using a YOLOv3 or YOLOv2 algorithm,
Optical flow extraction in generating the third image data and the fourth image data is performed using a Farneback algorithm, a Pyflow algorithm, an EpicFlow algorithm, or a FlowNet algorithm,
The CNN is implemented using the VGG16 model, a dangerous behavior detection and inhibition system of companion animals.
제1항에 있어서,
상기 카메라에 의해 촬영된 반려 동물의 영상은 탑-다운(top-down) 앵글을 갖는 카메라에 의해 촬영된 것이고,
상기 반려 동물의 영상은 공간 내에 혼자 있는 상기 반려 동물의 영상인, 반려 동물의 위험 행동 검출 및 억제 시스템.
The method of claim 1,
The image of the companion animal photographed by the camera was photographed by a camera having a top-down angle,
The image of the companion animal is an image of the companion animal alone in the space, a dangerous behavior detection and suppression system of the companion animal.
제1항에 있어서,
상기 위험 행동 검출부는 상기 LSTM 출력 값에 기반하여 상기 반려 동물의 활동을 결정하고 상기 활동을 입력 데이터로서, 상기 입력 데이터를 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로써 상기 반려 동물의 위험 행동을 검출하는, 반려 동물의 위험 행동 검출 및 억제 시스템.
The method of claim 1,
The dangerous behavior detection unit determines the activity of the companion animal based on the LSTM output value, uses the activity as input data, and analyzes the input data using Complex Event Processing (CEP). Hazardous behavior detection and suppression system of companion animals to detect dangerous behavior.
제1항에 있어서,
상기 위험 행동 검출부에 의한 검출에 따라, 상기 반려 동물의 위험 행동이 검출되었음을 나타내는 데이터는 사용자 단말로 출력되고,
상기 사용자 단말을 통해 수신된 명령에 따라 상기 반려 동물의 위험 행동을 해소하기 위한 조치를 수행하기 위한 조치 명령을 생성하고, 상기 조치 명령을 적어도 하나의 외부 장치로 전송하는 위험 행동 조치부
를 더 포함하는, 반려 동물의 위험 행동 검출 및 억제 시스템.
The method of claim 1,
According to the detection by the dangerous behavior detection unit, data indicating that the dangerous behavior of the companion animal is detected is output to the user terminal,
A dangerous action action unit that generates an action command for performing action to eliminate the dangerous action of the companion animal according to the command received through the user terminal, and transmits the action command to at least one external device
A system for detecting and inhibiting dangerous behavior of companion animals further comprising a.
제1항에 있어서,
상기 위험 행동 검출부는, 투-스트림(Two-Stream) YOLOv2 알고리즘을 사용하여, 상기 라벨링된 영상 클립들로부터의 RGB 정보로부터 상기 반려 동물의 형상 정보를 획득하고, 상기 라벨링된 영상 클립들로부터의 광학 흐름 정보로부터 상기 반려 동물의 움직임 정보를 획득함으로써, 상기 형상 정보 및 상기 움직임 정보에 기반하여 상기 반려 동물의 활동을 결정하는, 반려 동물의 위험 행동 검출 및 억제 시스템.
The method of claim 1,
The dangerous behavior detection unit uses a two-stream YOLOv2 algorithm to obtain shape information of the companion animal from RGB information from the labeled image clips, and optical data from the labeled image clips. By acquiring motion information of the companion animal from flow information, an activity of the companion animal is determined based on the shape information and the motion information.
제8항에 있어서,
상기 위험 행동 검출부는 상기 결정된 활동을 입력 데이터로서, 상기 입력 데이터를 복잡 이벤트 처리(Complex Event Processing; CEP)를 사용하여 분석함으로써 상기 반려 동물의 위험 행동을 검출하는, 반려 동물의 위험 행동 검출 및 억제 시스템.
The method of claim 8,
The dangerous behavior detection unit detects and suppresses dangerous behavior of the companion animal by analyzing the determined activity as input data and analyzing the input data using Complex Event Processing (CEP). system.
컴퓨터에 의해 수행되는 반려 동물의 위험 행동의 검출 및 억제 방법에 있어서,
카메라에 의해 촬영된 반려 동물의 영상을 처리하여 상기 반려 동물의 행동 분석을 위한 영상 데이터 세트를 생성하는 단계;
상기 영상 데이터 세트의 각 영상 데이터를 멀티 스트림의 입력 값으로 하는 콘볼루션 신경망(Convolutional Neural Network; CNN)에 대해 CNN 출력 값을 생성하는 단계;
상기 CNN 출력 값을 입력 값으로 하는 장단기메모리(Long Short-Term Memory; LSTM)에 대해 LSTM 출력 값을 생성하는 단계; 및
상기 LSTM 출력 값에 기반하여 상기 반려 동물의 위험 행동을 검출하는 단계
를 포함하고,
상기 영상 데이터 세트를 생성하는 단계는,
상기 반려 동물의 영상이 포함하는 복수의 영상 클립들을 시간 파라미터 및 공간 파라미터에 기반하여 라벨링하는 단계; 및
상기 라벨링된 복수의 영상 클립들 각각에 대한 플립된 영상 데이터로서 상기 라벨링된 복수의 영상 클립들의 각각에 대한 수평 플립(horizontal filpped) 영상 데이터, 수직 플립(vertical) 영상 데이터 및 수평 및 수직 플립(combined filpped) 영상 데이터를 플립된 영상 데이터를 각각 추가적인 라벨링된 영상 클립으로서 더 생성하는 단계
를 포함하고,
상기 영상 데이터 세트를 생성하는 단계는,
제1 영상 데이터에 해당하는 상기 라벨링된 영상 클립들의 각 영상 클립 또는 상기 각 영상 클립의 각 프레임에 대해,
상기 제1 영상 데이터에서 상기 반려 동물을 추적함으로써 상기 반려 동물을 포함하도록 크롭된 영상인 제2 영상 데이터를 생성하는 단계;
상기 제1 영상 데이터와 연관된 광학 흐름(optical flow) 추출 영상인 제3 영상 데이터를 생성하는 단계; 및
상기 제2 영상 데이터와 연관된 광학 흐름 추출 영상인 제4 영상 데이터를 생성하는 단계
를 포함하고,
상기 제1 영상 데이터, 상기 제2 영상 데이터, 상기 제3 영상 데이터 및 상기 제4 영상 데이터가 상기 CNN에 대해 멀티 스트림의 입력 값이 되는, 반려 동물의 위험 행동의 검출 및 억제 방법.
In the detection and suppression method of dangerous behavior of companion animals performed by a computer,
Generating an image data set for analyzing the behavior of the companion animal by processing the image of the companion animal captured by the camera;
Generating a CNN output value for a convolutional neural network (CNN) using each image data of the image data set as an input value of a multi-stream;
Generating an LSTM output value for a long short-term memory (LSTM) using the CNN output value as an input value; And
Detecting dangerous behavior of the companion animal based on the LSTM output value
Including,
Generating the image data set,
Labeling a plurality of image clips included in the image of the companion animal based on a temporal parameter and a spatial parameter; And
As flipped image data for each of the labeled plurality of image clips, horizontally flipped image data, vertical flipped image data, and horizontal and vertical flipped image data for each of the labeled plurality of image clips filpped) further generating flipped image data of image data as additionally labeled image clips
Including,
Generating the image data set,
For each video clip of the labeled video clips corresponding to the first video data or each frame of each video clip,
Generating second image data which is an image cropped to include the companion animal by tracking the companion animal from the first image data;
Generating third image data that is an optical flow extraction image associated with the first image data; And
Generating fourth image data that is an optical flow extraction image associated with the second image data
Including,
The first image data, the second image data, the third image data, and the fourth image data are multi-stream input values for the CNN.
KR1020180136789A 2018-11-08 2018-11-08 Method and automated camera-based system for detecting and suppressing harmful behavior of pet Active KR102156279B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020180136789A KR102156279B1 (en) 2018-11-08 2018-11-08 Method and automated camera-based system for detecting and suppressing harmful behavior of pet

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020180136789A KR102156279B1 (en) 2018-11-08 2018-11-08 Method and automated camera-based system for detecting and suppressing harmful behavior of pet

Publications (2)

Publication Number Publication Date
KR20200055821A KR20200055821A (en) 2020-05-22
KR102156279B1 true KR102156279B1 (en) 2020-09-15

Family

ID=70913900

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020180136789A Active KR102156279B1 (en) 2018-11-08 2018-11-08 Method and automated camera-based system for detecting and suppressing harmful behavior of pet

Country Status (1)

Country Link
KR (1) KR102156279B1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102832889B1 (en) 2022-06-29 2025-07-11 고려대학교 세종산학협력단 Multi-level Hierarchical Complex Behavior Monitoring Method and System for Dog Psychological Separation Anxiety Symptoms

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102327354B1 (en) * 2020-01-14 2021-11-17 고려대학교 세종산학협력단 Cat behavior analysis system using location and behavior information
KR102559688B1 (en) * 2021-02-09 2023-07-25 성균관대학교산학협력단 Behavior estimation device for an emotional support animal and its operation method
KR102527208B1 (en) * 2022-09-13 2023-04-28 주식회사 서랩 Convergence device for pets management service, and convergence system usiing the same

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130046725A1 (en) * 2011-08-15 2013-02-21 Software Ag Systems and/or methods for forecasting future behavior of event streams in complex event processing (cep) environments
KR101876433B1 (en) * 2017-07-20 2018-07-13 주식회사 이고비드 Activity recognition-based automatic resolution adjustment camera system, activity recognition-based automatic resolution adjustment method and automatic activity recognition method of camera system
KR101876491B1 (en) * 2016-03-09 2018-07-13 워크브레인(주) Apparatus for pet management

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100455286B1 (en) * 2002-01-11 2004-11-06 삼성전자주식회사 Method and apparatus for understanding the condition of animal using acquisition and analysis of physiological signal of the animal
KR101713198B1 (en) * 2015-02-09 2017-03-09 주식회사 디바이스넷 Apparatus and method for managing companion animals

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130046725A1 (en) * 2011-08-15 2013-02-21 Software Ag Systems and/or methods for forecasting future behavior of event streams in complex event processing (cep) environments
KR101876491B1 (en) * 2016-03-09 2018-07-13 워크브레인(주) Apparatus for pet management
KR101876433B1 (en) * 2017-07-20 2018-07-13 주식회사 이고비드 Activity recognition-based automatic resolution adjustment camera system, activity recognition-based automatic resolution adjustment method and automatic activity recognition method of camera system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Kwang-Eun Ko 외 1명,‘Deep convolutional framework for abnormal behavior detection in a smart surveillance system’Engineering Applications of Artificial Intelligence, 제67권, 226~234쪽, (2018.01.01.) 1부.*

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102832889B1 (en) 2022-06-29 2025-07-11 고려대학교 세종산학협력단 Multi-level Hierarchical Complex Behavior Monitoring Method and System for Dog Psychological Separation Anxiety Symptoms

Also Published As

Publication number Publication date
KR20200055821A (en) 2020-05-22

Similar Documents

Publication Publication Date Title
KR101607934B1 (en) The method for monitoring communicable disease and system using the method, recording medium for performing the method
JP6592183B2 (en) monitoring
US8743200B2 (en) Activity monitor
KR102156279B1 (en) Method and automated camera-based system for detecting and suppressing harmful behavior of pet
US20170032192A1 (en) Computer-vision based security system using a depth camera
US20150262068A1 (en) Event detection apparatus and event detection method
CN111767888A (en) Object state detection method, computer device, storage medium and electronic device
US11138856B1 (en) Intelligent infant sleep position monitor to avoid SIDS
CN112712020B (en) Sleep monitoring method, device and system
KR102279958B1 (en) Method and Apparatus for Recognizing Animal State using Video and Sound
KR102026183B1 (en) Method and system for state analysis of pets using sensor technology
US11043301B2 (en) Infrared detectors and thermal tags for real-time activity monitoring
KR20200009530A (en) System and method for detecting abnormal object
JP6602067B2 (en) Display control apparatus, display control method, and program
CN109889774A (en) System and method for automatic video recording
KR102156280B1 (en) Method and system for detecting elimination behavior of pet using cnn-lstm and complex event processing
KR102188868B1 (en) IoT BASED MONITORING METHOD AND SYSTEM FOR DETECTING SEPARATION ANXIETY OF PET USING SUPPORT VECTOR MACHINE AND COMPLEX EVENT PROCESSING
KR20220163069A (en) Hybrid Human Fall Detection Method and System using Wearable Accelerometer and Video-Based Pose Data
KR20240084588A (en) An electronic device for pet monitoring and pet communication, method for controlling such electronic device, and system including the electronic device
JP6939065B2 (en) Image recognition computer program, image recognition device and image recognition method
KR20240028207A (en) Method for providing an companion animal behavior analysis service based on artificial intelligence and companion animal behavior analysis system based on artificial intelligence supporting the same
CN115147929A (en) A construction scene monitoring method, device, equipment and storage medium
KR102264116B1 (en) Method and Computer Program for Analyzing Real-Time Activity of GPCR in Cellular Endoplasmic Reticulum
KR20230005694A (en) Server and Methof for managing a safety of infant thereof
KR20210058396A (en) Electronic apparatus and method for controlling thereof

Legal Events

Date Code Title Description
PA0109 Patent application

Patent event code: PA01091R01D

Comment text: Patent Application

Patent event date: 20181108

PA0201 Request for examination
PE0902 Notice of grounds for rejection

Comment text: Notification of reason for refusal

Patent event date: 20200225

Patent event code: PE09021S01D

PG1501 Laying open of application
E701 Decision to grant or registration of patent right
PE0701 Decision of registration

Patent event code: PE07011S01D

Comment text: Decision to Grant Registration

Patent event date: 20200729

GRNT Written decision to grant
PR0701 Registration of establishment

Comment text: Registration of Establishment

Patent event date: 20200909

Patent event code: PR07011E01D

PR1002 Payment of registration fee

Payment date: 20200910

End annual number: 3

Start annual number: 1

PG1601 Publication of registration
PR1001 Payment of annual fee

Payment date: 20230705

Start annual number: 4

End annual number: 4

PR1001 Payment of annual fee

Payment date: 20250702

Start annual number: 6

End annual number: 6