KR102596308B1 - Electronic apparatus and method for intelligent video conversion - Google Patents

Electronic apparatus and method for intelligent video conversion Download PDF

Info

Publication number
KR102596308B1
KR102596308B1 KR1020210088394A KR20210088394A KR102596308B1 KR 102596308 B1 KR102596308 B1 KR 102596308B1 KR 1020210088394 A KR1020210088394 A KR 1020210088394A KR 20210088394 A KR20210088394 A KR 20210088394A KR 102596308 B1 KR102596308 B1 KR 102596308B1
Authority
KR
South Korea
Prior art keywords
image
horizontal
transformation
vertical
model
Prior art date
Application number
KR1020210088394A
Other languages
Korean (ko)
Other versions
KR20230007718A (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 KR1020210088394A priority Critical patent/KR102596308B1/en
Priority to PCT/KR2022/002168 priority patent/WO2023282426A2/en
Publication of KR20230007718A publication Critical patent/KR20230007718A/en
Application granted granted Critical
Publication of KR102596308B1 publication Critical patent/KR102596308B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • G06T3/4046Scaling of whole images or parts thereof, e.g. expanding or contracting using neural networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/01Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level
    • H04N7/0117Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level involving conversion of the spatial resolution of the incoming video signal
    • H04N7/0122Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level involving conversion of the spatial resolution of the incoming video signal the input and the output signals having different aspect ratios
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • G06T5/002
    • G06T5/009
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/90Dynamic range modification of images or parts thereof
    • G06T5/92Dynamic range modification of images or parts thereof based on global image properties
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/01Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/01Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level
    • H04N7/0135Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level involving interpolation processes

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Signal Processing (AREA)
  • Software Systems (AREA)
  • Multimedia (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • Medical Informatics (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computer Graphics (AREA)
  • Controls And Circuits For Display Device (AREA)
  • Editing Of Facsimile Originals (AREA)

Abstract

본 발명은 지능적 영상 변환을 위한 전자 장치 및 방법에 관한 것이다. 본 발명의 일 실시예에 따른 전자 장치는 영상을 변환하여 재생하는 전자 장치로서, 상기 전자 장치의 파지 상태에 관련된 센서 값을 감지하는 센서부; 및 상기 센서 값에 따른 파지 상태 및 상기 영상의 영상비율에 따라, 상기 영상에 대한 변환을 수행하는 제어부;를 포함하며, 상기 제어부는, 상기 영상의 내용을 유지하면서 화질을 개선하는 제1 변환, 상기 영상의 내용에 새로운 영상 내용을 추가 합성하는 제2 변환, 및 상기 영상의 내용에서 적어도 일부분을 확대하면서 화질을 개선하는 제3 변환 중 적어도 하나의 변환을 수행한다.The present invention relates to an electronic device and method for intelligent image conversion. An electronic device according to an embodiment of the present invention is an electronic device that converts and reproduces an image, comprising: a sensor unit that detects a sensor value related to a holding state of the electronic device; and a control unit that performs conversion on the image according to the grip state according to the sensor value and the image ratio of the image, wherein the control unit includes: a first conversion that improves image quality while maintaining the content of the image; At least one of a second transformation that adds new video content to the video content and a third transformation that improves image quality while enlarging at least a portion of the video content is performed.

Description

지능적 영상 변환을 위한 전자 장치 및 방법{ELECTRONIC APPARATUS AND METHOD FOR INTELLIGENT VIDEO CONVERSION}Electronic device and method for intelligent video conversion {ELECTRONIC APPARATUS AND METHOD FOR INTELLIGENT VIDEO CONVERSION}

본 발명은 동영상 재생에 관련된 전자 장치 및 방법에 관한 것으로서, 더욱 상세하게는 단말의 파지 상태와 동영상(이하, “영상”이라 지칭함)의 영상비율에 따라 적응적으로 영상을 변환하는 전자 장치 및 방법에 관한 것이다.The present invention relates to an electronic device and method related to video playback, and more specifically, to an electronic device and method for adaptively converting video according to the holding state of a terminal and the video ratio of the video (hereinafter referred to as “video”). It's about.

종래의 화면비율 변환 기술(이하, “종래 기술”이라 지칭함)에 따라, 단말에서 영상을 재생할 경우, 영상비율(즉, 영상 소스의 가로와 세로 간의 비율)을 유지한 채 화면비율(즉, 단말 화면의 가로와 세로 간의 비율)의 크기에 맞춰 최대한 크기로 영상을 재생한다. According to the conventional aspect ratio conversion technology (hereinafter referred to as “the prior art”), when playing a video on a terminal, the screen ratio (i.e., the terminal Play the video at the maximum size according to the size of the screen (ratio between width and height).

도 1은 종래 기술이 적용된 다양한 화면비율의 단말에서 16:9 영상비율의 영상을 재생 시에 대한 예들을 나타낸다.Figure 1 shows examples of playing a 16:9 video ratio video in terminals with various screen ratios using the prior art.

이에 따라, 종래 기술을 적용하면 단말 화면의 상하 또는 좌우에 빈 공간이 생기게 되며, 해당 빈 공간은 검은색으로 처리된다. 즉, 도 1을 참조하면, 4:3 화면비율을 가지는 단말에서 16:9 영상비율의 영상을 재생하면 단말 화면의 상하에 생기는 빈 공간에 레터 박스(letter box)라는 검은 영상이 삽입된다. 또한, 21:9 화면비율의 단말에서 16:9 영상비율의 영상을 재생하면 단말 화면의 좌우에 생기는 빈 공간에 필러 박스(pillar box)라는 검은 영상이 삽입된다.Accordingly, when the prior art is applied, an empty space is created on the top and bottom or left and right sides of the terminal screen, and the empty space is colored black. That is, referring to Figure 1, when a video with a 16:9 aspect ratio is played on a terminal with a 4:3 screen ratio, a black image called a letter box is inserted into the empty space created at the top and bottom of the terminal screen. Additionally, when a 16:9 aspect ratio video is played on a 21:9 screen ratio terminal, a black image called a pillar box is inserted into the empty space on the left and right sides of the terminal screen.

즉, 종래 기술은 단순히 영상비율을 유지하면서 단말의 화면에 맞게 재생하는 기술에 불과하므로, 단말의 화면비율이 영상비율과 맞지 않는 경우에 과도한 레터 박스 또는 필러의 사용으로 인해 사용자의 시각적 만족도가 낮아지는 문제점이 있다. 특히, 종래 기술이 적용된 단말의 화면 상태가 세로 상태(단말의 화면비율이 가로 보다 세로가 더 긴 상태)인 경우에 가로 영상(세로 보다 가로가 더 긴 영상비율을 가지는 영상)이 재생되면 해당 화면비율에 맞게 가로영상이 축소 재생되면서 이러한 문제점이 더욱 부각될 수밖에 없다.In other words, the prior art is simply a technology that matches the screen of the terminal while maintaining the video ratio, so when the screen ratio of the terminal does not match the video ratio, the user's visual satisfaction is low due to the use of excessive letter boxes or fillers. There is a problem with losing. In particular, when the screen state of a terminal to which the prior art is applied is portrait (the screen ratio of the terminal is longer than width), and a horizontal video (an image with an aspect ratio that is longer than vertical) is played, the corresponding screen As horizontal images are scaled down and played to match the ratio, these problems are bound to become more prominent.

KR10- 2007-0039790 AKR10- 2007-0039790 A

상기한 바와 같은 종래 기술의 문제점을 해결하기 위하여, 본 발명은 단말의 파지 상태와 영상의 영상비율에 따라 적응적으로 영상을 변환하는 기술을 제공하는데 그 목적이 있다.In order to solve the problems of the prior art as described above, the purpose of the present invention is to provide a technology for adaptively converting images according to the holding state of the terminal and the aspect ratio of the image.

다만, 본 발명이 해결하고자 하는 과제는 이상에서 언급한 과제에 제한되지 않으며, 언급되지 않은 또 다른 과제들은 아래의 기재로부터 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 명확하게 이해될 수 있을 것이다.However, the problem to be solved by the present invention is not limited to the problems mentioned above, and other problems not mentioned can be clearly understood by those skilled in the art from the description below. There will be.

상기와 같은 과제를 해결하기 위한 본 발명의 일 실시예에 따른 전자 장치는 영상을 변환하여 재생하는 전자 장치로서, 상기 전자 장치의 파지 상태에 관련된 센서 값을 감지하는 센서부; 및 상기 센서 값에 따른 파지 상태 및 상기 영상의 영상비율에 따라, 상기 영상에 대한 변환을 수행하는 제어부;를 포함한다.An electronic device according to an embodiment of the present invention for solving the above problems is an electronic device that converts and reproduces images, comprising: a sensor unit that detects a sensor value related to a holding state of the electronic device; and a control unit that performs conversion on the image according to the grip state according to the sensor value and the image ratio of the image.

상기 제어부는 상기 영상의 내용을 유지하면서 화질을 개선하는 제1 변환, 상기 영상의 내용에 새로운 영상 내용을 추가 합성하는 제2 변환, 및 상기 영상의 내용에서 적어도 일부분을 확대하되 세로가 더 긴 영상비율의 세로 영상으로 확대하면서 화질을 개선하는 제3 변환 중 적어도 하나의 변환을 수행할 수 있다.The control unit performs a first transformation to improve picture quality while maintaining the content of the video, a second transformation to add and synthesize new video content to the content of the video, and a video that enlarges at least a portion of the content of the video but has a longer length. At least one of the third transformations may be performed to improve image quality while enlarging the vertical image at a certain ratio.

상기 제어부는 가로가 더 긴 화면비율의 가로 파지 상태인 경우에 가로가 더 긴 영상비율의 가로 영상에 대해 상기 제1 변환 또는 상기 제2 변환을 수행할 수 있다.The control unit may perform the first conversion or the second conversion on a horizontal image with a longer horizontal aspect ratio when the display is in a horizontal holding state.

상기 제어부는 세로가 더 긴 화면비율의 세로 파지 상태인 경우에 가로 영상에 대해 상기 제3 변환을 수행할 수 있다.The control unit may perform the third transformation on the horizontal image when the screen is in a vertical position with a longer screen ratio.

상기 제어부는 상기 가로 파지 상태 또는 상기 세로 파지 상태인 경우에 세로가 더 긴 영상비율의 세로 영상에 대해 상기 제1 변환 또는 상기 제2 변환을 수행할 수 있다.The control unit may perform the first transformation or the second transformation on a vertical image with a longer vertical aspect ratio when the image is in the horizontal holding state or the vertical holding state.

상기 제어부는 상기 가로 파지 상태에서 상기 가로 영상에 필러 박스(pillar box) 또는 레터 박스(letter box)의 영역을 채워서 재생해야 하는 경우에 상기 가로 영상에 대해 상기 제2 변환을 수행하며, 필러 박스(pillar box) 또는 레터 박스(letter box)의 영역이 불필요한 경우에 상기 가로 영상에 대해 상기 제1 변환을 수행할 수 있다.The control unit performs the second conversion on the horizontal image when the horizontal image must be played by filling the area of a pillar box or letter box in the horizontal holding state, and performs the second transformation on the horizontal image, and fills the horizontal image with a pillar box ( When the pillar box or letter box area is unnecessary, the first transformation can be performed on the horizontal image.

상기 제어부는 제1 변환의 수행 시, 상기 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환할 수 있다.When performing the first conversion, the control unit generates an enlarged image by applying a previously learned machine learning model to the image to enlarge the image to an image larger than the screen size of the grasped state while improving image quality, and then generates an enlarged image. It can be converted to the screen ratio of the grip state by performing size interpolation.

상기 제어부는 상기 제2 변환의 수행 시, 이전 및 이후 프레임 영상을 이용하여 대응점 매칭 기반으로 현재 프레임 영상에 이전 또는 이후 프레임 영상에 포함된 새로운 영상 내용을 합성할 수 있다.When performing the second conversion, the control unit may synthesize new image content included in the previous or next frame image into the current frame image based on corresponding point matching using the previous and next frame images.

상기 제어부는 상기 제2 변환의 수행 시, 상기 합성된 현재 프레임 영상이 목표 영상의 해상도에 미달하는 경우에 해당 현재 프레임 영상에 생성적 적대 신경망(Generative Adversarial Network; GAN) 기반의 경계 확장을 수행하여 새로운 영상 내용을 합성할 수 있다.When performing the second transformation, the control unit performs boundary expansion based on a generative adversarial network (GAN) on the current frame image if the synthesized current frame image is less than the resolution of the target image. New video content can be synthesized.

상기 제어부는 상기 제2 변환의 수행 시, 상기 합성된 현재 프레임 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환할 수 있다.When performing the second conversion, the control unit generates an enlarged image by applying a previously learned machine learning model to the synthesized current frame image to enlarge the image into an image larger than the screen size of the grasped state while improving image quality. Afterwards, size interpolation can be performed on the enlarged image to convert it to the screen ratio of the holding state.

상기 제어부는 상기 제3 변환의 수행 시, 상기 가로 영상의 프레임 영상마다 해당 프레임 영상의 컨텐츠를 분석하여 해당 프레임 영상의 일부에 해당하는 재생 영역을 산출하는 과정과, 상기 가로 영상을 다수의 소단위로 분리하고 영상의 컨텐츠 종류 별로 기 학습된 다수의 AI(artificial intelligence) 모델 중에서 해당 소단위 내 가로 영상의 컨텐츠에 따라 소단위 별로 적용되는 최적 AI 모델을 선택하는 과정과, 상기 재생 영역을 기반으로 상기 가로 영상에서 세로가 더 긴 영상비율의 세로 영상을 프레임 영상마다 추출하는 과정과, 선택된 최적 AI 모델을 소단위 별로 적용하여 추출된 세로 영상을 확대 변환하는 과정을 각각 수행할 수 있다.When performing the third conversion, the control unit analyzes the contents of the frame image for each frame image of the horizontal image to calculate a playback area corresponding to a portion of the frame image, and divides the horizontal image into a plurality of small units. A process of separating and selecting an optimal AI model applied to each subunit according to the content of the horizontal image within the subunit from among a plurality of artificial intelligence (AI) models previously learned for each type of content of the image, and selecting the optimal AI model applied to each subunit based on the playback area of the horizontal image. A process of extracting a vertical image with a longer aspect ratio for each frame image and a process of enlarging and converting the extracted vertical image by applying the selected optimal AI model to each subunit can be performed.

상기 제어부는 상기 산출하는 과정에서, 각 프레임 영상에서 객체와 얼굴에 대한 영역을 각각 검출하여 검출된 영역을 포함하는 최대 재생 영역을 산출하며, 산출된 최대 재생 영역에 대한 잘라내기 과정을 통해 가로 보다 세로가 더 긴 제2 영상비율을 가지는 적어도 하나의 상기 재생 영역을 산출할 수 있다.In the calculation process, the control unit detects an area for an object and a face in each frame image, calculates a maximum playback area including the detected area, and performs a cropping process on the calculated maximum playback area to view horizontally. At least one playback area having a second vertically longer video ratio can be calculated.

상기 최대 재생 영역은 상기 검출된 영역이 복수개인 경우에 상기 각 검출된 영역을 모두 포함하는 영역일 수 있다.The maximum playback area may be an area that includes all of the detected areas when there are multiple detected areas.

상기 각 AI 모델은 머신 러닝(machine learning) 기법에 따라 서로 다른 컨텐츠의 저화질 영상으로부터 화질 개선된 확대 영상을 생성하도록 학습된 모델일 수 있다.Each of the AI models may be a model learned to generate enlarged images with improved quality from low-quality images of different content according to machine learning techniques.

상기 최적 AI 모델은 해상도 증가, 노이즈 제거 및 다이나믹 레인지 증가 중 적어도 하나의 화질 개선을 수행할 수 있다.The optimal AI model can improve image quality by at least one of increasing resolution, removing noise, and increasing dynamic range.

상기 제어부는 상기 제3 변환에 따라 확대된 영상을 디스플레이의 모든 화소에서 재생하도록 제어할 수 있다.The control unit can control the image enlarged according to the third transformation to be played back in all pixels of the display.

본 발명의 일 실시예에 따른 방법은 전자 장치에서 영상을 변환하여 재생하기 위한 방법으로서, 상기 전자 장치의 파지 상태에 관련된 센서 값을 감지하는 단계; 및 상기 센서 값에 따른 파지 상태 및 상기 영상의 영상비율에 따라, 상기 영상에 대한 변환을 수행하는 단계;를 포함한다.A method according to an embodiment of the present invention is a method for converting and playing back an image in an electronic device, the method comprising: detecting a sensor value related to a holding state of the electronic device; and performing conversion on the image according to the grip state according to the sensor value and the image ratio of the image.

상기 변환을 수행하는 단계는, 상기 영상의 내용을 유지하면서 화질을 개선하는 제1 변환을 수행하는 단계와, 상기 영상의 내용에 새로운 영상 내용을 추가 합성하는 제2 변환을 수행하는 단계와, 상기 영상의 내용에서 적어도 일부분을 확대하면서 화질을 개선하는 제3 변환을 수행하는 단계 중에 적어도 하나의 단계를 포함할 수 있다.The step of performing the transformation includes performing a first transformation to improve image quality while maintaining the content of the image, and performing a second transformation to add new image content to the content of the image. At least one step may be included among the steps of performing a third transformation to improve image quality while enlarging at least a portion of the video content.

상기 변환을 수행하는 단계는 가로가 더 긴 화면비율의 가로 파지 상태인 경우에 가로가 더 긴 영상비율의 가로 영상에 대해 상기 제1 변환 또는 상기 제2 변환을 수행하고, 세로가 더 긴 화면비율의 세로 파지 상태인 경우에 가로가 더 긴 영상비율의 가로 영상에 대해 상기 제3 변환을 수행하며, 상기 가로 파지 상태 또는 상기 세로 파지 상태인 경우에 세로가 더 긴 영상비율의 세로 영상에 대해 상기 제1 변환 또는 상기 제2 변환을 수행하는 단계를 포함할 수 있다.The step of performing the conversion is to perform the first conversion or the second conversion on the horizontal image with the longer horizontal aspect ratio when the horizontal image is in a horizontal holding state, and the second conversion is performed on the horizontal image with the longer horizontal aspect ratio. In the case of the vertical holding state, the third transformation is performed on the horizontal image with a longer horizontal aspect ratio, and in the case of the horizontal holding state or the vertical holding state, the third transformation is performed on the vertical image with the longer vertical aspect ratio. It may include performing the first transformation or the second transformation.

상기 제1 변환을 수행하는 단계는, 상기 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환하는 단계를 포함할 수 있다.The step of performing the first conversion includes generating an enlarged image by applying a previously learned machine learning model to the image to enlarge the image into an image larger than the screen size of the grasped state while improving image quality, and then generating an enlarged image. It may include performing size interpolation on and converting to the screen ratio of the grip state.

상기 제2 변환을 수행하는 단계는 이전 및 이후 프레임 영상을 이용하여 대응점 매칭 기반으로 현재 프레임 영상에 이전 또는 이후 프레임 영상에 포함된 새로운 영상 내용을 합성하는 단계를 포함할 수 있다.The step of performing the second transformation may include synthesizing new image content included in the previous or next frame image into the current frame image based on corresponding point matching using the previous and next frame images.

상기 제2 변환을 수행하는 단계는 상기 합성된 현재 프레임 영상이 목표 영상의 해상도에 미달하는 경우에 해당 현재 프레임 영상에 생성적 적대 신경망(Generative Adversarial Network; GAN) 기반의 경계 확장을 수행하여 새로운 영상 내용을 단계를 포함할 수 있다.In the step of performing the second transformation, when the synthesized current frame image is less than the resolution of the target image, a generative adversarial network (GAN)-based boundary expansion is performed on the current frame image to create a new image. Content may include steps.

상기 제2 변환을 수행하는 단계는 상기 합성된 현재 프레임 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환하는 단계를 포함할 수 있다.The step of performing the second conversion includes generating an enlarged image by applying a previously learned machine learning model to the synthesized current frame image to enlarge the image into an image larger than the screen size of the grip state while improving image quality, It may include performing size interpolation on the enlarged image and converting it to the screen ratio of the holding state.

상기 변환을 수행하는 단계는 세로가 더 긴 화면비율의 세로 파지 상태인 경우에 가로가 더 긴 영상비율의 가로 영상에 대해 상기 제3 변환을 수행하는 단계를 포함할 수 있다.The step of performing the conversion may include performing the third conversion on a horizontal image with a longer horizontal aspect ratio when the image is in a vertical holding state with a longer aspect ratio.

상기 제3 변환을 수행하는 단계는, 상기 가로 영상의 프레임 영상마다 해당 프레임 영상의 컨텐츠를 분석하여 해당 프레임 영상의 일부에 해당하는 재생 영역을 산출하는 단계; 상기 가로 영상을 다수의 소단위로 분리하고 영상의 컨텐츠 종류 별로 기 학습된 다수의 AI(artificial intelligence) 모델 중에서 해당 소단위 내 가로 영상의 컨텐츠에 따라 소단위 별로 적용되는 최적 AI 모델을 선택하는 단계; 상기 재생 영역을 기반으로 상기 가로 영상에서 세로가 더 긴 영상비율의 세로 영상을 프레임 영상마다 추출하는 단계; 및 선택된 최적 AI 모델을 소단위 별로 적용하여 추출된 세로 영상을 확대 변환하는 단계;를 포함할 수 있다.The step of performing the third transformation includes calculating a playback area corresponding to a portion of the frame image by analyzing the content of the frame image for each frame image of the horizontal image; Separating the horizontal image into a plurality of subunits and selecting an optimal AI model applied to each subunit according to the content of the horizontal image within the subunit from among a plurality of artificial intelligence (AI) models already learned for each type of content of the image; extracting a vertical image with a longer vertical aspect ratio for each frame image from the horizontal image based on the playback area; and enlarging and converting the extracted vertical image by applying the selected optimal AI model for each subunit.

상기와 같이 구성되는 본 발명은 영상의 영상비율과 이를 재생하는 전자 장치의 화면비율이 다를 때, 검은 영상(필러 박스 또는 레터 박스)를 삽입하는 것이 아니라, 영상의 영상비율이 조정되도록 처리함으로써 이를 재생하는 전자 장치의 화면비율에 해당 영상을 적합하게 맞출 수 있는 이점이 있다. The present invention, constructed as described above, does not insert a black image (pillar box or letter box) when the aspect ratio of the image and the screen ratio of the electronic device that reproduces it are different, but processes it so that the aspect ratio of the image is adjusted. There is an advantage in that the video can be appropriately adjusted to the screen ratio of the electronic device being played.

또한, 본 발명은 전자 장치의 파지 상태와 영상의 영상비율에 따라 제1 내지 제3 변환 중 적어도 하나의 변환을 적응적으로 수행함으로써 영상의 영상비율에 대한 변환을 효과적으로 수행할 수 있을 뿐만 아니라, 변환된 영상의 고해상도화를 도모할 수 있는 이점 있다.In addition, the present invention not only effectively performs conversion on the aspect ratio of an image by adaptively performing at least one of the first to third conversions according to the holding state of the electronic device and the aspect ratio of the image. There is an advantage in achieving higher resolution of the converted video.

또한, 본 발명은 영상 재생 시, 레터 박스 또는 필러 박스를 최소화할 수 있을 뿐 아니라, 그 영상의 주요 객체를 포함하면서 확대하되, 확대하면서 발생하는 저화질의 문제를 개선한 고화질의 영상으로 재생할 수 있으므로, 사용자의 시각적 만족도를 높일 수 있는 이점이 있다. In addition, the present invention not only minimizes letter boxes or pillar boxes when playing video, but also enlarges the video while including the main objects, and reproduces the video in high definition by improving the low-quality problem that occurs during enlargement. , it has the advantage of increasing the user's visual satisfaction.

또한, 본 발명은 전자 장치의 화면을 최대한 활용하여 재생할 수 있어 시청 몰입감의 증대될 뿐 아니라, 노출 효과도 커, 재생 영상이 광고일 경우에 그 광고 효과가 큰 이점이 있다. In addition, the present invention allows playback using the screen of the electronic device as much as possible, which not only increases viewing immersion, but also has a large exposure effect, so when the played video is an advertisement, the advertisement effect is great.

또한, 본 발명은 다양한 화질 개선 기법의 적용 가능하므로, 주문형 비디오(video on demand; VOD) 뿐 아니라 실시간 스트리밍에도 적용 가능한 이점이 있다.In addition, since the present invention can be applied to various image quality improvement techniques, it has the advantage of being applicable not only to video on demand (VOD) but also to real-time streaming.

본 발명에서 얻을 수 있는 효과는 이상에서 언급한 효과들로 제한되지 않으며, 언급하지 않은 또 다른 효과들은 아래의 기재로부터 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 명확하게 이해될 수 있을 것이다.The effects that can be obtained from the present invention are not limited to the effects mentioned above, and other effects not mentioned can be clearly understood by those skilled in the art from the description below. will be.

도 1은 종래 기술이 적용된 다양한 화면비율의 단말에서 16:9 영상비율의 영상을 재생 시에 대한 예들을 나타낸다.
도 2는 본 발명의 일 실시예에 따른 전자 장치(100)의 블록 구성도를 나타낸다.
도 3은 본 발명의 일 실시예에 따른 방법의 순서도를 나타낸다.
도 4는 제어부(160)에 의해 수행되는 제1 변환에 대한 순서도를 나타낸다.
도 5는 영상에 대한 다양한 확대에 대한 예시를 나타낸다.
도 6은 제어부(160)에 의해 수행되는 제2 변환에 대한 순서도를 나타낸다.
도 7은 제2 변환에 대한 예시를 나타낸다.
도 8은 제어부(160)에 의해 수행되는 제3 변환에 대한 순서도를 나타낸다.
도 9는 제3 변환에서 S310에 대한 보다 상세한 순서도를 나타낸다.
도 10은 S320에서 최적 AI 모델을 선택하는 일 예를 나타낸다.
도 11은 세로 파지 상태의 전자 장치에서 가로 영상을 재생하는 예를 비교하여 나타낸다.
도 12는 본 발명의 일 실시예에 따른 방법의 S20에서 전자 장치(100)가 가로 파지 상태일 경우에 가로 영상에 대한 영상처리의 보다 상세한 순서도를 나타낸다.
도 13는 본 발명의 일 실시예에 따른 방법의 S20에서 전자 장치(100)가 세로 파지 상태일 경우에 가로 영상에 대한 영상처리의 보다 상세한 순서도를 나타낸다.
Figure 1 shows examples of playing a 16:9 video ratio video in terminals with various screen ratios using the prior art.
Figure 2 shows a block diagram of an electronic device 100 according to an embodiment of the present invention.
Figure 3 shows a flowchart of a method according to one embodiment of the present invention.
Figure 4 shows a flow chart for the first conversion performed by the control unit 160.
Figure 5 shows examples of various enlargements of an image.
Figure 6 shows a flow chart for the second conversion performed by the control unit 160.
Figure 7 shows an example of the second transformation.
Figure 8 shows a flowchart for the third conversion performed by the control unit 160.
Figure 9 shows a more detailed flow chart for S310 in the third transformation.
Figure 10 shows an example of selecting an optimal AI model in S320.
Figure 11 shows a comparison example of playing a horizontal image in an electronic device held vertically.
FIG. 12 shows a more detailed flowchart of image processing for a horizontal image when the electronic device 100 is held horizontally in step S20 of the method according to an embodiment of the present invention.
FIG. 13 shows a more detailed flowchart of image processing for a horizontal image when the electronic device 100 is held vertically in step S20 of the method according to an embodiment of the present invention.

본 발명의 상기 목적과 수단 및 그에 따른 효과는 첨부된 도면과 관련한 다음의 상세한 설명을 통하여 보다 분명해질 것이며, 그에 따라 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자가 본 발명의 기술적 사상을 용이하게 실시할 수 있을 것이다. 또한, 본 발명을 설명함에 있어서 본 발명과 관련된 공지 기술에 대한 구체적인 설명이 본 발명의 요지를 불필요하게 흐릴 수 있다고 판단되는 경우에는 그 상세한 설명을 생략하기로 한다.The above purpose and means of the present invention and the resulting effects will become clearer through the following detailed description in conjunction with the accompanying drawings, and thus the technical idea of the present invention will be easily understood by those skilled in the art. It will be possible to implement it. Additionally, in describing the present invention, if it is determined that a detailed description of known technologies related to the present invention may unnecessarily obscure the gist of the present invention, the detailed description will be omitted.

본 명세서에서 사용된 용어는 실시예들을 설명하기 위한 것이며, 본 발명을 제한하고자 하는 것은 아니다. 본 명세서에서, 단수형은 문구에서 특별히 언급하지 않는 한 경우에 따라 복수형도 포함한다. 본 명세서에서, "포함하다", “구비하다”, “마련하다” 또는 “가지다” 등의 용어는 언급된 구성요소 외의 하나 이상의 다른 구성요소의 존재 또는 추가를 배제하지 않는다.The terminology used herein is for describing embodiments and is not intended to limit the invention. In this specification, singular forms also include plural forms, as appropriate, unless specifically stated otherwise in the context. In this specification, terms such as “comprise,” “provide,” “provide,” or “have” do not exclude the presence or addition of one or more other components other than the mentioned components.

본 명세서에서, “또는”, “적어도 하나” 등의 용어는 함께 나열된 단어들 중 하나를 나타내거나, 또는 둘 이상의 조합을 나타낼 수 있다. 예를 들어, “또는 B”“및 B 중 적어도 하나”는 A 또는 B 중 하나만을 포함할 수 있고, A와 B를 모두 포함할 수도 있다.In this specification, terms such as “or” and “at least one” may represent one of words listed together, or a combination of two or more. For example, “or B” “and at least one of B” may include only A or B, or both A and B.

본 명세서에서, “예를 들어” 등에 따르는 설명은 인용된 특성, 변수, 또는 값과 같이 제시한 정보들이 정확하게 일치하지 않을 수 있고, 허용 오차, 측정 오차, 측정 정확도의 한계와 통상적으로 알려진 기타 요인을 비롯한 변형과 같은 효과로 본 발명의 다양한 실시 예에 따른 발명의 실시 형태를 한정하지 않아야 할 것이다.In this specification, descriptions under “for example” and the like may not exactly match the information presented, such as cited characteristics, variables, or values, and may be subject to tolerances, measurement errors, limits of measurement accuracy and other commonly known factors. Effects such as modifications, including, should not limit the embodiments of the invention according to various embodiments of the present invention.

본 명세서에서, 어떤 구성요소가 다른 구성요소에 '연결되어’ 있다거나 '접속되어' 있다고 기재된 경우, 그 다른 구성요소에 직접적으로 연결되어 있거나 또는 접속되어 있을 수도 있지만, 중간에 다른 구성요소가 존재할 수도 있다고 이해되어야 할 것이다. 반면에, 어떤 구성요소가 다른 구성 요소에 '직접 연결되어' 있다거나 '직접 접속되어' 있다고 언급된 때에는, 중간에 다른 구성요소가 존재하지 않는 것으로 이해될 수 있어야 할 것이다.In this specification, when a component is described as being 'connected' or 'connected' to another component, it may be directly connected or connected to the other component, but other components may exist in between. It must be understood that it may be possible. On the other hand, when a component is mentioned as being 'directly connected' or 'directly connected' to another component, it should be understood that there are no other components in between.

본 명세서에서, 어떤 구성요소가 다른 구성요소의 '상에' 있다거나 '접하여' 있다고 기재된 경우, 다른 구성요소에 상에 직접 맞닿아 있거나 또는 연결되어 있을 수 있지만, 중간에 또 다른 구성요소가 존재할 수 있다고 이해되어야 할 것이다. 반면, 어떤 구성요소가 다른 구성요소의 '바로 위에' 있다거나 '직접 접하여' 있다고 기재된 경우에는, 중간에 또 다른 구성요소가 존재하지 않은 것으로 이해될 수 있다. 구성요소 간의 관계를 설명하는 다른 표현들, 예를 들면, '~사이에'와 '직접 ~사이에' 등도 마찬가지로 해석될 수 있다.In this specification, when a component is described as being ‘on’ or ‘in contact with’ another component, it may be in direct contact with or connected to the other component, but there may be another component in between. It must be understood that it can be done. On the other hand, if a component is described as being 'right above' or 'in direct contact' with another component, it can be understood that there is no other component in the middle. Other expressions that describe the relationship between components, such as 'between' and 'directly between', can be interpreted similarly.

본 명세서에서, '제1', '제2' 등의 용어는 다양한 구성요소를 설명하는데 사용될 수 있지만, 해당 구성요소는 위 용어에 의해 한정되어서는 안 된다. 또한, 위 용어는 각 구성요소의 순서를 한정하기 위한 것으로 해석되어서는 안되며, 하나의 구성요소와 다른 구성요소를 구별하는 목적으로 사용될 수 있다. 예를 들어, '제1구성요소'는 '제2구성요소'로 명명될 수 있고, 유사하게 '제2구성요소'도 '제1구성요소'로 명명될 수 있다.In this specification, terms such as 'first' and 'second' may be used to describe various components, but the components should not be limited by the above terms. Additionally, the above term should not be interpreted as limiting the order of each component, but may be used for the purpose of distinguishing one component from another component. For example, a 'first component' may be named a 'second component', and similarly, a 'second component' may also be named a 'first component'.

다른 정의가 없다면, 본 명세서에서 사용되는 모든 용어는 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 공통적으로 이해될 수 있는 의미로 사용될 수 있을 것이다. 또한, 일반적으로 사용되는 사전에 정의되어 있는 용어들은 명백하게 특별히 정의되어 있지 않는 한 이상적으로 또는 과도하게 해석되지 않는다.Unless otherwise defined, all terms used in this specification may be used with meanings that can be commonly understood by those skilled in the art to which the present invention pertains. Additionally, terms defined in commonly used dictionaries are not interpreted ideally or excessively unless clearly specifically defined.

이하, 첨부된 도면을 참조하여 본 발명에 따른 바람직한 일 실시예를 상세히 설명하도록 한다. Hereinafter, a preferred embodiment according to the present invention will be described in detail with reference to the attached drawings.

도 2는 본 발명의 일 실시예에 따른 전자 장치(100)의 블록 구성도를 나타낸다.Figure 2 shows a block diagram of an electronic device 100 according to an embodiment of the present invention.

본 발명의 일 실시예에 따른 전자 장치(100)는 영상을 변환하여 재생하는 장치이다. 이때, 영상은 동영상(video)을 지칭할 수 있으며, 기 저장된 영상이거나 타 장치(서버)로부터 전송된 영상일 수 있다. 예를 들어, 본 전자 장치(100)가 제공하는 서비스는 기 저장된 영상을 재생하는 서비스, 주문형 비디오(video on demand; VOD) 또는 실시간 스트리밍 등의 서비스일 수 있으나, 이에 한정되는 것은 아니다.The electronic device 100 according to an embodiment of the present invention is a device that converts and reproduces images. At this time, the video may refer to a video, and may be a pre-stored video or a video transmitted from another device (server). For example, the service provided by the electronic device 100 may be a service that plays pre-stored images, video on demand (VOD), or real-time streaming, but is not limited thereto.

특히, 영상은 세로 보다 가로가 더 긴 영상비율의 컨텐츠를 가지는 영상(이하, “가로 영상”이라 지칭함)이거나, 가로 보다 세로가 더 긴 영상비율의 컨텐츠를 가지는 영상(이하, “세로 영상”이라 지칭함)일 수 있다. 또한, 파지 상태는 전자 장치(100)가 사용자에 의해 주어진 상태로서, 디스플레이(130)가 세로보다 가로가 더 긴 화면비율의 상태(이하, “가로 파지 상태”라 지칭함)이거나, 가로보다 세로가 더 긴 화면비율의 상태(이하, “세로 파지 상태”라 지칭함)일 수 있다In particular, the video is either a video with content with an aspect ratio that is longer than the width (hereinafter referred to as “horizontal video”), or a video with content with an aspect ratio that is longer than width (hereinafter referred to as “vertical video”). may refer to it). In addition, the holding state is a state in which the electronic device 100 is given by the user, and the display 130 is in a state where the screen ratio is longer than the vertical (hereinafter referred to as “horizontal holding state”), or the display 130 is in a state where the screen ratio is longer than the width. It may be in a state of a longer screen ratio (hereinafter referred to as “vertical grip state”).

즉, 전자 장치(100)는 현재의 파지 상태 및 영상의 영상비율(즉, 가로 영상인지 세로 영상인지 여부)에 따라, 해당 영상에 대해 다양한 변환을 수행한 후 재생할 수 있다.In other words, the electronic device 100 can perform various transformations on the image and then play it, depending on the current grip state and the image ratio of the image (i.e., whether it is a horizontal image or a vertical image).

이때, 전자 장치(100)은 컴퓨팅(computing)이 가능한 단말일 수 있다. 예를 들어, 전자 장치(100)는 데스크탑 PC(desktop personal computer), 랩탑 PC(laptop personal computer), 태블릿 PC(tablet personal computer), 넷북 컴퓨터(netbook computer), 워크스테이션(workstation), PDA(personal digital assistant), 스마트폰(smart phone), 스마트패드(smart pad), 또는 휴대폰(mobile phone) 등일 수 있으나, 이에 한정되는 것은 아니다.At this time, the electronic device 100 may be a terminal capable of computing. For example, the electronic device 100 may be a desktop personal computer, a laptop personal computer, a tablet personal computer, a netbook computer, a workstation, or a personal digital assistant (PDA). It may be a digital assistant, a smart phone, a smart pad, or a mobile phone, but is not limited thereto.

이러한 전자 장치(100)은, 도 2에 도시된 바와 같이, 입력부(110), 통신부(120), 디스플레이(130), 메모리(140) 및 제어부(160)를 포함할 수 있다.As shown in FIG. 2 , the electronic device 100 may include an input unit 110, a communication unit 120, a display 130, a memory 140, and a control unit 160.

입력부(110)는 다양한 사용자의 입력에 대응하여, 입력데이터를 발생시키며, 다양한 입력수단을 포함할 수 있다.The input unit 110 generates input data in response to various user inputs and may include various input means.

예를 들어, 입력부(110)는 키보드(key board), 키패드(key pad), 돔 스위치(dome switch), 터치 패널(touch panel), 터치 키(touch key), 터치 패드(touch pad), 마우스(mouse), 메뉴 버튼(menu button) 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.For example, the input unit 110 includes a keyboard, key pad, dome switch, touch panel, touch key, touch pad, and mouse. It may include (mouse), menu button, etc., but is not limited thereto.

통신부(120)는 서버 등 다른 장치와의 통신을 수행하는 구성으로서, 영상에 대한 비트스트림, 기 학습된 모델(AI 모델, 머신 러닝 모델, GAN 모델 등)에 대한 정보 등을 다른 장치로부터 수신할 수 있다. The communication unit 120 is a component that performs communication with other devices such as servers, and can receive information about bitstreams for images, information about pre-learned models (AI models, machine learning models, GAN models, etc.) from other devices. You can.

예를 들어, 통신부(120)는 5G(5th generation communication), LTE-A(long term evolution-advanced), LTE(long term evolution), 블루투스, BLE(bluetooth low energy), NFC(near field communication), 와이파이(WiFi) 통신 등의 무선 통신을 수행하거나, 케이블 통신 등의 유선 통신을 수행할 수 있으나, 이에 한정되는 것은 아니다.For example, the communication unit 120 supports 5th generation communication (5G), long term evolution-advanced (LTE-A), long term evolution (LTE), Bluetooth, bluetooth low energy (BLE), near field communication (NFC), Wireless communication such as WiFi communication may be performed, or wired communication such as cable communication may be performed, but is not limited thereto.

디스플레이(130)는 다양한 영상 데이터를 화면으로 표시하는 것으로서, 비발광형 패널이나 발광형 패널로 구성될 수 있다. 또한, 디스플레이(230)는 파지 상태 및 영상의 영상비율에 따라 변환된 영상을 표시할 수 있다. The display 130 displays various image data on a screen and may be composed of a non-emissive panel or an emissive panel. Additionally, the display 230 can display the converted image according to the grip state and the aspect ratio of the image.

예를 들어, 디스플레이(130)는 액정 디스플레이(LCD; liquid crystal display), 발광 다이오드(LED; light emitting diode) 디스플레이, 유기 발광 다이오드(OLED; organic LED) 디스플레이, 마이크로 전자기계 시스템(MEMS; micro electro mechanical systems) 디스플레이, 또는 전자 종이(electronic paper) 디스플레이 등을 포함할 수 있으나, 이에 한정되는 것은 아니다. 또한, 디스플레이(130)는 입력부(120, 220)와 결합되어 터치 스크린(touch screen) 등으로 구현될 수 있다.For example, the display 130 may be a liquid crystal display (LCD), a light emitting diode (LED) display, an organic light emitting diode (OLED) display, or a micro electromechanical system (MEMS). It may include, but is not limited to, a mechanical systems display, an electronic paper display, etc. Additionally, the display 130 may be combined with the input units 120 and 220 and implemented as a touch screen or the like.

메모리(140)는 전자 장치(100)의 동작에 필요한 각종 정보를 저장한다. 메모리(140)의 저장 정보로는 영상, 모델, 변환된 영상, 후술할 방법에 관련된 프로그램 정보 등이 포함될 수 있으나, 이에 한정되는 것은 아니다. 특히, AI 모델은 복수개가 저장될 수 있으며, 압축 처리된 형태로 저장될 수 있으나, 이에 한정되는 것은 아니다.The memory 140 stores various information necessary for the operation of the electronic device 100. Information stored in the memory 140 may include, but is not limited to, images, models, converted images, and program information related to methods to be described later. In particular, a plurality of AI models may be stored and may be stored in compressed form, but are not limited thereto.

예를 들어, 메모리(140)는 그 유형에 따라 하드디스크 타입(hard disk type), 마그네틱 매체 타입(magnetic media type), CD-ROM(compact disc read only memory), 광 기록 매체 타입(optical Media type), 자기-광 매체 타입(magneto-optical media type), 멀티미디어 카드 마이크로 타입(multimedia card micro type), 플래시 저장부 타입(flash memory type), 롬 타입(read only memory type), 또는 램 타입(random access memory type) 등을 포함할 수 있으나, 이에 한정되는 것은 아니다. 또한, 메모리(140)는 그 용도/위치에 따라 캐시(cache), 버퍼, 주기억장치, 또는 보조기억장치이거나 별도로 마련된 저장 시스템일 수 있으나, 이에 한정되는 것은 아니다.For example, the memory 140 is classified into hard disk type, magnetic media type, CD-ROM (compact disc read only memory), and optical media type depending on its type. ), magneto-optical media type, multimedia card micro type, flash memory type, ROM type (read only memory type), or random RAM type. access memory type), etc., but is not limited thereto. Additionally, the memory 140 may be a cache, a buffer, a main memory, an auxiliary memory, or a separately provided storage system depending on its purpose/location, but is not limited thereto.

센서부(150)는 전자 장치(100)나 그 주변의 상태 정보를 감지한다. 이러한 센서부(150)는 가속 센서, 자이로 센서(Gyro Sensor), 근접 센서, RGB 센서, 밝기 센서, 홀 센서, 모션 센서, 온도/습도 센서, 기압계, 지자기 센서 등 다양한 센서를 포함할 수 있다.The sensor unit 150 detects status information of the electronic device 100 or its surroundings. This sensor unit 150 may include various sensors such as an acceleration sensor, a gyro sensor, a proximity sensor, an RGB sensor, a brightness sensor, a hall sensor, a motion sensor, a temperature/humidity sensor, a barometer, and a geomagnetic sensor.

특히, 전자 장치(100)는 다양한 파지 상태에 있을 수 있으며, 센서부(150)는 이를 감지할 수 있다. 즉, 센서부(150)는 자이로 센서(Gyro Sensor), 모션 센서 등과 같이 전자 장치(100)의 파지 상태에 관련된 센서 값을 감지하는 센서를 포함할 수 있다.In particular, the electronic device 100 may be in various holding states, and the sensor unit 150 may detect these. That is, the sensor unit 150 may include a sensor that detects sensor values related to the gripping state of the electronic device 100, such as a gyro sensor or a motion sensor.

제어부(160)는 전자 장치(100)의 다양한 제어 동작을 수행할 수 있다. 즉, 제어부(160)는 후술할 방법의 수행을 제어할 수 있으며, 전자 장치(100)의 나머지 구성, 즉 입력부(110), 통신부(120), 디스플레이(130), 메모리(140), 센서부(150) 등의 동작을 제어할 수 있다.The control unit 160 can perform various control operations of the electronic device 100. That is, the control unit 160 can control the execution of a method to be described later, and the remaining components of the electronic device 100, namely, the input unit 110, the communication unit 120, the display 130, the memory 140, and the sensor unit. Operations such as (150) can be controlled.

예를 들어, 제어부(160)는 하드웨어인 프로세서(processor) 또는 해당 프로세서에서 수행되는 소프트웨어인 프로세스(process) 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.For example, the control unit 160 may include a hardware processor or a software process executed on the processor, but is not limited thereto.

특히, 제어부(160)는 센서부(150)의 파지 상태 관련 센서의 센서 값을 이용하여 전자 장치(100)의 파지 상태를 파악할 수 있으며, 파악된 파지 상태와 영상의 영상비율에 따라, 영상에 대한 변환을 수행을 제어할 수 있다.In particular, the control unit 160 can determine the gripping state of the electronic device 100 using the sensor value of the gripping state-related sensor of the sensor unit 150, and depending on the grasping state and the image ratio of the image, the image You can control the conversion performed.

이때, 영상에 대한 변환은 제1 내지 제3 변환 중 적어도 하나일 수 있다. 즉, 제1 변환은 영상의 내용을 유지하면서 확대하되 그 화질 개선도 함께 수행하는 변환이다. 제2 변환은 영상의 내용에 새로운 영상 내용을 추가 합성하면서 확대하는 변환이다. 물론, 제2 변환은 새로운 영상 내용이 추가 합성된 후에 제1 변환이 추가적으로 수행되는 변환일 수 있다. 또한, 제3 변환은 영상의 내용에서 적어도 일부분을 확대하되 세로 영상으로 확대하면서 그 화질 개선도 함께 수행하는 변환이다.At this time, the transformation for the image may be at least one of the first to third transformations. In other words, the first transformation is a transformation that enlarges the image while maintaining its content, but also improves the image quality. The second transformation is a transformation that expands by adding new video content to the video content. Of course, the second transformation may be a transformation in which the first transformation is additionally performed after new image content is additionally synthesized. Additionally, the third transformation is a transformation that enlarges at least a portion of the video content into a vertical image while also improving the image quality.

하기의 표 1은 파지 상태와 영상의 영상비율에 따라 제어부(160)가 수행하는 변환의 종류를 나타낸다.Table 1 below shows the types of conversion performed by the control unit 160 depending on the grip state and the aspect ratio of the image.

가로 파지 상태horizontal grip state 세로 파지 상태Vertical grip state 가로 영상horizontal video 제1 변환 또는 제2 변환First Transformation or Second Transformation 제3 변환third transformation 세로 영상vertical video 제1 변환 또는 제2 변환First Transformation or Second Transformation 제1 변환 또는 제2 변환First Transformation or Second Transformation

즉, 제어부(160)는 전자 장치(100)가 가로 파지 상태이고 가로 영상인 경우에 가로 영상에 대해 제1 변환 또는 제2 변환을 수행하도록 제어할 수 있다. 이때, 제어부(160)는 필러 박스(pillar box)의 영역이 필요한지 여부에 따라 제1 변환 또는 제2 변환을 수행할 수 있다. 즉, 가로 파지 상태 및 가로 영상이되 가로 영상에 필러 박스(pillar box)의 영역을 채워서 재생해야 하는 경우(가령, 원본 가로 영상의 해상도가 부족하여 변환되는 가로 영상에 필러 박스의 영역이 필요한 경우), 가로 영상에 대해 상기 제2 변환을 수행할 수 있다. 반면, 가로 파지 상태 및 가로 영상이되 가로 영상에 필러 박스의 영역을 채울 필요가 없는 경우(가령, 원본 가로 영상의 해상도가 충분하여 변환되는 가로 영상에 필러 박스의 영역이 불필요한 경우), 가로 영상에 대해 제1 변환을 수행할 수 있다.또한, 제어부(160)는 전자 장치(100)가 세로 파지 상태인 경우에 가로 영상에 대해 제3 변환을 수행하도록 제어할 수 있다.That is, when the electronic device 100 is held in a horizontal position and the image is a horizontal image, the control unit 160 may control the horizontal image to perform first or second conversion. At this time, the control unit 160 may perform the first transformation or the second transformation depending on whether the area of the pillar box is needed. In other words, when the horizontal image is held horizontally and the horizontal image needs to be played by filling the pillar box area (for example, when the resolution of the original horizontal image is insufficient and the converted horizontal image requires the pillar box area) ), the second transformation can be performed on the horizontal image. On the other hand, when the horizontal image is in a horizontal grip state and there is no need to fill the pillar box area in the horizontal image (for example, when the resolution of the original horizontal image is sufficient and the pillar box area is unnecessary in the converted horizontal image), the horizontal image A first transformation may be performed. Additionally, the control unit 160 may control the electronic device 100 to perform a third transformation on a horizontal image when the electronic device 100 is held in a vertical position.

또한, 제어부(160)는 전자 장치(100)가 가로 파지 상태 또는 세로 파지 상태인 경우에 세로 영상에 대해 제1 변환 또는 제2 변환을 수행하도록 제어할 수 있다. 이때, 제어부(160)는 필러 박스(pillar box)의 영역이 필요한지 여부에 따라 제1 변환 또는 제2 변환을 수행할 수 있다. 즉, 세로 영상에 필러 박스(pillar box)의 영역을 채워서 재생해야 하는 경우(가령, 원본 세로 영상의 해상도가 부족하여 변환되는 가로 또는 세로 영상에 필러 박스의 영역이 필요한 경우), 세로 영상에 대해 상기 제2 변환을 수행할 수 있다. 반면, 세로 영상에 필러 박스의 영역을 채울 필요가 없는 경우(가령, 원본 세로 영상의 해상도가 충분하여 변환되는 가로 또는 세로 영상에 필러 박스의 영역이 불필요한 경우), 세로 영상에 대해 제1 변환을 수행할 수 있다.Additionally, the control unit 160 may control the electronic device 100 to perform first or second transformation on a vertical image when the electronic device 100 is in a horizontal or vertical holding state. At this time, the control unit 160 may perform the first transformation or the second transformation depending on whether the area of the pillar box is needed. In other words, when a vertical video needs to be played by filling the pillar box area (for example, when the resolution of the original vertical video is insufficient and the converted horizontal or vertical video needs the pillar box area), the vertical video The second conversion may be performed. On the other hand, if there is no need to fill the pillar box area in the vertical image (for example, if the resolution of the original vertical image is sufficient and the pillar box area is unnecessary in the converted horizontal or vertical image), the first conversion is performed on the vertical image. It can be done.

도 3은 본 발명의 일 실시예에 따른 방법의 순서도를 나타낸다. Figure 3 shows a flowchart of a method according to one embodiment of the present invention.

본 발명의 일 실시예에 따른 방법은 전자 장치(100)에서 영상을 변환하여 재생하기 위한 방법으로서, 도 3에 도시된 바와 같이, S10 내지 S30을 포함한다. 이때, S10 내지 S30은 제어부(160)의 다양한 하드웨어 구성 또는 소프트웨어인 프로세스를 통해 그 수행이 제어할 수 있다.The method according to an embodiment of the present invention is a method for converting and playing back an image in the electronic device 100, and includes steps S10 to S30, as shown in FIG. 3. At this time, the performance of S10 to S30 can be controlled through various hardware configurations of the control unit 160 or software processes.

먼저, 제어부(160)는 전자 장치(100)의 파지 상태에 관련된 센서 값을 감지하여, 파지 상태를 파악한다(S10). 이때, 제어부(160)는 센서부(150)의 파지 상태 관련 센서로부터 감지된 센서 값을 이용하여, 전자 장치(100)의 파지 상태를 파악할 수 있다. 즉, 전자 장치(100)가 가로 파지 상태인지 세로 파지 상태인지를 파악할 수 있다. First, the control unit 160 detects sensor values related to the holding state of the electronic device 100 and determines the holding state (S10). At this time, the control unit 160 may determine the gripping state of the electronic device 100 using the sensor value detected from the gripping state-related sensor of the sensor unit 150. In other words, it is possible to determine whether the electronic device 100 is held horizontally or vertically.

이후, 제어부(160)는 파악된 파지 상태 및 영상이 가지는 영상비율에 따라, 영상에 대한 변환을 적응적으로 수행한다(S20). 즉, 제어부(160)는 파지 상태(즉, 가로 파지 상태/세로 파지 상태) 및 영상비율(즉, 가로 영상/세로 영상)의 여부에 따라, 제1 내지 제3 변환 중에 적어도 하나를 수행할 수 있다. 물론, S20의 수행 전에, 제어부(160)는 메모리(140)에 기 저장되거나 통신부(120)을 통해 수신된 영상이 가로 영상인지 세로 영상인지 여부에 대해서 파악하며, 이후에 S20을 수행할 수 있다.Thereafter, the control unit 160 adaptively performs conversion on the image according to the identified grip state and the image ratio of the image (S20). That is, the control unit 160 may perform at least one of the first to third transformations depending on the holding state (i.e., horizontal holding state/vertical holding state) and the image ratio (i.e., horizontal image/vertical image). there is. Of course, before performing S20, the control unit 160 determines whether the image pre-stored in the memory 140 or received through the communication unit 120 is a horizontal image or a vertical image, and then performs S20. .

이후, 제어부(160)는 제1 내지 제3 변환 중 적어도 하나가 수행된 영상을 재생하여 디스플레이(130)에서 표시되도록 제어한다(S30). Thereafter, the control unit 160 controls to reproduce the image on which at least one of the first to third transformations has been performed and display it on the display 130 (S30).

즉, 가로 파지 상태 및 가로 영상인 경우, 가로 영상에 대해 제1 변환 또는 제2 변환이 수행된 변환 가로 영상이 디스플레이(130)에 표시될 수 있다. 또한, 세로 파지 상태 및 가로 영상인 경우, 가로 영상에 대해 제3 변환이 수행된 고화질의 세로 영상이 디스플레이(130)에 표시될 수 있다. 이때, 확대 변환된 고화질의 세로 영상은, 도 11에 도시된 바와 같이, 전자 장치(100)의 디스플레이(140)의 모든 화소에서 재생될 수 있으나, 이에 한정되는 것은 아니다. 또한, 파지 상태와 상관없이 세로 영상인 경우, 세로 영상에 대해 제1 변환 또는 제2 변환이 수행된 변환 가로 또는 세로 영상이 디스플레이(130)에 표시될 수 있다.That is, in the case of a horizontal grip state and a horizontal image, the converted horizontal image in which the first or second conversion has been performed on the horizontal image may be displayed on the display 130. Additionally, in the case of a vertical grip state and a horizontal image, a high-definition vertical image obtained by performing a third transformation on the horizontal image may be displayed on the display 130. At this time, the enlarged and converted high-definition vertical image can be played in all pixels of the display 140 of the electronic device 100, as shown in FIG. 11, but is not limited to this. Additionally, in the case of a vertical image regardless of the grip state, a converted horizontal or vertical image obtained by performing the first or second conversion on the vertical image may be displayed on the display 130.

물론, S30에서, 제어부(160)는 제1 내지 제3 변환 중 적어도 하나가 수행된 영상의 재생 시에 해당 영상에 대한 오디오도 함께 동기화하여 전자 장치(100)에서 출력(재생)되도록 제어할 수 있다.Of course, in S30, when playing an image on which at least one of the first to third conversions has been performed, the controller 160 may synchronize the audio for the image and control it to be output (played) from the electronic device 100. there is.

<제1 변환><First transformation>

제1 변환을 수행할 경우, 제어부(160)는 영상에 대해 화질을 개선하면서 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 제1 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 생성된 확대 영상에 대한 크기 보간을 수행하여 파지 상태의 화면비율에 맞도록 변환할 수 있다.When performing the first conversion, the control unit 160 generates an enlarged image by applying a previously learned first machine learning model to improve the image quality and enlarge the image to an image larger than the screen size in the grasped state, and then generates an enlarged image. By performing size interpolation on the enlarged image, it can be converted to fit the screen ratio of the grip state.

도 4는 제어부(160)에 의해 수행되는 제1 변환에 대한 순서도를 나타내며, 도 5는 영상에 대한 다양한 확대에 대한 예시를 나타낸다. FIG. 4 shows a flow chart for the first transformation performed by the control unit 160, and FIG. 5 shows examples of various enlargements of an image.

구체적으로, 도 4를 참조하면, 제어부(160)는 제1 변환을 수행할 경우에 S101 내지 S104를 수행할 수 있다.Specifically, referring to FIG. 4 , the control unit 160 may perform steps S101 to S104 when performing the first conversion.

제어부(160)는 현재 변환 대상이 되는 영상(입력 영상)과 변환 후의 영상(목표 영상) 간의 화면비를 계산한다(S101). 이때, 목표 영상은 전자 장치(100)의 현재 파지 상태에 따른 영상이다.The control unit 160 calculates the aspect ratio between the image currently being converted (input image) and the image after conversion (target image) (S101). At this time, the target image is an image according to the current grip state of the electronic device 100.

즉, S101에서, 제어부(160)는 입력 영상의 가로 및 세로 화소 개수와, 목표 영상의 가로 및 세로 화소 개수를 파악하며, 파악된 각 화소 개수 간의 비율을 계산할 수 있다. 물론, 제어부(160)는 가로 비율(즉, 입력 영상 및 목표 영상 간의 가로 화소 개수 비율)과, 가로 비율(즉, 입력 영상 및 목표 영상 간의 세로 화소 개수 비율)을 계산할 수 있다. 예를 들어, 입력 영상이 320×240이고 목표 영상이 720×480인 경우, 제어부(160)는 가로/세로 비율을 각각 2.25/2으로 계산할 수 있다.That is, in S101, the control unit 160 can determine the number of horizontal and vertical pixels of the input image and the number of horizontal and vertical pixels of the target image, and calculate the ratio between each identified number of pixels. Of course, the control unit 160 may calculate the horizontal ratio (i.e., the ratio of the number of horizontal pixels between the input image and the target image) and the horizontal ratio (i.e., the ratio of the number of vertical pixels between the input image and the target image). For example, if the input image is 320×240 and the target image is 720×480, the control unit 160 may calculate the width/height ratio as 2.25/2, respectively.

이후, 제어부(160)는 가로/세로 확대 비율을 각각 설정한다(S102). 이때, 가로 확대 비율은 입력 영상에 대해 가로 방향에서 확대하기 위한 비율이며, 세로 확대 비율은 입력 영상에 대해 세로 방향에서 확대하기 위한 비율이다. 이러한 가로/세로 확대 비율은 S101에서 계산된 가로/세로 비율과 다를 수 있으며, 특히 S101에서 계산된 가로/세로 비율보다 크게 설정될 수 있다. 예를 들어, S101에서 가로/세로 비율이 각각 2.25/2로 계산된 경우, 제어부(160)는 가로 확대 비율을 2.25보다 크게 설정하고, 세로 확대 비율을 2보다 크게 설정할 수 있다.Afterwards, the control unit 160 sets the horizontal/vertical enlargement ratios respectively (S102). At this time, the horizontal enlargement ratio is a ratio for enlarging the input image in the horizontal direction, and the vertical enlargement ratio is a ratio for enlarging the input image in the vertical direction. This horizontal/height enlargement ratio may be different from the horizontal/height ratio calculated in S101, and in particular, it may be set larger than the horizontal/height ratio calculated in S101. For example, if the horizontal/height ratios are calculated to be 2.25/2 in S101, the control unit 160 may set the horizontal enlargement ratio to be greater than 2.25 and the vertical enlargement ratio to be greater than 2.

이후, 제어부(160)는 기 학습된 제1 머신 러닝 모델에 입력 영상 및 가로/세로 확대 비율을 입력함으로써, 입력 영상에 대해 화질을 개선하면서 가로/세로 확대 비율로 확대된 영상을 생성할 수 있다. 이때, 생성된 확대 영상은 목표 영상(즉, 현재 파지 상태의 화면 크기를 가지는 영상) 보다 큰 해상도의 영상이다.Thereafter, the control unit 160 inputs the input image and the horizontal/vertical magnification ratio to the previously learned first machine learning model, thereby improving the image quality of the input image and generating an image enlarged at the horizontal/vertical magnification ratio. . At this time, the generated enlarged image is an image with a higher resolution than the target image (i.e., an image having the screen size of the current grip state).

만일, 종래 기술을 적용하면, 영상이 단순히 일정 비율로 확대 변환되므로, 저해상도 등과 같이 화질 저하가 발생되어 사용자의 시각적 만족도는 낮아질 수밖에 없다. 이를 해결하기 위해, 본 발명에서는 제1 머신 러닝 모델을 이용함으로써, 입력 영상을 확대 변환하되 그 화질도 개선할 수 있다. 즉, 제1 머신 러닝 모델은 머신 러닝(machine learning) 기법에 따라 학습된 모델로서, 저화질 영상으로부터 화질 개선된 영상을 생성하되 입력된 가로/세로 확대 비율에 따라 확대된 영상을 생성하도록 학습된 모델이다. If the conventional technology is applied, the image is simply enlarged and converted at a certain rate, so image quality deteriorates, such as low resolution, and the user's visual satisfaction is inevitably lowered. To solve this problem, the present invention uses a first machine learning model to enlarge and convert the input image and improve its image quality. In other words, the first machine learning model is a model learned according to machine learning techniques, and is a model learned to generate images with improved quality from low-quality images and to generate images enlarged according to the input horizontal/vertical magnification ratio. am.

구체적으로, 제1 머신 러닝 모델은 입력 데이터 및 출력 데이터 쌍(데이터셋)의 학습 데이터를 통해 지도 학습(supervised learning)의 머신 러닝 기법에 따라 학습된 모델이다. 즉, 제1 머신 러닝 모델은 저화질 영상 및 가로/세로 확대 비율의 입력 데이터와, 가로/세로 확대 비율에 따라 확대되되 화질 개선된 영상의 출력 데이터를 포함하는 학습 데이터를 이용해 학습될 수 있다. 이에 따라, 제1 머신 러닝 모델은 입력 데이터인 저화질 영상 및 가로/세로 확대 비율과, 출력 데이터인 화질 개선된 확대 영상 간의 관계에 대한 함수를 가지며, 이를 다양한 파라미터를 이용해 표현한다. Specifically, the first machine learning model is a model learned according to the machine learning technique of supervised learning through training data of input data and output data pairs (dataset). That is, the first machine learning model can be learned using training data including input data of a low-quality image and a horizontal/vertical enlargement ratio, and output data of an image enlarged according to the horizontal/vertical enlargement ratio but with improved image quality. Accordingly, the first machine learning model has a function for the relationship between the low-quality image and horizontal/vertical enlargement ratio as input data and the enlarged image with improved image quality as output data, and expresses this using various parameters.

예를 들어, 제1 머신 러닝 모델은 가중치(Weights)와 편향치(Biases)의 파라미터를 이용해 저화질 영상과 화질 개선되면서 가로/세로 확대 비율로 확대된 영상 간의 관계를 표현할 수 있다. 이에 따라, 학습된 제1 머신 러닝 모델에 저화질의 입력 영상과 가로/세로 확대 비율의 입력 데이터가 입력되는 경우, 해당 함수에 따라 가로/세로 확대 비율로 확대되면서 화질 개선된 확대 영상의 출력 데이터가 출력될 수 있다.For example, the first machine learning model can use parameters of weights and biases to express the relationship between a low-quality image and an image enlarged at the horizontal/vertical magnification ratio with improved image quality. Accordingly, when a low-quality input image and input data with a horizontal/vertical magnification ratio are input to the learned first machine learning model, the output data of the enlarged image with improved image quality is enlarged at the horizontal/vertical magnification ratio according to the function. can be printed.

이때, 화질 개선 종류는 저화질 영상에 비해 해상도 증가, 노이즈 제거 및 다이나믹 레인지 증가 중 적어도 하나일 수 있다. 즉, 제1 머신 러닝 모델은 저화질 영상이 입력되면, 해상도 증가, 노이즈 제거 및 다이나믹 레인지 증가 중 어느 하나의 화질 개선 영상을 출력할 수 있다. 다만, 입력 영상이 확대 변환되어야 하므로, 해상도 증가는 반드시 포함되는 것이 바람직할 수 있다. 가령, 제1 머신 러닝 모델은 저화질 영상 및 가로/세로 확대 비율이 입력되면, 가로/세로 확대 비율로의 해상도 증가의 화질 개선 영상을 출력하거나, 가로/세로 확대 비율로의 해상도 증가 및 노이즈 제거의 화질 개선 영상을 출력하거나, 가로/세로 확대 비율로의 해상도 증가 및 다이나믹 레인지 증가의 화질 개선 영상을 출력할 수 있다.At this time, the type of image quality improvement may be at least one of increasing resolution, removing noise, and increasing dynamic range compared to low-quality images. That is, when a low-quality image is input, the first machine learning model can output an image with improved image quality in any one of increased resolution, removal of noise, and increased dynamic range. However, since the input image must be enlarged and converted, it may be desirable to include an increase in resolution. For example, when a low-quality image and a horizontal/vertical magnification ratio are input, the first machine learning model outputs an image with improved image quality by increasing the resolution at the horizontal/vertical magnification ratio, or increases resolution at the horizontal/vertical magnification ratio and removes noise. You can output an image with improved image quality, or an image with improved image quality with increased resolution and dynamic range in the horizontal/vertical magnification ratio.

이후, 제어부(160)는 S103에서 생성된 확대 영상에 대해 해상도 변형 기법을 적용하여 크기 보간을 수행함으로써, 전자 장치(100)의 현재 파지 상태의 화면비율에 맞는 영상으로 변환할 수 있다. 예를 들어, 해상도 변형 기법은 Bilinear, bicubic interpolation, down-sampling 등일 수 있으나, 이에 한정되는 것은 아니다. Thereafter, the control unit 160 may perform size interpolation by applying a resolution transformation technique to the enlarged image generated in S103, thereby converting it into an image that matches the screen ratio of the current grip state of the electronic device 100. For example, the resolution modification technique may be bilinear, bicubic interpolation, down-sampling, etc., but is not limited thereto.

특히, 도 5를 참조하면, 종래의 딥러닝 기반 화면 확대 기법의 경우, 가로/세로에 대해 고정 비율로만 확대가 가능한 제약이 있다. 이러한 제약을 개선하기 위해, 본 발명은 가로/세로 확대 비율을 목표 영상의 해상도 보다 크게 설정하여, 제1 머신 러닝 모델을 통해 목표 영상보다 큰 영상을 생성하며, 이후 전통적인 해상도 변형 기법(Bilinear, bicubic interpolation, down-sampling 등)을 추가적으로 적용하여 크기 보간을 수행함으로써 생성된 확대 영상에 대한 미세한 화면비율의 보정이 가능하다.In particular, referring to Figure 5, in the case of the conventional deep learning-based screen enlargement technique, there is a limitation that enlargement can only be done at a fixed ratio for width and height. In order to improve this limitation, the present invention sets the horizontal/vertical magnification ratio to be larger than the resolution of the target image, generates an image larger than the target image through a first machine learning model, and then uses traditional resolution transformation techniques (Bilinear, bicubic By additionally applying size interpolation (interpolation, down-sampling, etc.), it is possible to finely correct the screen ratio of the generated enlarged image.

<제2 변환><Second Transformation>

한편, 제2 변환을 수행할 경우, 제어부(160)는 이전 및 이후 프레임 영상을 이용하여 대응점 매칭 기반으로 현재 프레임 영상에 새로운 영상 내용을 합성함으로써, 현재 프레임 영상을 확대 변환할 수 있다. 물론, 이와 같이 확대 변환된 현재 프레임 영상이 목표 영상의 해상도에 미달하는 경우, 제어부(160)는 해당 현재 프레임 영상에 대해 생성적 적대 신경망(Generative Adversarial Network; GAN) 기반의 경계 확장 기법(border extension)을 적용함으로써, 해당 현재 프레임 영상에 새로운 영상 내용을 합성할 수 있다.Meanwhile, when performing the second conversion, the control unit 160 can enlarge and convert the current frame image by combining new image content with the current frame image based on corresponding point matching using the previous and next frame images. Of course, if the current frame image enlarged and converted in this way is less than the resolution of the target image, the control unit 160 uses a border extension technique (border extension) based on a generative adversarial network (GAN) for the current frame image. ), new video content can be synthesized into the current frame video.

도 6은 제어부(160)에 의해 수행되는 제2 변환에 대한 순서도를 나타내며, 도 7은 제2 변환에 대한 예시를 나타낸다. 도 7에서, F(N)은 현재 프레임 영상이고, F(N-1)은 이전 프레임 영상이며, F(N+1)은 이후 프레임 영상이다.FIG. 6 shows a flow chart for the second conversion performed by the control unit 160, and FIG. 7 shows an example of the second conversion. In Figure 7, F(N) is the current frame image, F(N-1) is the previous frame image, and F(N+1) is the next frame image.

구체적으로, 도 6을 참조하면, 제어부(160)는 제2 변환을 수행할 경우에 S201 내지 S202을 수행할 수 있다.Specifically, referring to FIG. 6 , the control unit 160 may perform steps S201 to S202 when performing the second conversion.

즉, 제어부(160)는 F(N-1), F(N) 및 F(N+1)을 이용하여, F(N-1) 또는 F(N+1)에 포함된 새로운 영상 내용을 F(N)에 추가함으로써 F'(N)을 합성할 수 있다(S201). 이때, 제어부(160)는 F(N)에서 매칭되는 F(N-1) 및 F(N+1)의 대응점을 찾아 해당 대응점에 따른 F(N-1) 또는 F(N+1)의 일부 영상을 F(N)에 추가하여 F(N)'을 생성할 수 있다. 즉, F(N-1) 및 F(N+1)에서 F(N)와 중첩되는 부분을 제외한 나머지 부분 중의 일부 영상을 F(N)에 추가하는 기하학적 합성을 수행할 수 있다.That is, the control unit 160 uses F(N-1), F(N), and F(N+1) to change the new image content included in F(N-1) or F(N+1) to F. F'(N) can be synthesized by adding to (N) (S201). At this time, the control unit 160 finds the corresponding points of F(N-1) and F(N+1) that match in F(N), and a part of F(N-1) or F(N+1) according to the corresponding points. You can create F(N)' by adding an image to F(N). In other words, geometric synthesis can be performed by adding some images from the remaining portions of F(N-1) and F(N+1), excluding the portion overlapping with F(N), to F(N).

이후, 만일 F(N) 보다 큰 해상도를 갖는 F'(N)이 목표 영상의 해상도에 미달하는 경우, 제어부(160)는 F'(N)에 대해 GAN 기반의 경계 확장을 수행하여 새로운 영상 내용을 F'(N)에 추가함으로써 F''(N)을 합성할 수 있다(S202). 즉, 제어부(160)는 GAN 기법에 따라 기 학습된 GAN 모델에 F'(N)을 입력함으로써, F'(N)의 가장자리 부분의 영상을 더 확장하는 F''(N)을 생성할 수 있다.Afterwards, if F'(N), which has a resolution greater than F(N), falls short of the resolution of the target image, the control unit 160 performs GAN-based boundary expansion on F'(N) to create new image contents. F''(N) can be synthesized by adding to F'(N) (S202). That is, the control unit 160 can generate F''(N) that further expands the image of the edge portion of F'(N) by inputting F'(N) into the GAN model previously learned according to the GAN technique. there is.

이러한 GAN 기법은 미리 정의된 2개의 네트워크 모델인 생성기(G)와 분류기(D)를 이용한 방식이다. 즉, 분류기(D)를 먼저 학습시킨 후, 생성기(G)를 학습시키며, 서로의 결과를 주고받으면서 반복 학습시키는 방식으로서, 생성기(G)와 분류기(D)가 서로 경쟁하여 조금씩 학습되는 방식이다. 이때, 분류기(D)의 경우, 실제 입력 영상(진짜 데이터)을 입력 받아 해당 입력 영상이 실제(진짜)인 것으로 분류하도록 학습시킨 후, 이와 반대로 생성기(G)에서 생성한 합성 입력 영상(가짜 데이터)을 입력 받아 해당 입력 영상이 합성(가짜)인 것으로 분류하도록 학습될 수 있다.This GAN technique uses two predefined network models, a generator (G) and a classifier (D). In other words, it is a method of learning the classifier (D) first, then the generator (G), and learning repeatedly by exchanging results with each other. This is a method in which the generator (G) and classifier (D) compete with each other and learn little by little. . At this time, in the case of the classifier (D), it receives the actual input image (real data) and learns to classify the input image as real (real), and then, on the contrary, the synthetic input image (fake data) generated by the generator (G) ) can be input and learned to classify the input image as synthetic (fake).

특히, 생성기(G)의 경우, 어떤 입력 영상을 입력 받아 그 입력 영상의 가장자리 부분을 확장한 영상을 생성하도록 학습될 수 있다. 이때, 생성기(G)에서 생성한 가짜 데이터를 판별기(D)에 입력하고, 가짜 데이터를 진짜라고 분류할 만큼 진짜 데이터와 유사한 데이터를 만들어 내도록 생성기(G)를 학습시킬 수 있다. 이와 같이 충분히 학습된 생성기(G)를 GAN 모델로 사용하여 F'(N)을 입력함으로써 F''(N)을 생성할 수 있다.In particular, in the case of the generator (G), it can be trained to receive an input image and generate an image that expands the edges of the input image. At this time, fake data generated by the generator (G) can be input into the discriminator (D), and the generator (G) can be trained to produce data similar to real data enough to classify the fake data as real. In this way, F''(N) can be generated by using the sufficiently learned generator (G) as a GAN model and inputting F'(N).

예를 들어, GAN 기법은 일반적인 GAN 외에도, DCGAN(Deep Convolutional GAN), LSGAN(Least Squares GAN), SGAN(Semi-Supervised GAN), ACGAN(Auxiliary Classifier GAN), WGAN(Wasserstein Generative Adversarial Networks, ConGAN(Continuous GAN), cGAN(Conditional GAN), SNcGAN(Spectral Normalization Conditional GAN), starGAN 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.For example, in addition to general GAN, GAN techniques include DCGAN (Deep Convolutional GAN), LSGAN (Least Squares GAN), SGAN (Semi-Supervised GAN), ACGAN (Auxiliary Classifier GAN), WGAN (Wasserstein Generative Adversarial Networks), and ConGAN (Continuous GAN), cGAN (Conditional GAN), SNcGAN (Spectral Normalization Conditional GAN), starGAN, etc., but are not limited thereto.

<제3 변환><The Third Transformation>

다음으로, 제3 변환을 수행할 경우, 제어부(160)는 세로 파지 상태에서 재생 가능하도록 가로 영상에 대해 다양한 영상처리를 수행한다. 즉, 제어부(160)는 가로 영상에 대해 가로 영상의 내용에서 적어도 일부분을 화질 개선하면서 확대하되 세로 영상으로 확대하도록 변환할 수 있다. 가령, 제어부(160)은 가로 영상에 대해 그 주요 컨텐츠 부분을 남기고 나머지를 잘라내어, 세로 영상으로 변경하고, 변경된 세로 영상을 세로 파지 상태의 화면 크기에 맞게 확대 변환할 수 있다.Next, when performing the third transformation, the control unit 160 performs various image processing on the horizontal image so that it can be played in a vertical holding state. That is, the control unit 160 can convert the horizontal image to enlarge at least a portion of the content of the horizontal image to a vertical image while improving image quality. For example, the control unit 160 can change the horizontal image into a vertical image by cutting out the remaining main content portion, and enlarging and converting the changed vertical image to fit the screen size in the vertically held state.

도 8은 제어부(160)에 의해 수행되는 제3 변환에 대한 순서도를 나타낸다.Figure 8 shows a flowchart for the third conversion performed by the control unit 160.

구체적으로, 도 8을 참조하면, 제어부(160)는 제3 변환을 수행할 경우에 S310 내지 S340을 수행할 수 있다. 물론, S310과 S320는 그 순서가 바뀌거나 동시에 병렬 수행될 수도 있다.Specifically, referring to FIG. 8, the control unit 160 may perform steps S310 to S340 when performing the third conversion. Of course, the order of S310 and S320 may be changed or performed in parallel at the same time.

먼저, 제어부(160)는 가로 영상에 대해 프레임 영상마다 해당 프레임 영상의 컨텐츠를 분석하여 해당 프레임 영상의 일부에 해당하는 재생 영역을 산출한다(S310). 즉, 제어부(160)는 가로 영상에 대해서 영상 컨텐츠 분석을 수행함으로써 재생 영역을 산출할 수 있다.First, the control unit 160 analyzes the content of the frame image for each frame image of the horizontal image and calculates a playback area corresponding to a portion of the frame image (S310). That is, the control unit 160 can calculate the playback area by performing image content analysis on the horizontal image.

이때, 재생 영역은 가로 영상에 대해 프레임 영상마다 산출되는데, 해당 프레임 영상 중에 일부 영역으로서, 해당 프레임 영상의 주요 컨텐츠에 해당하는 영역이다. 가령, 전자 장치(100)가 세로 파지 상태에서의 재생을 위해 가로 영상 일부를 잘라내어 세로 영상으로 변경할 때, 그 가로 영상에서 해당 재생 영역은 주요 컨텐츠이므로 잘리지 않고 나머지 부분만이 잘려진다. 즉, 재생 영역은 전자 장치(100)에서 가로 영상을 세로 영상으로 변경 시에 세로 영상 내에 포함되어야 하는 영역으로 참조될 수 있다.At this time, the playback area is calculated for each frame image for the horizontal image, and is a partial area in the corresponding frame image, and is an area corresponding to the main content of the corresponding frame image. For example, when the electronic device 100 cuts out part of the horizontal image and changes it to a vertical image for playback in a vertical holding state, the corresponding playback area in the horizontal image is the main content, so it is not cut out and only the remaining portion is cut out. That is, the playback area may be referred to as an area that must be included in the vertical image when changing a horizontal image to a vertical image in the electronic device 100.

가령, 가로 영상이 1000개의 프레임을 가진다면, 1000개 프레임에 대해 각각 하나씩 적용되는 1000개의 재생 영역에 대한 정보가 산출될 수 있다.For example, if a horizontal image has 1000 frames, information on 1000 playback areas, one for each 1000 frames, can be calculated.

도 9는 제3 변환에서 S310에 대한 보다 상세한 순서도를 나타낸다.Figure 9 shows a more detailed flow chart for S310 in the third transformation.

구체적으로, 도 9를 참조하면, 제어부(160)는 가로 영상의 각 프레임 영상에서 객체와 얼굴에 대한 영역을 각각 검출한다(S311). 이때, 제어부(160)는 객체 검출기 및 얼굴 검출기를 이용하여 각 프레임 영상에서 객체에 대한 영역과 얼굴에 대한 영역을 검출할 수 있다. 즉, 객체 검출기는 주요 사물을 검출할 수 있으며, 얼굴 검출기는 주요 등장 인물의 얼굴을 검출할 수 있다. 이때, 각 검출기는 객체 탐지(object detection)에 관련된 다양한 알고리즘을 적용하여 각 영역을 검출하는 것으로서, 메모리(140)에 저장될 수 있다. Specifically, referring to FIG. 9, the control unit 160 detects areas for objects and faces in each frame image of the horizontal image (S311). At this time, the control unit 160 may detect an area for an object and an area for a face in each frame image using an object detector and a face detector. That is, the object detector can detect key objects, and the face detector can detect the faces of key characters. At this time, each detector detects each area by applying various algorithms related to object detection, and may be stored in the memory 140.

예를 들어, 각 검출기는 Canny Edger, Harris corner, Haar-like feature, HOG(Histogram of Oriented Gradient), SIFT(Scale Invariant Feature Transform), 또는 머신 러닝 모델 등을 이용한 검출기일 수 있으며, 이에 한정되는 것은 아니다.For example, each detector may be a detector using Canny Edger, Harris corner, Haar-like feature, HOG (Histogram of Oriented Gradient), SIFT (Scale Invariant Feature Transform), or machine learning model, but is limited thereto. no.

이후, 제어부(160)는 검출된 각 영역을 포함하는 영역(이하, “최대 재생 영역”이라 지칭함)을 산출한다(S312). 즉, S311에서 검출된 각 영역은 재생 영역이 될 수 있는 후보 영역에 해당하므로, 이들을 모두 포함하는 최대 재생 영역을 산출한다. 가령, S311에서 검출된 영역이 복수개인 경우, 각 검출된 영역은 최대 재생 영역에 모두 포함될 수 있다.Afterwards, the control unit 160 calculates an area (hereinafter referred to as “maximum playback area”) including each detected area (S312). That is, since each area detected in S311 corresponds to a candidate area that can be a playback area, the maximum playback area including all of them is calculated. For example, if there are multiple areas detected in S311, each detected area may be included in the maximum playback area.

특히, S311에서 하나의 검출기 대신 객체 검출기 및 얼굴 검출기를 함께 사용하고, S312에서 각 검출 영역을 모두 포함하도록 최대 재생 영역을 산출함으로써, 본 발명은 각 프레임 영상에 대한 영상 컨텐츠 분석의 정확성을 더욱 높일 수 있다.In particular, by using an object detector and a face detector instead of a single detector in S311 and calculating the maximum playback area to include all detection areas in S312, the present invention further improves the accuracy of video content analysis for each frame image. You can.

이후, 제어부(160)는 산출된 최대 재생 영역에 대한 잘라내기 과정을 통해 세로 영상의 영상비율을 가지는 재생 영역을 각 프레임에서 산출한다(S313). 즉, 전자 장치(100)가 가질 수 있는 세로 파지 상태의 화면비율의 종류(1:1, 4:5, 9:16, 10:21 등)를 고려하여, 해당 화면비율에 맞도록 최대 재생 영역에 대해 잘라내기 과정을 수행한다. 물론, 전자 장치(100)가 가질 수 있는 세로 파지 상태의 화면비율은 세로가 가로보다 긴 화면비율인 것 외에 세로와 가로가 동일한 화면비율일 수도 있다.Thereafter, the control unit 160 calculates a playback area having the aspect ratio of the vertical image in each frame through a cropping process for the calculated maximum playback area (S313). That is, considering the type of screen ratio (1:1, 4:5, 9:16, 10:21, etc.) in the vertical holding state that the electronic device 100 can have, the maximum playback area is set to fit the screen ratio. Perform the cut process for . Of course, the screen ratio that the electronic device 100 can have in a vertically held state may be a screen ratio where the height is longer than the width, and the screen ratio where the height and width are the same.

예를 들어, 잘라내기 과정은 최대 재생 영역의 일정 영역을 중심으로(가령, 특정 종류의 객체 또는 얼굴에 대한 영역을 중심으로) 그 외의 영역부터 잘라내도록 해당 과정이 수행될 수 있으나, 이에 한정되는 것은 아니다.For example, the cutting process may be performed to cut out a certain area of the maximum playback area (e.g., an area for a specific type of object or face) and other areas, but is limited to this. That is not the case.

이후, 제어부(160)는 가로 영상을 다수의 소단위로 분리하고 영상의 컨텐츠 종류 별로 기 학습되어 메모리(140)에 기 저장된 다수의 AI 모델 중에서 해당 소단위 내 가로 영상의 컨텐츠에 따라 소단위 별로 적용되는 최적 AI 모델을 선택한다(S320).Afterwards, the control unit 160 divides the horizontal image into a plurality of subunits and selects the optimal model applied to each subunit according to the content of the horizontal image within the subunit among the plurality of AI models pre-learned for each content type of the image and stored in the memory 140. Select an AI model (S320).

이때, 제어부(160)는 다양한 장면 전환 검출(scene change detection) 알고리즘을 이용하여, 가로 영상을 다수의 소단위로 분리할 수 있다. 가령, 제어부(160)는 이웃한 프레임 간의 차이 값을 계산하고 계산된 차이 값이 특정 기준치 보다 클 경우에 샷 전환이 이루어진 것으로 판단하여, 각 소단위를 구분할 수 있다.At this time, the control unit 160 may separate the horizontal image into multiple small units using various scene change detection algorithms. For example, the control unit 160 may calculate the difference value between neighboring frames and determine that a shot change has occurred when the calculated difference value is greater than a specific reference value, thereby distinguishing each subunit.

물론, 분리된 각 소단위에 포함된 프레임 개수는 일정하지 않을 수 있다. 즉, 제1 소단위의 프레임 개수와 제2 소단위 프레임 개수는 같거나 다를 수 있다. 예를 들어, 소단위는 샷(shot), 씬(scene) 또는 시퀀스(sequence) 등에 따라 나눠질 수 있으나, 이에 한정되는 것은 아니다. 다만, 소단위는 프레임 보다 큰 단위인 것이 바람직할 수 있다. 즉, 각 소단위는 복수개의 프레임을 포함할 수 있다.Of course, the number of frames included in each separated subunit may not be constant. That is, the number of frames of the first subunit and the number of frames of the second subunit may be the same or different. For example, subunits may be divided according to shots, scenes, or sequences, but are not limited to this. However, it may be desirable for the small unit to be a unit larger than the frame. That is, each subunit may include a plurality of frames.

한편, AI 모델은 변경된 세로 영상을 전자 장치(100)의 화면 크기에 맞게 확대 변환할 때 적용되는 모델이다. 만일, 종래 기술을 적용하면, 변경된 세로 영상이 단순히 일정 비율로 확대 변환되므로, 저해상도 등과 같이 화질 저하가 발생되어 사용자의 시각적 만족도는 낮아질 수밖에 없다. 이를 해결하기 위해, 본 발명에서는 AI 모델을 이용함으로써, 세로 영상으로 확대 변환하되 그 화질도 개선할 수 있다. 즉, AI 모델은 머신 러닝(machine learning) 기법에 따라 학습된 머신 러닝 모델로서, 저화질 영상으로부터 화질 개선된 확대 영상을 생성하도록 학습된 모델이다. Meanwhile, the AI model is a model applied when enlarging and converting a changed vertical image to fit the screen size of the electronic device 100. If the conventional technology is applied, the changed vertical image is simply enlarged and converted at a certain rate, so image quality deteriorates, such as low resolution, and the user's visual satisfaction is inevitably lowered. To solve this problem, in the present invention, by using an AI model, it is possible to enlarge and convert a vertical image and improve the image quality. In other words, the AI model is a machine learning model learned according to machine learning techniques, and is a model learned to generate enlarged images with improved quality from low-quality images.

구체적으로, AI 모델은 입력 데이터 및 출력 데이터 쌍(데이터셋)의 학습 데이터를 통해 지도 학습(supervised learning)의 머신 러닝 기법에 따라 학습된 머신 러닝 모델이다. 즉, AI 모델은 저화질 영상의 입력 데이터와 화질 개선된 확대 영상의 출력 데이터를 포함하는 학습 데이터를 이용해 학습될 수 있다. 이에 따라, AI 모델은 입력 데이터인 저화질 영상과 출력 데이터인 화질 개선된 확대 영상 간의 관계에 대한 함수를 가지며, 이를 다양한 파라미터를 이용해 표현한다. Specifically, the AI model is a machine learning model learned according to the machine learning technique of supervised learning through training data of input data and output data pairs (datasets). In other words, the AI model can be learned using training data including input data of low-quality images and output data of enlarged images with improved quality. Accordingly, the AI model has a function for the relationship between the low-quality image as input data and the enlarged image with improved quality as output data, and expresses this using various parameters.

예를 들어, AI 모델은 가중치(Weights)와 편향치(Biases)의 파라미터를 이용해 저화질 영상과 화질 개선된 확대 영상 간의 관계를 표현할 수 있다. 이에 따라, 학습된 AI 모델에 저화질 영상(가령, 변경된 세로 영상)의 입력 데이터가 입력되는 경우, 해당 함수에 따른 화질 개선된 확대 영상(가령, 전자 장치(100)의 화면 크기만큼 확대되되 고화질로 변환된 세로 영상)의 출력 데이터가 출력될 수 있다.For example, an AI model can express the relationship between low-quality images and enlarged images with improved quality using parameters of weights and biases. Accordingly, when input data of a low-quality image (e.g., a changed vertical image) is input to the learned AI model, an enlarged image with improved image quality according to the function (e.g., enlarged to the screen size of the electronic device 100 but in high definition) Output data of the converted vertical video may be output.

이때, 화질 개선 종류는 저화질 영상에 비해 해상도 증가, 노이즈 제거 및 다이나믹 레인지 증가 중 적어도 하나일 수 있다. 즉, AI 모델은 저화질 영상이 입력되면, 해상도 증가, 노이즈 제거 및 다이나믹 레인지 증가 중 어느 하나의 화질 개선 영상을 출력할 수 있다. 다만, 세로 영상이 확대 변환되어야 하므로, 해상도 증가는 반드시 포함되는 것이 바람직할 수 있다. 가령, AI 모델은 저화질 영상이 입력되면, 해상도 증가의 화질 개선 영상을 출력하거나, 해상도 증가 및 노이즈 제거의 화질 개선 영상을 출력하거나, 해상도 증가 및 다이나믹 레인지 증가의 화질 개선 영상을 출력할 수 있다.At this time, the type of image quality improvement may be at least one of increasing resolution, removing noise, and increasing dynamic range compared to low-quality images. In other words, when a low-quality image is input, the AI model can output an image with improved image quality in any one of increased resolution, removal of noise, and increased dynamic range. However, since the vertical image must be enlarged and converted, it may be desirable to include an increase in resolution. For example, when a low-quality image is input, the AI model can output an image with improved image quality with increased resolution, an image with improved image quality with increased resolution and noise removal, or an image with improved image quality with increased resolution and increased dynamic range.

한편, AI 모델은 복수개가 메모리(140) 또는 전자 장치(100)가 접속하는 다른 장치에 저장될 수 있다. 이때, 각 AI 모델은 세로 영상이 그 컨텐츠 종류에 따라 학습된 모델일 수 있다. 예를 들어, 영상의 컨텐츠 종류는 스포츠(sports), 드라마(drama), 게임(game), 뉴스(news), 교육(education), 예능(entertainment) 등일 수 있으나, 이에 한정되는 것은 아니다.Meanwhile, a plurality of AI models may be stored in the memory 140 or another device connected to the electronic device 100. At this time, each AI model may be a model learned based on the type of vertical video content. For example, the content type of the video may be sports, drama, game, news, education, entertainment, etc., but is not limited thereto.

즉, 각 AI 모델은 서로 다른 종류의 컨텐츠를 가지는 영상을 기반으로 학습될 수 있다. 이와 같이 영상 컨텐츠 종류에 따라 다양하게 적용되는 다수의 AI 모델을 제공함으로써, 변경된 세로 영상을 확대 변환 시에 해당 화질 개선의 효율을 더욱 향상시킬 수 있는 이점이 있다.In other words, each AI model can be learned based on images with different types of content. In this way, by providing a number of AI models that are applied in various ways depending on the type of video content, there is an advantage in that the efficiency of image quality improvement can be further improved when enlarging and converting a changed vertical video.

가령, 제어부(160)는 가로 영상을 샷(shot) 단위로 분리하고, 분리된 샷(shot) 내에 포함된 연속된 프레임 영상에 대한 정보를 입력으로 받아 샷(shot) 별로 최적 AI 모델을 선택할 수 있다. For example, the control unit 160 can separate the horizontal image into shots, receive information about consecutive frame images included in the separated shots as input, and select the optimal AI model for each shot. there is.

도 10은 S320에서 최적 AI 모델을 선택하는 일 예를 나타낸다.Figure 10 shows an example of selecting an optimal AI model in S320.

도 10을 참조하면, 제어부(160)는 분류기(classifier)를 이용하여 최적 AI 모델을 선택할 수 있다. 즉, 분류기는 입력 데이터 및 출력 데이터 쌍(데이터셋)의 학습 데이터를 통해 지도 학습(supervised learning)의 머신 러닝 기법에 따라 학습된 제2 머신 러닝 모델이다.Referring to FIG. 10, the control unit 160 can select the optimal AI model using a classifier. In other words, the classifier is a second machine learning model learned according to the machine learning technique of supervised learning through the training data of the input data and output data pair (dataset).

이때, 분류기는 연속된 프레임 영상의 입력 데이터와 이들 프레임 영상의 컨텐츠 종류(예를 들어, 스포츠, 드라마, 게임, 뉴스, 교육, 예능 등)에 대한 출력 데이터를 포함하는 학습 데이터를 이용해 학습될 수 있다. 이에 따라, 분류기는 입력 데이터인 연속된 프레임 영상과 출력 데이터인 컨텐츠 종류 간의 관계에 대한 함수를 가지며, 이를 다양한 파라미터를 이용해 표현한다. At this time, the classifier can be learned using learning data including input data of continuous frame images and output data for the content type of these frame images (e.g., sports, drama, game, news, education, entertainment, etc.). there is. Accordingly, the classifier has a function for the relationship between the continuous frame image as input data and the content type as output data, and expresses this using various parameters.

예를 들어, 분류기는 가중치(Weights)와 편향치(Biases)의 파라미터를 이용해 연속된 프레임 영상과 이들 프레임 영상의 컨텐츠 종류 간의 관계를 표현할 수 있다. 이에 따라, 도 10에 도시된 바와 같이, 학습된 분류기에 어떤 소단위 내의 연속된 프레임 영상(F(t-1), F(t), F(t+1))의 입력 데이터가 입력되는 경우, 해당 함수에 따른 해당 소단위의 영상들(F(t-1), F(t), F(t+1))의 컨텐츠 종류에 대한 출력 데이터가 출력될 수 있다.For example, a classifier can express the relationship between consecutive frame images and the content types of these frame images using parameters of weights and biases. Accordingly, as shown in Figure 10, when input data of consecutive frame images (F(t-1), F(t), F(t+1)) within a certain subunit is input to the learned classifier, Output data for the content type of the corresponding subunit images (F(t-1), F(t), and F(t+1)) according to the function may be output.

예를 들어, AI 모델, 제1 머신 러닝 모델 및 제2 머신 러닝 모델(분류기)에 적용되는 머신 러닝 기법은 Artificial neural network, Boosting, Bayesian statistics, Decision tree, Gaussian process regression, Nearest neighbor algorithm, Support vector machine, Random forests, Symbolic machine learning, Ensembles of classifiers, 또는 Deep learning 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.For example, machine learning techniques applied to the AI model, first machine learning model, and second machine learning model (classifier) include Artificial neural network, Boosting, Bayesian statistics, Decision tree, Gaussian process regression, Nearest neighbor algorithm, Support vector It may include, but is not limited to, machine, random forests, symbolic machine learning, ensembles of classifiers, or deep learning.

특히, AI 모델, 제1 머신 러닝 모델 및 제2 머신 러닝 모델이 딥 러닝(Deep learning) 기법에 의해 학습된 딥 러닝 모델일 경우, 입력 데이터와 출력 데이터 간의 관계를 다수의 층(레이어)으로 표현하며, 이러한 다수의 표현층을 “신경망(neural network)”라 지칭하기도 한다. 이러한 딥 러닝 모델은 본 발명과 같은 영상처리 분야에서 고무적인 성능을 가질 수 있다.In particular, when the AI model, the first machine learning model, and the second machine learning model are deep learning models learned using deep learning techniques, the relationship between input data and output data is expressed as multiple layers. These multiple representation layers are also referred to as “neural networks.” Such deep learning models can have encouraging performance in image processing fields such as the present invention.

예를 들어, 딥 러닝 기법은 Deep Neural Network(DNN), Convolutional Neural Network(CNN), Recurrent Neural Network(RNN), Restricted Boltzmann Machine(RBM), Deep Belief Network(DBN), Deep Q-Networks 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.For example, deep learning techniques include Deep Neural Network (DNN), Convolutional Neural Network (CNN), Recurrent Neural Network (RNN), Restricted Boltzmann Machine (RBM), Deep Belief Network (DBN), Deep Q-Networks, etc. It can be done, but it is not limited to this.

특히, 소단위(예를 들어, 샷 등) 내의 영상에 대해 새롭게 AI 모델을 생성하려는 경우, 그 학습 과정이 오래 걸리므로 실시간 전송에 적합하지 않다. 이에 따라, 본 발명에서는 영상의 컨텐츠 종류에 따라 미리 학습해 둔 다수의 AI 모델(즉, AI 모델 DB)을 메모리(140) 또는 별도의 데이터베이스 장치에 기 저장하고, 제어부(160)가 현재 소단위에 적합한 최적 AI 모델을 AI 모델 DB에서 검색하여 사용한다. 즉, 제어부(160)는 어떤 소단위의 연속된 프레임 영상의 입력에 대해 분류기가 출력하는 컨텐츠 종류에 매칭되는 AI 모델을 기 저장된 AI 모델 DB에서 검색하여 검색된 AI 모델을 해당 소단위에 적용되는 최적 AI 모델로 선택할 수 있다. 그 결과, 본 발명은 영상의 실시간 재생에 보다 부합될 수 있는 이점이 있다.In particular, when trying to create a new AI model for an image within a small unit (for example, a shot, etc.), the learning process takes a long time, so it is not suitable for real-time transmission. Accordingly, in the present invention, a number of AI models (i.e., AI model DB) learned in advance according to the type of video content are stored in the memory 140 or a separate database device, and the control unit 160 controls the current small unit. The optimal suitable AI model is searched and used in the AI model DB. That is, the control unit 160 searches the pre-stored AI model DB for an AI model that matches the type of content output by the classifier for the input of a continuous frame image of a certain subunit, and uses the searched AI model as the optimal AI model applied to the subunit. You can select . As a result, the present invention has the advantage of being more suitable for real-time playback of video.

또한, AI 모델이 영상의 컨텐츠 종류에 맞게 학습된 것이므로, 동일 컨텐츠 종류의 일련의 장면에 대한 단위인 샷 단위 또는 씬 단위로 나눠지는 경우가 보다 효과적일 수 있다.Additionally, since the AI model is learned according to the type of video content, it may be more effective to divide it into shot units or scene units, which are units for a series of scenes of the same content type.

이후, 제어부(160)는 S310에서 산출된 재생 영역을 기반으로 가로 영상에서 세로 영상을 프레임 영상마다 추출한다(S330). 즉, 가로 영상의 각 프레임 영상에서 해당 프레임의 재생 영역에 해당하는 부분을 남기고 그 나머지를 제거함으로써 해당 프레임의 세로 영상을 추출할 수 있다.Thereafter, the control unit 160 extracts the vertical image for each frame image from the horizontal image based on the playback area calculated in S310 (S330). In other words, the vertical image of the frame can be extracted by removing the remainder from each frame of the horizontal image, leaving a portion corresponding to the playback area of the frame.

제어부(160)는 가로 영상의 각 프레임 영상에서 해당 프레임의 재생 영역에 해당하는 부분을 남기고 그 나머지를 제거함으로써 해당 프레임의 세로 영상을 추출할 수 있다.The control unit 160 can extract the vertical image of the frame by removing the remainder from each frame of the horizontal image, leaving a portion corresponding to the playback area of the frame.

이후, 제어부(160)는 S320에서 선택된 최적 AI 모델 정보에 따른 AI 모델을 소단위 별로 적용하여, S330에서 추출된 세로 영상을 확대 변환한다(S340). 즉, 제어부(160) S330에서 분리된 저화질 영상인 세로 영상을 AI 모델에 입력한다. 그 결과, AI 모델은 내장된 함수에 따른 화질 개선된 확대 영상, 즉 전자 장치(100)의 디스플레이(140)의 크기만큼 확대되되 고화질의 세로 영상을 출력할 수 있다. Thereafter, the control unit 160 applies the AI model according to the optimal AI model information selected in S320 for each subunit and enlarges and converts the vertical image extracted in S330 (S340). That is, the vertical image, which is a low-quality image separated from the control unit 160 S330, is input to the AI model. As a result, the AI model can output an enlarged image with improved image quality according to the built-in function, that is, a vertical image enlarged to the size of the display 140 of the electronic device 100 but with high definition.

물론, 필요할 경우, 제어부(160)는 AI 모델에서 출력되면서 확대 변환된 고화질의 세로 영상의 일부를 자르는 과정의 영상처리를 수행하거나 해상도 변형 기법에 따른 크기 보간을 수행할 수도 있다. 이는 확대 변환된 고화질의 세로 영상이 전자 장치(100)의 디스플레이(140) 보다 클 경우에 수행될 수 있다. 예를 들어, 해상도 변형 기법은 Bilinear, bicubic interpolation, down-sampling 등일 수 있으나, 이에 한정되는 것은 아니다.Of course, if necessary, the control unit 160 may perform image processing by cutting a portion of the high-definition vertical image output from the AI model and enlarged and converted, or may perform size interpolation according to a resolution transformation technique. This can be performed when the enlarged high-definition vertical image is larger than the display 140 of the electronic device 100. For example, the resolution modification technique may be bilinear, bicubic interpolation, down-sampling, etc., but is not limited thereto.

도 11은 세로 파지 상태의 전자 장치에서 가로 영상을 재생하는 예를 비교하여 나타낸다. 즉, 좌측이 종래 기술에 따라 재생되는 영상이며, 우측이 본 발명에 따라 재생되는 영상이다.Figure 11 shows a comparison example of playing a horizontal image in an electronic device held vertically. That is, the left side is an image played according to the prior art, and the right side is an image played according to the present invention.

도 11을 참조하면, 가로 영상을 세로 파지 상태의 단말에서 재생 시, 본 발명은 종래 기술과 달리, 레터 박스 또는 필러를 최소화할 수 있을 뿐 아니라, 그 영상의 주요 객체를 포함하면서 확대하되, 확대하면서 발생하는 저화질의 문제를 개선한 고화질의 세로 영상으로 재생할 수 있다. 그 결과, 본 발명은 사용자의 시각적 만족도를 높일 수 있는 이점이 있다. Referring to FIG. 11, when playing a horizontal image on a terminal in a vertical position, the present invention, unlike the prior art, not only minimizes letter boxes or fillers, but also enlarges the image while including the main object. It is possible to play a high-definition vertical video that improves the low-definition problem that occurs while playing. As a result, the present invention has the advantage of increasing the user's visual satisfaction.

즉, 종래 기술(도 11의 좌측)에서는 화면의 25%를 차지하는 반면, 본 발명의 경우(도 11의 우측) 화면의 전체를 활용할 수 있기 때문에 시각적 만족도가 높고, 노출 효과도 커 재생 영상이 광고일 경우에 그 광고 효과가 큰 이점이 있다.In other words, while the conventional technology (left side of Figure 11) occupies 25% of the screen, in the case of the present invention (right side of Figure 11), the entire screen can be used, so visual satisfaction is high and the exposure effect is large, so the playback video can be used as an advertisement. In some cases, the advertising effect has a great advantage.

도 12는 본 발명의 일 실시예에 따른 방법의 S20에서 전자 장치(100)가 가로 파지 상태일 경우에 가로 영상에 대한 영상처리의 보다 상세한 순서도를 나타낸다.FIG. 12 shows a more detailed flowchart of image processing for a horizontal image when the electronic device 100 is held horizontally in step S20 of the method according to an embodiment of the present invention.

한편, 전자 장치(100)가 가로 파지 상태일 경우에 가로 영상에 대한 영상처리를 수행할 경우, 도 12에 도시된 바와 같이, 제어부(160)는 S20에서 S211 내지 S214를 수행할 수 있다. Meanwhile, when performing image processing on a horizontal image when the electronic device 100 is in a horizontal grip state, as shown in FIG. 12, the control unit 160 may perform steps S211 to S214 in S20.

즉, 제어부(160)는 검은 영상에 대한 필요 여부, 즉 필러 박스(pillar box) 또는 레터 박스(letter box)의 영역에 대한 필요 여부를 결정한다(S211). 즉, 전자 장치(100)의 파지 상태에 따른 디스플레이(130)의 화면비율, 가로 영상이 가지는 영상비율을 비교함으로써, 필러 박스 또는 레터 박스의 영역에 대한 필요 여부를 결정할 수 있다. That is, the control unit 160 determines whether a black image is needed, that is, whether a pillar box or letter box area is needed (S211). That is, by comparing the screen ratio of the display 130 and the aspect ratio of the horizontal image according to the holding state of the electronic device 100, it is possible to determine whether a pillar box or letter box area is needed.

만일, S211의 결과, 검은 영상 영역이 필요한 경우(즉, 가로 파지 상태에서 가로 영상에 필러 박스 또는 레터 박스의 영역을 채워서 디스플레이(130)에 재생해야 하는 경우), 제어부(160)는 가로 영상에 대해 상술한 제2 변환을 수행한다(S212).If, as a result of S211, a black image area is required (i.e., when the horizontal image needs to be played on the display 130 by filling in the area of the pillar box or letter box in the horizontal holding state), the control unit 160 controls the horizontal image The second conversion described above is performed (S212).

반면, S211의 결과, 검은 영상 영역이 불필요한 경우(즉, 가로 파지 상태에서 가로 영상에 필러 박스 또는 레터 박스의 영역을 채울 필요 없이 가로 영상을 디스플레이(130)의 모든 화소에 재생할 수 있는 경우), 제어부(160)는 가로 영상에 대해 상술한 제1 변환을 수행한다(S214). On the other hand, as a result of S211, when the black image area is unnecessary (i.e., when the horizontal image can be played in all pixels of the display 130 without the need to fill the area of the pillar box or letter box in the horizontal image in the horizontal holding state), The control unit 160 performs the above-described first transformation on the horizontal image (S214).

한편, S212를 수행한 후, 제어부(160)는 제2 변환이 수행된 가로 영상의 해상도와 디스플레이(130)의 가로 파지 상태의 화면 해상도를 비교하여, 해당 가로 영상의 해상도가 부족한지 여부를 확인한다(S213).Meanwhile, after performing S212, the control unit 160 compares the resolution of the horizontal image on which the second conversion was performed with the screen resolution of the horizontally held state of the display 130 to determine whether the resolution of the horizontal image is insufficient. Do it (S213).

만일, S213의 결과, 디스플레이(130)의 가로 파지 상태의 화면 해상도가 제2 변환이 수행된 가로 영상의 해상도 보다 커서 해당 가로 영상의 해상도가 부족하다면, 제어부(160)는 제2 변환이 수행된 가로 영상에 대해 상술한 제1 변환을 추가 수행하여 가로 영상의 고해상화를 도모한다. 그 결과, 제어부(160)는 디스플레이(130)에서 제2 변환 및 제1 변환이 차례로 수행된 가로 영상을 고해상도로 재생시킬 수 있다.If, as a result of S213, the screen resolution of the horizontally held state of the display 130 is larger than the resolution of the horizontal image on which the second conversion has been performed and the resolution of the horizontal image is insufficient, the control unit 160 determines whether the second conversion has been performed. The above-described first transformation is additionally performed on the horizontal image to achieve high resolution of the horizontal image. As a result, the control unit 160 can reproduce the horizontal image on which the second transformation and the first transformation were sequentially performed on the display 130 at high resolution.

반면, S213의 결과, 제2 변환이 수행된 가로 영상의 해상도가 디스플레이(130)의 가로 파지 상태의 화면 해상도가 보다 커서 해당 가로 영상의 해상도가 부족하지 않다면, 제어부(160)는 제2 변환이 수행된 가로 영상을 고해상도로 재생시킬 수 있다.On the other hand, as a result of S213, if the resolution of the horizontal image on which the second conversion was performed is larger than the screen resolution of the horizontally held state of the display 130, and the resolution of the horizontal image is not insufficient, the control unit 160 performs the second conversion. The performed horizontal video can be played in high resolution.

물론, 상술한 S211 내지 S214는 전자 장치(100)가 세로 파지 상태일 경우에 세로 영상에 대한 영상처리를 수행할 경우에도 동일하게 S20에서 수행될 수 있다. 다만 이 경우, 상술한 S211 내지 S214의 내용에서, 가로 영상은 세로 영상으로 대체되고, 가로 파지 상태는 세로 파지 상태로 대체될 수 있다.Of course, the above-described S211 to S214 can be equally performed in S20 even when image processing is performed on a vertical image when the electronic device 100 is held vertically. However, in this case, in the contents of S211 to S214 described above, the horizontal image may be replaced with a vertical image, and the horizontal holding state may be replaced with a vertical holding state.

도 13는 본 발명의 일 실시예에 따른 방법의 S20에서 전자 장치(100)가 세로 파지 상태일 경우에 가로 영상에 대한 영상처리의 보다 상세한 순서도를 나타낸다.FIG. 13 shows a more detailed flowchart of image processing for a horizontal image when the electronic device 100 is held vertically in step S20 of the method according to an embodiment of the present invention.

또한, 전자 장치(100)가 세로 파지 상태일 경우에 가로 영상에 대한 영상처리를 수행할 경우, 도 13에 도시된 바와 같이, 제어부(160)는 S20에서 S221 내지 S223을 수행할 수 있다. Additionally, when performing image processing on a horizontal image when the electronic device 100 is held vertically, as shown in FIG. 13, the control unit 160 may perform steps S221 to S223 in S20.

즉, 제어부(160)는 가로 영상에 대해 상술한 제3 변환을 수행한다(S221). That is, the control unit 160 performs the above-described third transformation on the horizontal image (S221).

이후, 제어부(160)는 제3 변환이 수행된 세로 영상의 해상도와 디스플레이(130)의 세로 파지 상태의 화면 해상도를 비교하여, 해당 세로 영상의 해상도가 부족한지 여부를 확인한다(S222).Thereafter, the control unit 160 compares the resolution of the vertical image on which the third conversion was performed with the screen resolution in the vertically held state of the display 130 to determine whether the resolution of the vertical image is insufficient (S222).

만일, S222의 결과, 디스플레이(130)의 세로 파지 상태의 화면 해상도가 제3 변환이 수행된 세로 영상의 해상도 보다 커서 해당 세로 영상의 해상도가 부족하다면, 제어부(160)는 제3 변환이 수행된 세로 영상에 대해 상술한 제1 변환을 추가 수행하여 세로 영상의 고해상화를 도모한다. 그 결과, 제어부(160)는 디스플레이(130)에서 제3 변환 및 제1 변환이 차례로 수행된 세로 영상을 고해상도로 재생시킬 수 있다.If, as a result of S222, the screen resolution in the vertically held state of the display 130 is larger than the resolution of the vertical image on which the third conversion has been performed and the resolution of the vertical image is insufficient, the control unit 160 determines whether the third conversion has been performed. The above-described first transformation is additionally performed on the vertical image to achieve high resolution of the vertical image. As a result, the control unit 160 can reproduce the vertical image on which the third transformation and the first transformation were sequentially performed on the display 130 at high resolution.

반면, S222의 결과, 제3 변환이 수행된 세로 영상의 해상도가 디스플레이(130)의 세로 파지 상태의 화면 해상도가 보다 커서 해당 세로 영상의 해상도가 부족하지 않다면, 제어부(160)는 제3 변환이 수행된 세로 영상을 고해상도로 재생시킬 수 있다.On the other hand, as a result of S222, if the resolution of the vertical image on which the third conversion has been performed is larger than the screen resolution in the vertically held state of the display 130, and the resolution of the vertical image is not insufficient, the control unit 160 performs the third conversion. The captured vertical video can be played in high resolution.

상술한 바와 같이 구성되는 본 발명은 영상의 영상비율과 이를 재생하는 전자 장치의 화면비율이 다를 때, 검은 영상(필러 박스 또는 레터 박스)를 삽입하는 것이 아니라, 영상의 영상비율이 조정되도록 처리함으로써 이를 재생하는 전자 장치의 화면비율에 해당 영상을 적합하게 맞출 수 있는 이점이 있다. 또한, 본 발명은 전자 장치의 파지 상태와 영상의 영상비율에 따라 제1 내지 제3 변환 중 적어도 하나의 변환을 적응적으로 수행함으로써 영상의 영상비율에 대한 변환을 효과적으로 수행할 수 있을 뿐만 아니라, 제2 또는 제3 변환을 수행한 후에도 추가적으로 제1 변환을 수행함으로써 변환된 영상의 고해상도화를 도모할 수 있는 이점 있다. 또한, 본 발명은 영상 재생 시, 레터 박스 또는 필러 박스를 최소화할 수 있을 뿐 아니라, 그 영상의 주요 객체를 포함하면서 확대하되, 확대하면서 발생하는 저화질의 문제를 개선한 고화질의 영상으로 재생할 수 있으므로, 사용자의 시각적 만족도를 높일 수 있는 이점이 있다. 또한, 본 발명은 전자 장치의 화면을 최대한 활용하여 재생할 수 있어 시청 몰입감의 증대될 뿐 아니라, 노출 효과도 커, 재생 영상이 광고일 경우에 그 광고 효과가 큰 이점이 있다. 또한, 본 발명은 다양한 화질 개선 기법의 적용 가능하므로, 주문형 비디오(video on demand; VOD) 뿐 아니라 실시간 스트리밍에도 적용 가능한 이점이 있다.The present invention, constructed as described above, does not insert a black image (pillar box or letter box) when the aspect ratio of the image and the screen ratio of the electronic device that reproduces it are different, but processes the image so that the aspect ratio of the image is adjusted. There is an advantage in that the video can be appropriately adjusted to the screen ratio of the electronic device that plays it. In addition, the present invention not only effectively performs conversion on the aspect ratio of an image by adaptively performing at least one of the first to third conversions according to the holding state of the electronic device and the aspect ratio of the image. There is an advantage in that high resolution of the converted image can be achieved by additionally performing the first conversion even after performing the second or third conversion. In addition, the present invention not only minimizes letter boxes or pillar boxes when playing video, but also enlarges the video while including the main objects, and reproduces the video in high definition by improving the low-quality problem that occurs during enlargement. , it has the advantage of increasing the user's visual satisfaction. In addition, the present invention allows playback using the screen of the electronic device as much as possible, which not only increases viewing immersion, but also has a large exposure effect, so when the played video is an advertisement, the advertisement effect is great. In addition, since the present invention can be applied to various image quality improvement techniques, it has the advantage of being applicable not only to video on demand (VOD) but also to real-time streaming.

본 발명의 상세한 설명에서는 구체적인 실시 예에 관하여 설명하였으나 본 발명의 범위에서 벗어나지 않는 한도 내에서 여러 가지 변형이 가능함은 물론이다. 그러므로 본 발명의 범위는 설명된 실시 예에 국한되지 않으며, 후술되는 청구범위 및 이 청구범위와 균등한 것들에 의해 정해져야 한다.In the detailed description of the present invention, specific embodiments have been described, but of course, various modifications are possible without departing from the scope of the present invention. Therefore, the scope of the present invention is not limited to the described embodiments, but should be defined by the claims described below and equivalents to these claims.

100: 전자 장치 110: 입력부
120: 통신부 130: 디스플레이
140: 메모리 150: 센서부
160: 제어부
100: electronic device 110: input unit
120: Communication unit 130: Display
140: memory 150: sensor unit
160: control unit

Claims (20)

가로가 더 긴 화면비율의 가로 파지 상태와 세로가 더 긴 화면비율의 세로 파지 상태에 따라 가로가 더 긴 제1 영상비율의 가로 영상 또는 세로가 더 긴 제2 영상비율의 세로 영상에 대해 영상 변환하여 재생하는 전자 장치로서,
상기 전자 장치의 파지 상태에 관련된 센서 값을 감지하는 센서부; 및
상기 센서 값에 따른 파지 상태 및 상기 영상의 영상비율에 따라, 상기 영상에 대한 제1 내지 제3 변환 중에 적어도 하나를 적응적으로 수행하는 제어부;를 포함하며,
상기 제1 변환은 상기 영상의 내용을 유지하면서 화질을 개선하는 변환이고,
상기 제2 변환은 상기 영상의 내용에 새로운 영상 내용을 추가 합성하는 변환이며,
상기 제3 변환은 상기 세로 파지 상태인 경우에 상기 가로 영상에 대해 영상 내용에서 적어도 일부분을 확대하되 상기 세로 영상으로 확대하면서 화질을 개선하는 변환이고,
상기 제어부는 상기 제3 변환의 수행 시,
상기 가로 영상의 프레임마다 해당 프레임의 컨텐츠를 분석하여, 해당 프레임의 일부 영상에 해당하고 상기 제2 영상비율을 가지는 적어도 하나의 재생 영역을 프레임 별로 산출하는 과정과,
상기 가로 영상을 상기 프레임보다 큰 영상 단위에 해당하는 다수의 소단위로 구분하고 영상의 컨텐츠 종류 별로 기 학습된 다수의 AI(artificial intelligence) 모델 중에서 해당 소단위 내 가로 영상의 컨텐츠 종류에 따라 소단위 별로 적용되는 최적 AI 모델을 선택하는 과정과,
상기 재생 영역을 기반으로 상기 가로 영상에서 세로가 더 긴 영상비율의 세로 영상을 프레임 영상마다 추출하는 과정과,
선택된 최적 AI 모델을 소단위 별로 적용하여 추출된 세로 영상을 확대 변환하는 과정을 각각 수행하며,
서로 다른 적어도 2개의 소단위에 포함된 프레임의 개수는 서로 다르며,
상기 각 AI 모델은 머신 러닝(machine learning) 기법에 따라 서로 다른 컨텐츠의 저화질인 제2 영상비율의 영상으로부터 화질 개선된 제2 영상비율의 확대 영상을 생성하도록 학습된 모델이고,
상기 제어부는 상기 최적 AI 모델을 선택하는 과정의 수행 시, 상기 가로 영상에서 이웃한 프레임들 간의 차이 값을 계산하고 계산된 차이 값이 기준치 보다 큰 경우에 상기 소단위를 구분하며, 상기 소단위 내 연속된 프레임의 입력 데이터가 입력되는 경우에 상기 연속된 프레임 영상에 대한 컨텐츠 종류를 출력하도록 기 학습된 머신 러닝 모델인 분류기를 이용하여 상기 각 소단위에 대한 상기 최적 AI 모델을 선택하되, 상기 분류기에서 출력되는 컨텐츠 종류에 대응하는 컨텐츠 종류로 기 학습된 AI 모델을 해당 소단위에 대한 최적 AI 모델로 선택하는 전자 장치.
Image conversion to a horizontal image of the first aspect ratio with a longer width or a vertical image of a second aspect ratio with a longer height depending on the horizontal holding state of the longer horizontal aspect ratio and the vertical holding state of the longer vertical aspect ratio. As an electronic device that reproduces,
a sensor unit that detects a sensor value related to a holding state of the electronic device; and
A control unit that adaptively performs at least one of first to third transformations on the image according to the grip state according to the sensor value and the image ratio of the image,
The first transformation is a transformation that improves image quality while maintaining the content of the image,
The second transformation is a transformation that adds new video content to the video content,
The third transformation is a transformation that improves image quality by enlarging at least a portion of the image content of the horizontal image in the case of the vertical holding state and enlarging it to the vertical image,
When performing the third conversion, the control unit
A process of analyzing the content of each frame of the horizontal image and calculating at least one playback area corresponding to a partial image of the frame and having the second video ratio for each frame;
The horizontal image is divided into a plurality of subunits corresponding to image units larger than the frame, and among a plurality of AI (artificial intelligence) models previously learned for each content type of the image, a subunit is applied according to the content type of the horizontal image within the subunit. The process of selecting the optimal AI model,
A process of extracting a vertical image with a longer vertical aspect ratio for each frame image from the horizontal image based on the playback area;
The process of enlarging and converting the extracted vertical images is performed by applying the selected optimal AI model to each subunit.
The number of frames included in at least two different subunits is different,
Each of the AI models is a model learned to generate an enlarged image of a second aspect ratio with improved quality from a low-quality second aspect ratio image of different content according to a machine learning technique,
When performing the process of selecting the optimal AI model, the control unit calculates a difference value between neighboring frames in the horizontal image, distinguishes the subunit if the calculated difference value is greater than a reference value, and determines the subunit. When frame input data is input, the optimal AI model for each subunit is selected using a classifier, which is a machine learning model that has been previously learned to output the content type for the continuous frame image, and the optimal AI model output from the classifier is selected. An electronic device that selects an AI model already learned for a content type corresponding to the content type as the optimal AI model for the corresponding subunit.
제1항에 있어서,
상기 제어부는,
상기 가로 파지 상태인 경우에 상기 가로 영상에 대해 상기 제1 변환 또는 상기 제2 변환을 수행하며,
상기 가로 파지 상태 또는 상기 세로 파지 상태인 경우에 상기 세로 영상에 대해 상기 제1 변환 또는 상기 제2 변환을 수행하는 전자 장치.
According to paragraph 1,
The control unit,
When in the horizontal holding state, perform the first transformation or the second transformation on the horizontal image,
An electronic device that performs the first transformation or the second transformation on the vertical image when it is in the horizontal holding state or the vertical holding state.
제2항에 있어서,
상기 제어부는,
상기 가로 파지 상태에서 상기 가로 영상에 필러 박스(pillar box) 또는 레터 박스(letter box)의 영역을 채워서 재생해야 하는 경우에 상기 가로 영상에 대해 상기 제2 변환을 수행하며, 필러 박스(pillar box) 또는 레터 박스(letter box)의 영역이 불필요한 경우에 상기 가로 영상에 대해 상기 제1 변환을 수행하는 전자 장치.
According to paragraph 2,
The control unit,
In the horizontal holding state, when the horizontal image needs to be played by filling the area of a pillar box or letter box, the second transformation is performed on the horizontal image, and a pillar box is formed. Or, an electronic device that performs the first transformation on the horizontal image when a letter box area is unnecessary.
제1항에 있어서,
상기 제어부는 제1 변환의 수행 시,
상기 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환하는 전자 장치.
According to paragraph 1,
When performing the first conversion, the control unit
For the image, an enlarged image is generated by applying a pre-learned machine learning model to enlarge the image to a larger image than the screen size of the grasp state while improving image quality, and then size interpolation is performed on the enlarged image to determine the grasp state. An electronic device that converts to an aspect ratio of .
제1항에 있어서,
상기 제어부는 상기 제2 변환의 수행 시,
이전 및 이후 프레임 영상을 이용하여 대응점 매칭 기반으로 현재 프레임 영상에 이전 또는 이후 프레임 영상에 포함된 새로운 영상 내용을 합성하는 전자 장치.
According to paragraph 1,
When performing the second conversion, the control unit
An electronic device that synthesizes new image content included in the previous or next frame image into the current frame image based on matching points using the previous and next frame images.
제5항에 있어서,
상기 제어부는 상기 제2 변환의 수행 시,
상기 합성된 현재 프레임 영상이 목표 영상의 해상도에 미달하는 경우에 해당 현재 프레임 영상에 생성적 적대 신경망(Generative Adversarial Network; GAN) 기반의 경계 확장을 수행하여 새로운 영상 내용을 합성하는 전자 장치.
According to clause 5,
When performing the second conversion, the control unit
An electronic device that synthesizes new image content by performing generative adversarial network (GAN)-based boundary expansion on the current frame image when the synthesized current frame image is less than the resolution of the target image.
제5항 또는 제6항에 있어서,
상기 제어부는 상기 제1 변환의 수행 시,
상기 합성된 현재 프레임 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환하는 전자 장치.
According to claim 5 or 6,
When performing the first conversion, the control unit
For the synthesized current frame image, an enlarged image is generated by applying a previously learned machine learning model to enlarge the image to a larger image than the screen size of the grip state while improving image quality, and then perform size interpolation on the enlarged image. An electronic device that converts the screen ratio of the holding state.
삭제delete 제1항에 있어서,
상기 제어부는 상기 산출하는 과정의 수행 시, 각 프레임 영상에서 객체와 얼굴에 대한 영역을 각각 검출하여 검출된 영역을 포함하는 최대 재생 영역을 산출하며, 산출된 최대 재생 영역에 대한 잘라내기 과정을 통해 적어도 하나의 상기 재생 영역을 산출하는 전자 장치.
According to paragraph 1,
When performing the calculation process, the control unit detects areas for objects and faces in each frame image, calculates a maximum playback area including the detected areas, and performs a cropping process on the calculated maximum playback area. An electronic device that calculates at least one said playback area.
제9항에 있어서,
상기 최대 재생 영역은 상기 검출된 영역이 복수개인 경우에 상기 각 검출된 영역을 모두 포함하는 영역인 전자 장치.
According to clause 9,
The maximum playback area is an area that includes all of the detected areas when there are multiple detected areas.
삭제delete 제1항에 있어서,
상기 최적 AI 모델은 해상도 증가 및 노이즈 제거를 포함하는 화질 개선을 수행하거나, 해상도 증가 및 다이나믹 레인지 증가를 포함하는 화질 개선을 수행하는 전자 장치.
According to paragraph 1,
The optimal AI model is an electronic device that improves image quality including increasing resolution and removing noise, or improves image quality including increasing resolution and increasing dynamic range.
제1항에 있어서,
상기 제어부는 상기 제3 변환에 따라 확대된 영상을 디스플레이의 모든 화소에서 재생하도록 제어하는 전자 장치.
According to paragraph 1,
The control unit controls the reproduction of the image enlarged according to the third conversion in all pixels of the display.
가로가 더 긴 화면비율의 가로 파지 상태와 세로가 더 긴 화면비율의 세로 파지 상태에 따라 가로가 더 긴 제1 영상비율의 가로 영상 또는 세로가 더 긴 제2 영상비율의 세로 영상에 대해 영상 변환하여 재생하도록 전자 장치에서 수행되는 방법으로서,
상기 전자 장치의 파지 상태에 관련된 센서 값을 감지하는 단계; 및
상기 센서 값에 따른 파지 상태 및 상기 영상의 영상비율에 따라, 상기 영상에 대한 제1 내지 제3 변환 중에 적어도 하나를 적응적으로 수행하는 단계;를 포함하며,
상기 제1 변환은 상기 영상의 내용을 유지하면서 화질을 개선하는 변환이고
상기 제2 변환은 상기 영상의 내용에 새로운 영상 내용을 추가 합성하는 제2 변환이며,
상기 제3 변환은 상기 세로 파지 상태인 경우에 상기 가로 영상에 대해 영상 내용에서 적어도 일부분을 확대하되 상기 세로 영상으로 확대하면서 화질을 개선하는 변환이고,
상기 제3 변환의 수행 시에 상기 수행하는 단계는,
상기 가로 영상의 프레임마다 해당 프레임의 컨텐츠를 분석하여, 해당 프레임의 일부 영상에 해당하고 상기 제2 영상비율을 가지는 적어도 하나의 재생 영역을 프레임 별로 산출하는 단계;
상기 가로 영상을 상기 프레임보다 큰 영상 단위에 해당하는 다수의 소단위로 구분하고 영상의 컨텐츠 종류 별로 기 학습된 다수의 AI(artificial intelligence) 모델 중에서 해당 소단위 내 가로 영상의 컨텐츠 종류에 따라 소단위 별로 적용되는 최적 AI 모델을 선택하는 단계;
상기 재생 영역을 기반으로 상기 가로 영상에서 세로가 더 긴 영상비율의 세로 영상을 프레임 영상마다 추출하는 단계; 및
선택된 최적 AI 모델을 소단위 별로 적용하여 추출된 세로 영상을 확대 변환하는 단계;를 포함하며,
서로 다른 적어도 2개의 소단위에 포함된 프레임의 개수는 서로 다르며,
상기 각 AI 모델은 머신 러닝(machine learning) 기법에 따라 서로 다른 컨텐츠의 저화질인 제2 영상비율의 영상으로부터 화질 개선된 제2 영상비율의 확대 영상을 생성하도록 학습된 모델이고,
상기 최적 AI 모델을 선택하는 단계에서, 상기 가로 영상에서 이웃한 프레임들 간의 차이 값을 계산하고 계산된 차이 값이 기준치 보다 큰 경우에 상기 소단위를 구분하며, 상기 소단위 내 연속된 프레임의 입력 데이터가 입력되는 경우에 상기 연속된 프레임 영상에 대한 컨텐츠 종류를 출력하도록 기 학습된 머신 러닝 모델인 분류기를 이용하여 상기 각 소단위에 대한 상기 최적 AI 모델을 선택하되, 상기 분류기에서 출력되는 컨텐츠 종류에 대응하는 컨텐츠 종류로 기 학습된 AI 모델을 해당 소단위에 대한 최적 AI 모델로 선택하는 방법.
Image conversion to a horizontal image of the first aspect ratio with a longer width or a vertical image of a second aspect ratio with a longer height depending on the horizontal holding state of the longer horizontal aspect ratio and the vertical holding state of the longer vertical aspect ratio. A method performed in an electronic device to reproduce
detecting a sensor value related to a holding state of the electronic device; and
Adaptively performing at least one of first to third transformations on the image according to the holding state according to the sensor value and the aspect ratio of the image,
The first transformation is a transformation that improves image quality while maintaining the content of the image.
The second transformation is a second transformation that adds new video content to the video content,
The third transformation is a transformation that improves image quality by enlarging at least a portion of the image content of the horizontal image in the case of the vertical holding state and enlarging it to the vertical image,
The steps performed when performing the third transformation are:
Analyzing the content of each frame of the horizontal image and calculating at least one playback area corresponding to a partial image of the frame and having the second aspect ratio for each frame;
The horizontal image is divided into a plurality of subunits corresponding to image units larger than the frame, and among a plurality of AI (artificial intelligence) models previously learned for each content type of the image, a subunit is applied according to the content type of the horizontal image within the subunit. Selecting an optimal AI model;
extracting a vertical image with a longer vertical aspect ratio for each frame image from the horizontal image based on the playback area; and
A step of enlarging and converting the extracted vertical image by applying the selected optimal AI model for each subunit;
The number of frames included in at least two different subunits is different,
Each of the AI models is a model learned to generate an enlarged image of a second aspect ratio with improved quality from a low-quality second aspect ratio image of different content according to a machine learning technique,
In the step of selecting the optimal AI model, the difference value between neighboring frames in the horizontal image is calculated, and if the calculated difference value is greater than the reference value, the subunit is distinguished, and the input data of consecutive frames within the subunit is When input, the optimal AI model for each subunit is selected using a classifier, which is a machine learning model that has been previously learned to output the content type for the continuous frame image, and the optimal AI model corresponding to the content type output from the classifier is selected. A method of selecting an AI model already learned based on the content type as the optimal AI model for the corresponding subunit.
제14항에 있어서,
상기 수행하는 단계에서,
상기 가로 파지 상태인 경우에 상기 가로 영상에 대해 상기 제1 변환 또는 상기 제2 변환이 수행되고,
상기 가로 파지 상태 또는 상기 세로 파지 상태인 경우에 상기 세로 영상에 대해 상기 제1 변환 또는 상기 제2 변환이 수행되는 방법.
According to clause 14,
In the above performing steps,
In the case of the horizontal holding state, the first transformation or the second transformation is performed on the horizontal image,
A method in which the first transformation or the second transformation is performed on the vertical image when it is in the horizontal holding state or the vertical holding state.
제14항에 있어서,
상기 제1 변환의 수행 시,
상기 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환하는 방법.
According to clause 14,
When performing the first conversion,
For the image, an enlarged image is generated by applying a pre-learned machine learning model to enlarge the image to a larger image than the screen size of the grasp state while improving image quality, and then size interpolation is performed on the enlarged image to determine the grasp state. How to convert to aspect ratio.
제14항에 있어서,
상기 제2 변환의 수행 시,
이전 및 이후 프레임 영상을 이용하여 대응점 매칭 기반으로 현재 프레임 영상에 이전 또는 이후 프레임 영상에 포함된 새로운 영상 내용을 합성하는 방법.
According to clause 14,
When performing the second conversion,
A method of synthesizing new image content included in the previous or next frame image into the current frame image based on corresponding point matching using the previous and next frame images.
제14항에 있어서,
상기 제2 변환의 수행 시,
상기 합성된 현재 프레임 영상이 목표 영상의 해상도에 미달하는 경우에 해당 현재 프레임 영상에 생성적 적대 신경망(Generative Adversarial Network; GAN) 기반의 경계 확장을 수행하여 새로운 영상 내용을 합성하는 방법.
According to clause 14,
When performing the second conversion,
A method of synthesizing new image content by performing generative adversarial network (GAN)-based boundary expansion on the current frame image when the synthesized current frame image is less than the resolution of the target image.
제17항 또는 제18항에 있어서,
상기 제1 변환의 수행 시,
상기 합성된 현재 프레임 영상에 대해, 화질을 개선하면서 상기 파지 상태의 화면 크기보다 큰 영상으로 확대하도록 기 학습된 머신 러닝 모델을 적용하여 확대 영상을 생성한 후, 상기 확대 영상에 대한 크기 보간을 수행하여 상기 파지 상태의 화면비율로 변환하는 방법.
According to claim 17 or 18,
When performing the first conversion,
For the synthesized current frame image, an enlarged image is generated by applying a previously learned machine learning model to enlarge the image to a larger image than the screen size of the grip state while improving image quality, and then perform size interpolation on the enlarged image. A method of converting the screen ratio of the holding state.
삭제delete
KR1020210088394A 2021-07-06 2021-07-06 Electronic apparatus and method for intelligent video conversion KR102596308B1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
KR1020210088394A KR102596308B1 (en) 2021-07-06 2021-07-06 Electronic apparatus and method for intelligent video conversion
PCT/KR2022/002168 WO2023282426A2 (en) 2021-07-06 2022-02-14 Electronic device and method for intelligent image conversion

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020210088394A KR102596308B1 (en) 2021-07-06 2021-07-06 Electronic apparatus and method for intelligent video conversion

Publications (2)

Publication Number Publication Date
KR20230007718A KR20230007718A (en) 2023-01-13
KR102596308B1 true KR102596308B1 (en) 2023-10-31

Family

ID=84801819

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020210088394A KR102596308B1 (en) 2021-07-06 2021-07-06 Electronic apparatus and method for intelligent video conversion

Country Status (2)

Country Link
KR (1) KR102596308B1 (en)
WO (1) WO2023282426A2 (en)

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100987289B1 (en) * 2003-02-26 2010-10-12 삼성전자주식회사 Portable communication terminal capable of displaying data in the same direction with screen according to pivot position state of the screen and method thereof
KR20060070195A (en) * 2004-12-20 2006-06-23 주식회사 팬택앤큐리텔 Apparatus for screen display auto conversion in the swivel type mobile communication terminal
KR100738030B1 (en) 2005-10-10 2007-07-16 주식회사 케이티프리텔 Portable terminal having function of conversion of picture
EP4283528A3 (en) * 2018-01-04 2024-02-14 Samsung Electronics Co., Ltd. Video playback device and control method thereof
KR20200063329A (en) * 2018-11-21 2020-06-05 삼성전자주식회사 Image processing apparatus and controlling method thereof

Also Published As

Publication number Publication date
WO2023282426A3 (en) 2023-03-23
KR20230007718A (en) 2023-01-13
WO2023282426A2 (en) 2023-01-12

Similar Documents

Publication Publication Date Title
US10242265B2 (en) Actor/person centric auto thumbnail
US8750602B2 (en) Method and system for personalized advertisement push based on user interest learning
US20210004962A1 (en) Generating effects on images using disparity guided salient object detection
US10719741B2 (en) Sensory information providing apparatus, video analysis engine, and method thereof
CN113284073B (en) Image restoration method, device and storage medium
US20230021533A1 (en) Method and apparatus for generating video with 3d effect, method and apparatus for playing video with 3d effect, and device
KR20220000758A (en) Image detection apparatus and method thereof
JP2009140369A (en) Group learning device and group learning method, object detection device and object detection method, and computer program
CN110418148B (en) Video generation method, video generation device and readable storage medium
KR101642200B1 (en) Apparatus and method for generating motion effects by analyzing motion of object
Katsenou et al. Perceptually-aligned frame rate selection using spatio-temporal features
KR20210109719A (en) Method and Apparatus for Video Colorization
KR102595096B1 (en) Electronic apparatus, system and method for intelligent horizontal-vertical video conversion
KR102596308B1 (en) Electronic apparatus and method for intelligent video conversion
US20230209087A1 (en) Method and device for improving video quality
Suchecki et al. Understanding aesthetics in photography using deep convolutional neural networks
WO2018123202A1 (en) Moving-image processing device, display device, moving-image processing method, and control program
KR102429379B1 (en) Apparatus and method for classifying background, and apparatus and method for generating immersive audio-video data
JP2014229092A (en) Image processing device, image processing method and program therefor
CN113095239A (en) Key frame extraction method, terminal and computer readable storage medium
Ram et al. Video Analysis and Repackaging for Distance Education
CN117156078B (en) Video data processing method and device, electronic equipment and storage medium
US20230162499A1 (en) Image analysis system, image analysis method, and program
CN112019923B (en) Video cutting processing method
US20230267706A1 (en) Video remastering via deep learning

Legal Events

Date Code Title Description
E902 Notification of reason for refusal
E90F Notification of reason for final refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant