WO2023243040A1 - 画像処理装置、画像処理方法、及び画像処理プログラム - Google Patents

画像処理装置、画像処理方法、及び画像処理プログラム Download PDF

Info

Publication number
WO2023243040A1
WO2023243040A1 PCT/JP2022/024149 JP2022024149W WO2023243040A1 WO 2023243040 A1 WO2023243040 A1 WO 2023243040A1 JP 2022024149 W JP2022024149 W JP 2022024149W WO 2023243040 A1 WO2023243040 A1 WO 2023243040A1
Authority
WO
WIPO (PCT)
Prior art keywords
frames
processing
area
difference
block
Prior art date
Application number
PCT/JP2022/024149
Other languages
English (en)
French (fr)
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 PCT/JP2022/024149 priority Critical patent/WO2023243040A1/ja
Publication of WO2023243040A1 publication Critical patent/WO2023243040A1/ja

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis

Definitions

  • the technology of the present disclosure relates to an image processing device, an image processing method, and an image processing program.
  • Inference processing such as object detection, pose estimation, and segmentation using CNN (Convolutional Neural Network) is basically a process that targets one piece of image data, and when applying that process to each frame of a video, The amount of calculation required is proportional to the number of frames.
  • CNN Convolutional Neural Network
  • inference processing that targets video data uses the above-mentioned inference processing for image data, limits the applicable frames, and uses other information that can be derived with a smaller amount of calculations. By using them together, the amount of calculation is reduced.
  • inference processing uses the above-mentioned inference processing for image data, limits the applicable frames, and uses other information that can be derived with a smaller amount of calculations. By using them together, the amount of calculation is reduced.
  • Non-Patent Document 1 proposes a method of reducing the amount of calculation by taking the inter-frame difference for each pixel in each layer and performing a convolution calculation.
  • Non-Patent Document 1 has a problem in that it requires a complicated arithmetic and control mechanism.
  • the disclosed technology has been made in view of the above points, and provides an image processing device, an image processing method, and an image processing device that has a simple configuration and can suppress the amount of calculation in processing using a neural network including convolution processing.
  • the purpose is to provide image processing programs.
  • a first aspect of the present disclosure is an image processing apparatus including a neural network that performs convolution processing on a moving image including a plurality of frames; a difference determination unit that determines a difference region from a past frame for frames other than the key frame among the frames; and a plurality of layers that perform convolution processing of the neural network for frames other than the key frame among the plurality of frames.
  • a block setting unit that sets an update block including an update region corresponding to the difference region; processing the frame using a network to save an output feature map of each layer; processing the frame using the neural network for frames other than key frames among the plurality of frames; a processing unit that overwrites an output feature map stored for each layer, and the block setting unit sets the difference region to a surrounding area from the previous layer according to the parameters of the convolution process for each layer that performs the convolution process.
  • the difference area is set so as to be enlarged, and an update block including an update area corresponding to the difference area is set.
  • a second aspect of the present disclosure is an image processing apparatus including a neural network that performs convolution processing on a moving image including a plurality of frames, comprising: an acquisition unit that acquires a moving image to be processed; a difference determination unit that determines a difference region from a past frame for frames other than the key frame among the frames; and a plurality of layers that perform convolution processing of the neural network for frames other than the key frame among the plurality of frames.
  • an update block including an update area corresponding to the difference area is set among the plurality of blocks obtained by dividing the output feature map, and for each of the plurality of layers , a block setting unit that sets a processing target block including a processing target area according to the difference region, and a block setting unit that processes the frame using the neural network for a key frame among the plurality of frames, and processes the frame using the neural network, save each output feature map of the plurality of frames other than the key frame, perform processing using the neural network on the processing target block for each of the plurality of layers, and save the a processing unit that overwrites the update block of the stored output feature map for each of the layers;
  • the difference area is set so as to further expand the difference area to the surrounding area, and an update block including an update area according to the difference area is set.
  • a third aspect of the present disclosure is an image processing method in an image processing apparatus including a neural network that includes convolution processing for a moving image including a plurality of frames, wherein the acquisition unit acquires a moving image to be processed.
  • the difference determination unit determines a difference region from a past frame for a frame other than the key frame among the plurality of frames, and the block setting unit determines a difference area with respect to a frame other than the key frame among the plurality of frames.
  • an update block including an update region corresponding to the difference region is set among the plurality of blocks obtained by dividing the output feature map, and the processing unit
  • the frame is processed using the neural network and an output feature map of each layer is stored, and for frames other than the key frame among the plurality of frames, the neural network is used to process the frame.
  • processing the frame to overwrite an output feature map stored for the updated block;
  • the difference area is set so that the difference area is expanded to the periphery from the previous layer, and an update block including an update area according to the difference area is set.
  • a fourth aspect of the present disclosure is an image processing method in an image processing apparatus including a neural network that includes convolution processing for a moving image including a plurality of frames, wherein the acquisition unit acquires a moving image to be processed.
  • the difference determination unit determines a difference region from a past frame for a frame other than the key frame among the plurality of frames, and the block setting unit determines a difference area with respect to a frame other than the key frame among the plurality of frames.
  • update blocks that include an update region corresponding to the difference region among the plurality of blocks obtained by dividing the output feature map.
  • a processing target block including a processing target region corresponding to the difference region is set for each of the plurality of layers, and the processing unit uses the neural network for a key frame among the plurality of frames. processing the frame to save an output feature map of each of the storage layers, and for frames other than key frames among the plurality of frames, for each of the plurality of layers, the processing target block is processed.
  • the process includes performing processing using a neural network and overwriting the update block of the output feature map stored for each of the storage layers, and the block setting unit sets the update block for each storage layer.
  • the difference region is set so as to expand the difference region to the surrounding area from the previous layer according to the parameters of the convolution process, and an update block including the update region according to the difference region is set.
  • a fifth aspect of the present disclosure is an image processing program for causing a computer to function as the image processing device of the first aspect or the second aspect.
  • FIG. 1 is a schematic block diagram of an example of a computer that functions as an image processing device according to a first embodiment and a second embodiment.
  • FIG. 1 is a block diagram showing the functional configuration of an image processing apparatus according to a first embodiment and a second embodiment.
  • FIG. 2 is a block diagram showing the functional configuration of a learning section of the image processing apparatus of the first embodiment and the second embodiment.
  • FIG. 2 is a block diagram showing the functional configuration of an inference section of the image processing apparatus of the first embodiment and the second embodiment.
  • FIG. 3 is an image diagram of a difference area set for each layer.
  • FIG. 3 is a diagram for explaining a difference area, an update area, and an update block.
  • FIG. 3 is an image diagram of a difference area set for each layer.
  • FIG. 4 is an image diagram of a difference area set for each layer and an update block set for each storage layer.
  • FIG. 3 is a diagram for explaining a difference area, an update area, an update block, a processing target area, and a processing target block.
  • 7 is a flowchart showing the flow of convolution processing in image processing according to the second embodiment.
  • the presence or absence of a difference between the input image of the past frame and the current frame is determined in block units of several pixels x several pixels, and the block containing the difference area is subjected to one layer of normal CNN processing, resulting in the processing results of the first layer. shall be.
  • the first layer processing results of past frames are read and used as the first layer processing results.
  • the difference area is expanded to the range affected by the difference area of the first layer, and blocks that include the expanded difference area are subjected to normal CNN processing, and blocks that do not include the difference area are subjected to CNN processing. is skipped and the processing result of the same layer of the past frame is read and used as the processing result of that layer.
  • the difference area is updated based on criteria such as enlarging the peripheral area by one pixel in a layer using a 3x3 pixel kernel, and not enlarging it in a layer using a 1x1 pixel kernel. Furthermore, efficient implementation is possible by determining whether to perform CNN processing or to skip it in units of predetermined blocks.
  • the first method is to limit the storage of output feature maps of past frames to one out of several layers that undergo convolution processing.
  • the storage layer which can reduce data transfer bandwidth and memory capacity, there is no feature map outside the difference area, and it is affected by invalid data from the surroundings due to convolution processing.
  • CNN processing is performed. Furthermore, processing results affected by invalid data are discarded, and only processing results in areas that are not affected are overwritten over past frame results.
  • the pixel width N at which the influence of the difference area expands until the next storage layer is determined, and a block that includes at least a part of the update area obtained by expanding the difference area by N pixels is set as an update block, and the update is performed. Overwrites feature maps of past frames only for blocks. Further, a block including at least a part of the processing target area obtained by expanding the updated area by N pixels is set as a processing target block, and CNN processing is performed on the processing target block.
  • Another method is to determine in advance the range in which the final inference result is influenced by the difference region of the first layer from reduced images or inference results of past frames, and to prevent the difference region from expanding beyond that range. By doing so, CNN processing is skipped outside the range and the processing results of past frames are read. In this method, the effect of reducing the amount of calculation can be obtained by effectively limiting the area in which CNN processing is performed.
  • FIG. 1 is a block diagram showing the hardware configuration of an image processing apparatus 10 according to the first embodiment.
  • the image processing device 10 includes a CPU (Central Processing Unit) 11, a ROM (Read Only Memory) 12, a RAM 13, a storage 14, an input section 15, a display section 16, and a communication interface (I/F). It has 17. Each configuration is communicably connected to each other via a bus 19.
  • CPU Central Processing Unit
  • ROM Read Only Memory
  • RAM Random Access Memory
  • storage 14 an input section
  • I/F communication interface
  • the CPU 11 is a central processing unit that executes various programs and controls various parts. That is, the CPU 11 reads a program from the ROM 12 or the storage 14 and executes the program using the RAM 13 as a work area. The CPU 11 controls each of the above components and performs various arithmetic operations according to programs stored in the ROM 12 or the storage 14.
  • the ROM 12 or the storage 14 stores a learning processing program for performing neural network learning processing and an image processing program for performing image processing using the neural network.
  • the learning processing program and the image processing program may be one program, or may be a program group composed of a plurality of programs or modules.
  • the ROM 12 stores various programs and various data.
  • the RAM 13 temporarily stores programs or data as a work area.
  • the storage 14 is configured with an HDD (Hard Disk Drive) or an SSD (Solid State Drive), and stores various programs including an operating system and various data.
  • the input unit 15 includes a pointing device such as a mouse and a keyboard, and is used to perform various inputs.
  • the input unit 15 receives learning data for learning the neural network as input.
  • the input unit 15 receives, as input, learning data that includes a moving image to be processed and a predetermined processing result for the moving image.
  • the input unit 15 receives a moving image to be processed as input.
  • the display unit 16 is, for example, a liquid crystal display, and displays various information including processing results.
  • the display section 16 may adopt a touch panel method and function as the input section 15.
  • the communication interface 17 is an interface for communicating with other devices, and uses standards such as Ethernet (registered trademark), FDDI, and Wi-Fi (registered trademark), for example.
  • FIG. 2 is a block diagram showing an example of the functional configuration of the image processing device 10. As shown in FIG.
  • the image processing device 10 includes a learning section 20 and an inference section 22, as shown in FIG.
  • the learning section 20 includes an acquisition section 30, a processing section 38, and an updating section 40.
  • the acquisition unit 30 acquires a moving image of input learning data and a processing result.
  • the processing unit 38 processes each frame of the moving image using a neural network including convolution processing.
  • the updating unit 40 updates the parameters of the neural network so that the result of processing the moving image using the neural network matches the processing result obtained in advance.
  • Each process of the processing section 38 and the updating section 40 is repeatedly performed until a predetermined repetition end condition is met. This trains the neural network.
  • the inference section 22 includes an acquisition section 50, an overall control section 52, a difference determination section 54, a block setting section 56, and a processing section 58.
  • the acquisition unit 50 acquires the input moving image to be processed.
  • the overall control unit 52 determines whether each of the multiple frames of the moving image to be processed is a key frame.
  • a key frame it is assumed that one of a plurality of frames is designated as a key frame at a predetermined period. Note that a frame in which the proportion of the difference area is equal to or greater than a threshold value may be determined to be a key frame.
  • the difference determination unit 54 determines the difference region from the past frame for frames other than the key frame among the plurality of frames.
  • the block setting unit 56 configures each of the plurality of layers that perform convolution processing of the neural network for frames other than the key frame among the plurality of frames, according to the difference region among the plurality of blocks obtained by dividing the output feature map.
  • the block setting unit 56 sets the difference region for each layer to be subjected to the convolution process, so as to expand the difference region to the surrounding area from the previous layer according to the parameters of the convolution process (see FIG. 5),
  • An update block including at least a part of the update area according to the difference area is set (see FIG. 6).
  • FIG. 5 shows that compared to the difference area of the first layer, the difference area expands as the layer gets deeper, the range for normal CNN processing expands, and the range for skipping processing to read the processing results of past frames shrinks.
  • An example is shown.
  • FIG. 6 shows an example in which four blocks (dashed line rectangles) that include at least part of an update area (solid line rectangle) that is an expanded surrounding area of a difference area (dotted line rectangle) are set as update blocks. .
  • the block setting unit 56 sets the difference area so that it does not expand beyond a pre-specified area (see FIG. 7). Further, it is preferable that the block setting unit 56 sets the difference area in a layer after the pre-designated layer so as not to expand the difference area.
  • Figure 7 shows that compared to the difference region of the first layer, the difference region expands with the pre-specified region as the upper limit as the layer becomes deeper, and after the layer that reaches the pre-specified region, it becomes normal CNN. This example shows an example in which the processing range does not expand.
  • the processing unit 58 performs normal CNN inference processing for processing the frame using a neural network on key frames among the plurality of frames, and saves the output feature map of each layer.
  • Normal CNN inference processing here refers to inputting an input feature map in each layer from the first layer to the final layer, convolution processing, activation function processing, downsampling processing, upsampling processing, and output feature maps of other layers. This refers to performing summation/concatenation processing, etc., and outputting an output feature map.
  • the input feature map of the first layer is image data consisting of three channels of RGB, etc.
  • the output feature map of the final layer is data in which information regarding the inference result is stored in each channel.
  • the kernel size used for convolution is either 1 ⁇ 1 pixel or 3 ⁇ 3 pixel, but is not limited to this.
  • processing unit 58 performs processing using a neural network on blocks including difference regions for frames other than key frames among the plurality of frames, and overwrites the stored output feature map.
  • the display unit 16 displays the results of processing the moving image using the neural network.
  • FIG. 8 is a flowchart showing the flow of learning processing by the image processing device 10.
  • the learning process is performed by the CPU 11 reading the learning process program from the ROM 12 or the storage 14, expanding it to the RAM 13, and executing it. Furthermore, learning data is input to the image processing device 10.
  • step S100 the CPU 11, as the acquisition unit 30, acquires a moving image and a processing result of the input learning data.
  • step S102 the CPU 11, as the processing unit 38, processes the moving image of the learning data using a neural network including convolution processing.
  • step S104 the CPU 11, as the update unit 40, updates the parameters of the neural network so that the result of processing the learning data video using the neural network matches the processing result obtained in advance. do.
  • step S106 the CPU 11 determines whether a predetermined repetition end condition is satisfied. If the repetition end condition is not satisfied, the process returns to step S102, and the processes of the processing section 38 and the updating section 40 are repeatedly performed. This trains the neural network.
  • FIG. 9 is a flowchart showing the flow of image processing by the image processing device 10.
  • Image processing is performed by the CPU 11 reading an image processing program from the ROM 12 or the storage 14, expanding it to the RAM 13, and executing it. Further, a moving image to be processed is input to the image processing device 10 .
  • step S107 the CPU 11, as the acquisition unit 50, acquires the input moving image.
  • step S109 the CPU 11 processes the moving image using the neural network learned by the learning process described above. Then, the display unit 16 displays the results of processing the moving image using the neural network.
  • step S109 is realized by the processing routine shown in FIG.
  • each frame of the moving image is set as the current frame in order.
  • step S110 the CPU 11, as the overall control unit 52, determines whether the current frame is a key frame. If it is determined that the current frame is a key frame, the process moves to step S112. On the other hand, if it is determined that the current frame is not a key frame, the process moves to step S114.
  • step S112 the CPU 11, as the processing unit 58, performs normal CNN inference processing on the current frame and stores all output feature maps of each layer in the RAM 13. Further, the inference result is output from the processing section 58 to the display section 16.
  • step S114 the CPU 11, as the difference determination unit 54, determines the pixel difference between the current frame image and the cumulatively updated image to determine the difference area.
  • the cumulatively updated image is an image in which regions determined to have a difference in each subsequent frame are replaced with the input image of that frame with respect to the key frame image.
  • the influence of noise is removed by thresholding the pixel difference values of both images and comparison processing with surrounding pixels, and only areas with visually significant differences are determined pixel by pixel as difference areas. .
  • step S116 the CPU 11, as the block setting unit 56, sets a difference region for the layer so as to expand the difference region to the surrounding area from the previous layer according to the parameters of the convolution process, and uses the difference region as a margin.
  • Set an update area by enlarging it by one pixel width or several pixels width, determine whether or not it includes at least part of the update area in blocks of several pixels square, and update the blocks that include at least part of the update area. It is set as a block and saved in the RAM 13 as updated block information.
  • step S118 the CPU 11, as the processing unit 58, performs processing for one layer based on the update block information read from the RAM 13. Specifically, in step S118, the CPU 11, as the processing unit 58, determines whether the block in question is an updated block. If the block is not an update block, the process moves to step S124 without performing any processing. As a result, for the block, the output feature map of the past frame is directly used as the output feature map of the current frame.
  • step S120 the CPU 11, as the processing unit 58, reads the input feature map for the update block including surrounding pixels necessary for convolution processing, performs convolution processing and activates the result as in normal CNN inference processing. Performs function processing, etc.
  • step S122 the CPU 11, as the processing unit 58, overwrites the output feature map for the updated block with the output feature map at the same layer and position of the past frame on the RAM 13.
  • step S124 the CPU 11 determines whether the processes of steps S118 to S122 have been completed for all blocks. If there is a block that has not been processed in steps S118 to S122, the process returns to step S118 and the processes in steps S118 to S122 are performed for the block.
  • step S126 the CPU 11 determines whether the processes of steps S116 to S124 have been completed for all layers. If the processes in steps S116 to S124 have not been completed for all layers, the process returns to step S116 and processes the next layer. On the other hand, if the processing of steps S116 to S124 is completed for all layers, the process moves to step S128.
  • step S1208 the CPU 11 determines whether or not the processing in steps S110 to S126 described above has been completed for all frames. If the processing of steps S110 to S126 has not been completed for all frames, the process returns to step S110 and processes the next frame as the current frame. On the other hand, if the processing of steps S110 to S126 is completed for all frames, the processing routine ends.
  • step S116 is realized by the processing routine shown in FIG. 11.
  • step S130 the CPU 11, as the block setting unit 56, acquires information indicating the difference area determination result in step S114.
  • step S132 the CPU 11, as the block setting unit 56, determines whether the kernel size of the previous layer is 1 ⁇ 1. If the kernel size of the previous layer is 1 ⁇ 1, the process moves to step S140. On the other hand, if the kernel size of the previous layer is not 1 ⁇ 1 but 3 ⁇ 3, the process moves to step S134.
  • step S134 the CPU 11, as the block setting unit 56, determines whether the layer in question is after the layer specified in advance. If the layer is after the layer specified in advance, the process moves to step S140. On the other hand, if the relevant layer is before the pre-specified layer, the process moves to step S136.
  • step S136 the CPU 11, as the block setting unit 56, determines whether or not the difference region of the layer in question exceeds a pre-specified region when expanded to the surrounding area from the previous layer according to the parameters of the convolution process. judge. If it is determined that the difference area exceeds the pre-specified area when the difference area is expanded to the surrounding area from the previous layer, the process moves to step S140. On the other hand, if it is determined that expanding the differential area from the previous layer to the surrounding area does not exceed the pre-designated area, the process moves to step S138.
  • the difference region is not expanded to the periphery in layers after the pre-specified layer. Furthermore, even if it is before the specified layer, the difference area is not expanded outside the pre-specified area based on the determination in step S136. This prevents update blocks from spreading over the entire feature map and reduces the amount of calculation.
  • step S138 the CPU 11, as the block setting unit 56, expands the difference area by one pixel to the periphery. This is because if the kernel size of the convolution process in the immediately preceding layer is larger than 1 ⁇ 1 pixel, the influence of the difference region will spread to the periphery.
  • step S140 the CPU 11, as the block setting unit 56, determines whether the previous layer involves downsampling by 1/2. If the previous layer does not involve downsampling by 1/2, the process moves to step S144. On the other hand, if the previous layer involves downsampling by 1/2, the process moves to step S142.
  • step S142 the CPU 11, as the block setting unit 56, downsamples the difference region to 1/2 pixel by pixel. At this time, if there is a difference area of one or more pixels in the 2 ⁇ 2 pixels, it is regarded as a difference area.
  • step S144 the CPU 11, as the block setting unit 56, determines whether the previous layer involves up-sampling. If the previous layer does not involve upsampling, the process moves to step S148. On the other hand, if the previous layer involves upsampling, the process moves to step S146.
  • step S146 the CPU 11, as the block setting unit 56, upsamples the difference region pixel by pixel.
  • step S148 the CPU 11, as a block setting unit 56, sets an update area by enlarging the difference area by one pixel width or several pixel width as a margin, and includes at least a part of the update area in blocks of several pixels square.
  • a block including at least a part of the update area is set as an update block, and is stored in the RAM 13 as update block information.
  • the updated difference area information is also output to the RAM 13.
  • the difference area information may be information in units of pixels, or may be a combination of information in units of blocks and information on pixel widths expanded from the information in units of blocks.
  • the image processing apparatus determines the difference region from the past frame for frames other than key frames, and determines the difference region from the past frame for frames other than the key frame, and determines the difference region according to the difference region for each of the plurality of layers that performs convolution processing.
  • the difference area is set so as to expand the difference area to the surrounding area from the previous layer according to the parameters of the convolution process, and includes an update area according to the difference area.
  • Set update block Thereby, with a simple configuration, it is possible to suppress the amount of calculation in processing using a neural network including convolution processing.
  • the difference judgment is performed on the cumulatively updated image instead of the immediately preceding frame as an example, but this means that when the judgment of no difference is made for multiple consecutive frames in the same area, there is a small difference. This is to avoid cumulative deterioration in accuracy. Therefore, the difference determination may be performed on the immediately preceding frame, and key frames may be inserted more frequently instead. Further, the difference determination may be performed using a reduced image of the input image in order to reduce the amount of calculations and reduce the influence of noise.
  • the output feature maps of all layers of past frames were saved in RAM and overwritten, but in the second embodiment, the output feature maps are saved in RAM in order to reduce memory capacity and bandwidth.
  • This embodiment differs from the first embodiment in that the layers are limited.
  • the block setting unit 56 of the image processing device 10 selects a predetermined storage layer among the plurality of layers that performs convolution processing of the neural network for frames other than the key frame among the plurality of frames. For each block, an update block including an update area corresponding to the difference area is set among a plurality of blocks obtained by dividing the output feature map. At this time, the block setting unit 56 sets a difference region for each predetermined storage layer so as to expand the difference region to the surrounding area from the previous layer according to the parameters of the convolution process (FIG. 12), An update block including an update area according to the difference area is set (FIG. 13). Further, the block setting unit 56 sets a processing target block including a processing target region according to the difference region for each layer in which convolution processing is performed (FIG. 13).
  • Figure 12 shows that compared to the difference area of the first layer, the difference area expands as the layer gets deeper, the range for normal CNN processing expands, and the range for skipping processing to read the processing results of past frames shrinks.
  • An example is shown.
  • an example is shown in which an update block for writing and overwriting a feature map is set for each storage layer.
  • the difference region is expanded in consideration of the portion affected by invalid data, and the processing target block, which is the portion from which the feature map is read, is set.
  • FIG. 13 shows an example in which four blocks (dashed line rectangles) that include at least a part of the update area (innermost solid line rectangle) that is an expanded surrounding area of the difference area (dotted line rectangle) are set as update blocks. It shows. Further, an example is shown in which six blocks (broken line rectangles) that include at least a part of the processing target area (outer solid line rectangle) which is the difference area further expanded to the surrounding area are set as the processing target blocks.
  • the block setting unit 56 sets the difference area so that it does not expand beyond a pre-specified area. Further, it is preferable that the block setting unit 56 sets the difference area in a layer after the pre-designated layer so as not to expand the difference area.
  • the processing unit 58 performs normal CNN inference processing on key frames among the plurality of frames using a neural network, and saves the output feature map of each storage layer.
  • the processing unit 58 performs processing using a neural network on the processing target block for each of the plurality of layers that performs convolution processing, and On the other hand, it overwrites the saved update block of the output feature map.
  • step S109 is realized by the processing routine shown in FIG.
  • each frame of the moving image is set as the current frame in order.
  • step S110 the CPU 11, as the overall control unit 52, determines whether the current frame is a key frame. If it is determined that the current frame is a key frame, the process moves to step S200. On the other hand, if it is determined that the current frame is not a key frame, the process moves to step S114.
  • step S200 the CPU 11, as the processing unit 58, performs normal CNN inference processing on the current frame, and stores all output feature maps of each storage layer in the RAM 13. Further, the inference result is output from the processing section 58 to the display section 16.
  • step S114 the CPU 11, as the difference determination unit 54, determines the pixel difference between the current frame image and the cumulatively updated image to determine the difference area.
  • step S201 the CPU 11 determines whether the layer in question is the first layer or the previous layer is the storage layer. If the layer in question is the first layer or the previous layer is the storage layer, the process moves to step S202. On the other hand, if the layer in question is not the first layer and the previous layer is not the storage layer, the process moves to step S204.
  • step S202 the CPU 11, as the block setting unit 56, sets the difference region for each layer up to the next storage layer so as to expand the difference region to the surrounding area from the previous layer according to the parameters of the convolution process, For the next storage layer, set an update area by enlarging the difference area by one pixel width or several pixel width as a margin, and determine whether at least a part of the update area is included in each block of several pixels square, A block including at least a part of the update area is set as an update block, and is stored in the RAM 13 as update block information. In addition, for each layer up to the next storage layer, the difference area is further expanded to set a processing target area, and it is determined whether or not each block includes at least a part of the processing target area. A block including the section is set as a processing target block, and is stored in the RAM 13 as processing target block information.
  • N For example, obtain the number N of layers with a kernel size of 3 x 3 pixels up to the next storage layer, expand the difference region by N pixel width, set it as the difference region in the next storage layer, and set it as the margin.
  • An update area is set by enlarging the difference area by one pixel width or several pixel widths, and a block including at least a part of the update area is set as an update block.
  • a processing target area is set by further expanding the difference area, and a block including at least a part of the processing target area is set as a processing target block.
  • the range of the update block or block to be processed is calculated by downsampling or upsampling the difference area in addition to expanding the difference area.
  • step S204 the processing unit 58 determines whether the block is a block to be processed. If the block is the processing target block, the process moves to step S206. On the other hand, if the block is not the block to be processed, the process moves to step S124.
  • step S206 the CPU 11, as the processing unit 58, reads the input feature map including peripheral pixels necessary for the convolution process from the RAM 13, performs the convolution process of the input feature map and activates the result as in the normal CNN inference process. Performs conversion function processing, etc. No processing is done for other blocks.
  • peripheral pixel data of the block to be processed is not stored in the memory, invalid data is read.
  • step S208 the CPU 11, as the processing unit 58, determines whether the layer in question is a storage layer. If the layer is not a storage layer, the process moves to step S210. On the other hand, if the layer is a storage layer, the process moves to step S212.
  • step S210 the output feature map of the block to be processed is temporarily stored in the RAM 13. This output feature map of the block to be processed is saved until the next layer is processed.
  • step S212 the CPU 11, as the processing unit 58, determines whether the block in question is an updated block of the storage layer. If the block is not an update block of the storage layer, the process moves to step S124 without performing any processing. As a result, for the block, the output feature map of the past frame is directly used as the output feature map of the current frame. On the other hand, if the block is an updated block, the process moves to step S214.
  • step S214 the CPU 11, as the processing unit 58, overwrites the output feature map for the update block in the storage layer with the output feature map in the same layer and same position of the past frame on the RAM 13.
  • step S124 the CPU 11 determines whether the processing in steps S204 to S214 has been completed for all blocks. If there is a block that has not been processed in steps S204 to S214, the process returns to step S204 and the processes in steps S204 to S214 are performed for the block.
  • step S126 the CPU 11 determines whether the processes of steps S201 to S214 and S124 have been completed for all layers. If the processes in steps S201 to S214 and S124 have not been completed for all layers, the process returns to step S201 and processes the next layer. On the other hand, if the processes of steps S201 to S214 and S124 are completed for all layers, the process moves to step S128.
  • step S1208 the CPU 11 determines whether the processing in steps S110 to S126 has been completed for all frames. If the processing of steps S110 to S126 has not been completed for all frames, the process returns to step S110 and processes the next frame as the current frame. On the other hand, if the processing of steps S110 to S126 is completed for all frames, the processing routine ends.
  • step S202 is realized by a processing routine similar to the processing routine shown in FIG. 11 for each layer up to the next storage layer.
  • the CPU 11 as a block setting unit 56, sets the update area by enlarging the difference area by one pixel width or several pixel width as a margin, and sets at least part of the update area in blocks of several pixels square.
  • a block including at least a part of the update area is set as an update block, and is stored in the RAM 13 as update block information.
  • the CPU 11 as the block setting unit 56, sets the processing target area by further enlarging the difference area than the update area, determines whether or not it includes at least a part of the processing target area on a block-by-block basis, and A block including at least a part of the area is set as a processing target block, and is stored in the RAM 13 as processing target block information.
  • the image processing device determines the difference area from the past frame for frames other than key frames, and determines the difference area from the past frame for each of the predetermined storage layers.
  • An update block including an update area is set, a processing target block including a processing target area according to the difference area is set for each of the plurality of layers, and a neural network is applied to the processing target block for each of the plurality of layers. , and overwrites the saved update block of the output feature map for each saved layer.
  • a difference area is set so as to expand the difference area to the surrounding area from the previous layer according to the parameters of the convolution process, and an update block including an update area according to the difference area is set.
  • the kernel size used for convolution has been described as either 1 ⁇ 1 pixel or 3 ⁇ 3 pixel, it is not limited to this. Kernel sizes other than these may also be used.
  • the kernel size used for convolution may be 5 ⁇ 5 pixels or 7 ⁇ 7 pixels. In this case, if the kernel size used in the previous layer is 5 x 5 pixels, the difference area is expanded by 2 pixels around the periphery, and if the kernel size used in the previous layer is 7 x 7 pixels, the difference area It is sufficient to enlarge the surrounding area by three pixels.
  • the present invention is not limited to this.
  • the device including the learning section and the device including the inference section may be configured as separate devices. When hardware constraints such as power and size are large, it is preferable to configure the device including the learning section and the device including the inference section as separate devices.
  • various processes that the CPU reads and executes software (programs) in the above embodiments may be executed by various processors other than the CPU.
  • the processor in this case is a PLD (Programmable Logic Device) whose circuit configuration can be changed after manufacturing, such as an FPGA (Field-Programmable Gate Array), and an ASIC (Application Specific Intel).
  • PLD Programmable Logic Device
  • FPGA Field-Programmable Gate Array
  • ASIC Application Specific Intel
  • An example is a dedicated electric circuit that is a processor having a specially designed circuit configuration.
  • learning processing and image processing may be executed by one of these various processors, or by a combination of two or more processors of the same type or different types (for example, multiple FPGAs, and a combination of a CPU and an FPGA). combinations etc.).
  • the hardware structure of these various processors is, more specifically, an electric circuit that is a combination of circuit elements such as semiconductor elements.
  • the learning processing program and the image processing program are stored (installed) in advance in the storage 14, but the present invention is not limited to this.
  • the program can be installed on CD-ROM (Compact Disk Read Only Memory), DVD-ROM (Digital Versatile Disk Read Only Memory), and USB (Universal Serial Bus) stored in a non-transitory storage medium such as memory It may be provided in the form of Further, the program may be downloaded from an external device via a network.
  • An image processing device including a neural network including convolution processing for a moving image including multiple frames, memory and at least one processor connected to the memory; including;
  • the processor includes: Obtain the video image to be processed, Determining a difference area from a past frame for frames other than the key frame among the plurality of frames, For frames other than key frames among the plurality of frames, an update area corresponding to the difference area among the plurality of blocks obtained by dividing the output feature map for each of the plurality of layers that performs the convolution processing of the neural network.
  • the neural network is configured to process the frame to overwrite an output feature map stored for the update block;
  • the difference area is set so that the difference area is expanded to the surrounding area from the previous layer according to the parameters of the convolution process for each layer that performs the convolution process, and the difference area is An image processing device that sets an update block including an update area according to the update area.
  • a non-transitory storage medium storing a computer-executable program including a neural network including a convolution process for a moving image including a plurality of frames to perform image processing,
  • the image processing includes: Obtain the video image to be processed, Determining a difference area from a past frame for frames other than the key frame among the plurality of frames, For frames other than key frames among the plurality of frames, an update area corresponding to the difference area among the plurality of blocks obtained by dividing the output feature map for each of the plurality of layers that performs the convolution processing of the neural network.
  • the neural network is configured to process the frame to overwrite an output feature map stored for the update block;
  • the difference area is set so that the difference area is expanded to the surrounding area from the previous layer according to the parameters of the convolution process for each layer that performs the convolution process, and the difference area is A non-temporary storage medium that sets an update block containing an update area according to a non-transitory storage medium.
  • An image processing device including a neural network including convolution processing for a moving image including multiple frames, memory and at least one processor connected to the memory; including;
  • the processor includes: Obtain the video image to be processed, Determining a difference area from a past frame for frames other than the key frame among the plurality of frames, For frames other than key frames among the plurality of frames, one of the plurality of blocks obtained by dividing the output feature map for each of the predetermined storage layers of the plurality of layers that performs the convolution processing of the neural network.
  • a non-transitory storage medium storing a computer-executable program including a neural network including a convolution process for a moving image including a plurality of frames to perform image processing,
  • the image processing includes: Obtain the video image to be processed, Determining a difference area from a past frame for frames other than the key frame among the plurality of frames, For frames other than key frames among the plurality of frames, one of the plurality of blocks obtained by dividing the output feature map for each of the predetermined storage layers of the plurality of layers that performs the convolution processing of the neural network.
  • a non-transitory storage medium that sets update blocks containing updated update areas.
  • Image processing device 11
  • RAM 14
  • Storage 15
  • Input unit 16
  • Display unit 20
  • Learning unit 22
  • Inference unit 30
  • Acquisition unit 38
  • Processing unit 40
  • Update unit 50
  • Acquisition unit 52
  • Overall control unit 54
  • Difference determination unit 56
  • Block setting unit 58
  • Processing unit

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)

Abstract

画像処理装置は、処理対象である動画像を取得する取得部と、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定する差分判定部と、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定するブロック設定部と、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記更新ブロックについて前記ニューラルネットワークを用いた処理を行い、保存されている出力特徴マップを上書きする処理部と、を含み、前記ブロック設定部は、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する。

Description

画像処理装置、画像処理方法、及び画像処理プログラム
 本開示の技術は、画像処理装置、画像処理方法、及び画像処理プログラムに関する。
 CNN(Convolutional Neural Network)を用いた物体検出、姿勢推定、及びセグメンテーションなどの推論処理は基本的に1枚の画像データを対象とする処理であり、映像の各フレームにその処理を適用する場合、フレーム数に比例した演算量が必要になる。
 一方、映像シーン理解や、物体追跡など、映像データを対象とする推論処理では、前述の画像データに対する推論処理を利用しつつ適用フレームを限定し、より少ない演算量で導出可能な他の情報を併用することで演算量を抑えている。しかし、フレーム毎の変化の激しい映像では、より多くのフレーム画像に対する推論処理を行うことが望ましい。
 この場合の演算量削減手法として、映像の部分領域毎にフレーム間の変化を判定し、変化のある部分領域に対してのみCNN推論処理を行う手法があるが、部分領域を跨る推論が困難であるという問題がある。
 また非特許文献1では毎層毎画素毎にフレーム間差分を取って畳み込み演算をすることで演算量を削減する方法が提案されている。
 上記非特許文献1に記載の技術では、複雑な演算制御機構が必要となる問題がある。
 開示の技術は、上記の点に鑑みてなされたものであり、簡易な構成で、畳み込み処理を含むニューラルネットワークを用いた処理の演算量を抑制することができる画像処理装置、画像処理方法、及び画像処理プログラムを提供することを目的とする。
 本開示の第1態様は、複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、処理対象である動画像を取得する取得部と、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定する差分判定部と、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定するブロック設定部と、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記更新ブロックについて保存されている出力特徴マップを上書きする処理部と、を含み、前記ブロック設定部は、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する。
 本開示の第2態様は、複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、処理対象である動画像を取得する取得部と、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定する差分判定部と、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、前記複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定するブロック設定部と、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記保存層の各々の出力特徴マップを保存し、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記複数の層の各々に対し、前記処理対象ブロックについて前記ニューラルネットワークを用いた処理を行い、前記保存層の各々に対し、保存されている出力特徴マップの前記更新ブロックを上書きする処理部と、を含み、前記ブロック設定部は、前記保存層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する。
 本開示の第3態様は、複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置における画像処理方法であって、取得部が、処理対象である動画像を取得し、差分判定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、ブロック設定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、処理部が、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記更新ブロックについて保存されている出力特徴マップを上書きすることを含み、前記ブロック設定部が設定することでは、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する。
 本開示の第4態様は、複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置における画像処理方法であって、取得部が、処理対象である動画像を取得し、差分判定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、ブロック設定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、前記複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定し、処理部が、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記保存層の各々の出力特徴マップを保存し、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記複数の層の各々に対し、前記処理対象ブロックについて前記ニューラルネットワークを用いた処理を行い、前記保存層の各々に対し、保存されている出力特徴マップの前記更新ブロックを上書きすることを含み、前記ブロック設定部が設定することでは、前記保存層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する。
 本開示の第5態様は、第1態様又は第2態様の画像処理装置としてコンピュータを機能させるための画像処理プログラムである。
 開示の技術によれば、簡易な構成で、畳み込み処理を含むニューラルネットワークを用いた処理の演算量を抑制することができる。
第1実施形態及び第2実施形態の画像処理装置として機能するコンピュータの一例の概略ブロック図である。 第1実施形態及び第2実施形態の画像処理装置の機能構成を表すブロック図である。 第1実施形態及び第2実施形態の画像処理装置の学習部の機能構成を表すブロック図である。 第1実施形態及び第2実施形態の画像処理装置の推論部の機能構成を表すブロック図である。 層毎に設定される差分領域のイメージ図である。 差分領域、更新領域、及び更新ブロックを説明するための図である。 層毎に設定される差分領域のイメージ図である。 第1実施形態及び第2実施形態の学習処理の流れを表すフローチャートである。 第1実施形態及び第2実施形態の画像処理の流れを表すフローチャートである。 第1実施形態の画像処理における畳み込み処理の流れを表すフローチャートである。 第1実施形態の更新ブロックを設定する処理の流れを表すフローチャートである。 層毎に設定される差分領域、及び保存層毎に設定される更新ブロックのイメージ図である。 差分領域、更新領域、更新ブロック、処理対象領域、及び処理対象ブロックを説明するための図である。 第2実施形態の画像処理における畳み込み処理の流れを表すフローチャートである。
 以下、開示の技術の実施形態の一例を、図面を参照しつつ説明する。なお、各図面において同一又は等価な構成要素及び部分には同一の参照符号を付与している。また、図面の寸法比率は、説明の都合上誇張されており、実際の比率とは異なる場合がある。
<開示の技術の実施形態の概要>
 開示の技術では、以下の手順により映像の各フレームに対するCNN推論処理の演算量を削減する。
 まず、数画素×数画素のブロック単位で過去フレームと現フレームの入力画像の差分の有無を判定し、差分領域を含むブロックに対しては通常のCNN処理を1層分行い初層の処理結果とする。それ以外の差分領域を含まないブロックに対しては過去フレームの初層の処理結果を読み込んで初層の処理結果とする。それ以降の層では差分領域を初層の差分領域からの影響を受ける範囲に拡大し、拡大した差分領域を含むブロックに対しては通常のCNN処理を行い、差分領域を含まないブロックではCNN処理をスキップし過去フレームの同一層の処理結果を読み込んでその層の処理結果とする。この際に、差分領域を、3x3画素カーネルを用いた層では周辺に1画素ずつ拡大し、1x1画素カーネルを用いた層では拡大しない、等の基準で更新する。またCNN処理を行うかスキップするかはあらかじめ決められたブロック単位で判断することで効率的な実装が可能となる。
 上記に関して以下の手法を併用することができる。
 1つ目の手法としては、過去フレームの出力特徴マップの保存を、畳み込み処理を行う複数の層のうち、数層に1層に限定する。これによりデータ転送帯域やメモリ容量の削減効果が得られる保存層以外では、差分領域の外側の特徴マップが存在せず、畳み込み処理によって周囲から無効データの影響を受けるため、その分広い範囲で通常のCNN処理を行う。また、無効データの影響を受けた処理結果は廃棄し、影響を受けていない領域の処理結果のみを過去フレーム結果に対して上書きする。具体的には保存層ごとに次の保存層までに差分領域の影響が拡大する画素幅Nを求め、差分領域をN画素幅拡大した更新領域の少なくとも一部を含むブロックを更新ブロックとし、更新ブロックについてのみ過去フレームの特徴マップを上書きする。さらにその更新領域をN画素幅拡大した処理対象領域の少なくとも一部を含むブロックを処理対象ブロックとし、処理対象ブロックについてCNN処理を行う。
 もう1つの手法としては、初層の差分領域の影響を最終推論結果が受ける範囲を、縮小画像や過去フレームの推論結果などから事前に判断し、その範囲を超えて差分領域を拡大しないようにすることにより、その範囲外ではCNN処理をスキップし過去フレームの処理結果を読み込む。この方法ではCNN処理を行う領域を効果的に制限することで演算量削減効果が得られる。
[第1実施形態]
<第1実施形態に係る画像処理装置の構成>
 図1は、第1実施形態の画像処理装置10のハードウェア構成を示すブロック図である。
 図1に示すように、画像処理装置10は、CPU(Central Processing Unit)11、ROM(Read Only Memory)12、RAM13、ストレージ14、入力部15、表示部16、及び通信インタフェース(I/F)17を有する。各構成は、バス19を介して相互に通信可能に接続されている。
 CPU11は、中央演算処理ユニットであり、各種プログラムを実行したり、各部を制御したりする。すなわち、CPU11は、ROM12又はストレージ14からプログラムを読み出し、RAM13を作業領域としてプログラムを実行する。CPU11は、ROM12又はストレージ14に記憶されているプログラムに従って、上記各構成の制御及び各種の演算処理を行う。本実施形態では、ROM12又はストレージ14には、ニューラルネットワークの学習処理を行うための学習処理プログラム及びニューラルネットワークを用いた画像処理を行うための画像処理プログラムが格納されている。学習処理プログラム及び画像処理プログラムは、1つのプログラムであっても良いし、複数のプログラム又はモジュールで構成されるプログラム群であっても良い。
 ROM12は、各種プログラム及び各種データを格納する。RAM13は、作業領域として一時的にプログラム又はデータを記憶する。ストレージ14は、HDD(Hard Disk Drive)又はSSD(Solid State Drive)により構成され、オペレーティングシステムを含む各種プログラム、及び各種データを格納する。
 入力部15は、マウス等のポインティングデバイス、及びキーボードを含み、各種の入力を行うために使用される。
 入力部15は、ニューラルネットワークを学習するための学習用データを、入力として受け付ける。例えば、入力部15は、処理対象となる動画像と、予め求められた動画像に対する処理結果とを含む学習用データを、入力として受け付ける。
 また、入力部15は、処理対象となる動画像を、入力として受け付ける。
 表示部16は、例えば、液晶ディスプレイであり、処理結果を含む各種の情報を表示する。表示部16は、タッチパネル方式を採用して、入力部15として機能しても良い。
 通信インタフェース17は、他の機器と通信するためのインタフェースであり、例えば、イーサネット(登録商標)、FDDI、Wi-Fi(登録商標)等の規格が用いられる。
 次に、画像処理装置10の機能構成について説明する。図2は、画像処理装置10の機能構成の例を示すブロック図である。
 画像処理装置10は、機能的には、図2に示すように、学習部20及び推論部22を備えている。
 学習部20は、図3に示すように、取得部30、処理部38、及び更新部40を備えている。
 取得部30は、入力された学習用データの動画像及び処理結果を取得する。
 処理部38は、動画像の各フレームについて畳み込み処理を含むニューラルネットワークを用いて処理する。
 更新部40は、動画像に対してニューラルネットワークを用いて処理した結果と、予め求められた処理結果とが一致するように、ニューラルネットワークのパラメータを更新する。
 予め定められた反復終了条件を満たすまで、処理部38及び更新部40の各処理が繰り返し行われる。これにより、ニューラルネットワークが学習される。
 推論部22は、図4に示すように、取得部50、全体制御部52、差分判定部54、ブロック設定部56、及び処理部58を備えている。
 取得部50は、入力された処理対象である動画像を取得する。
 全体制御部52は、処理対象である動画像の複数のフレームの各々について、キーフレームであるか否かを判定する。ここで、複数のフレームから、予め定められた周期でキーフレームとして指定されているものとする。なお、差分領域の割合が閾値以上となるフレームをキーフレームと判定するようにしてもよい。
 差分判定部54は、複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定する。
 ブロック設定部56は、複数のフレームのうちのキーフレーム以外のフレームについて、ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、差分領域に応じた更新領域の少なくとも一部を含む更新ブロックを設定する。このとき、ブロック設定部56は、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より差分領域を周囲に拡大するように、差分領域を設定し(図5参照)、差分領域に応じた更新領域の少なくとも一部を含む更新ブロックを設定する(図6参照)。図5は、初層の差分領域に比べて、層が深くなるごとに差分領域が拡大し、通常のCNN処理を行う範囲が拡大し、過去フレームの処理結果を読み込む処理スキップを行う範囲が縮小する例を示している。また、図6は、差分領域(点線の矩形)を周囲に拡大した更新領域(実線の矩形)を少なくとも一部含む4つのブロック(破線の矩形)が更新ブロックとして設定される例を示している。
 また、ブロック設定部56は、事前に指定した領域より拡大しないように差分領域を設定することが好ましい(図7参照)。また、ブロック設定部56は、事前に指定した層より後の層で、差分領域を拡大しないように差分領域を設定することが好ましい。図7は、初層の差分領域に比べて、層が深くなるごとに、事前に指定した領域を上限として差分領域が拡大し、事前に指定した領域に到達した層より後では、通常のCNN処理を行う範囲が拡大しない例を示している。
 処理部58は、複数のフレームのうちのキーフレームについて、ニューラルネットワークを用いてフレームを処理する通常のCNN推論処理を行い、各層の出力特徴マップを保存する。
 ここでいう通常のCNN推論処理とは、初層から最終層までの各層において、入力特徴マップを入力し畳み込み処理と活性化関数処理、ダウンサンプル処理、アップサンプル処理、他層の出力特徴マップとの合算・連結処理等を行い、出力特徴マップを出力することを指す。また、初層の入力特徴マップは、RGBの3チャネル等からなる画像データであり、最終層の出力特徴マップは推論結果に関する情報が各チャネルに格納されたデータであるものとする。また、以下では便宜上、畳み込みに用いるカーネルサイズは1×1画素か3×3画素のどちらかであるものとするが、それに限るものではない。
 また、処理部58は、複数のフレームのうちのキーフレーム以外のフレームについて、差分領域を含むブロックについてニューラルネットワークを用いた処理を行い、保存されている出力特徴マップを上書きする。
 動画像に対してニューラルネットワークを用いて処理した結果が、表示部16により表示される。
<第1実施形態に係る画像処理装置の作用>
 次に、第1実施形態に係る画像処理装置10の作用について説明する。
 図8は、画像処理装置10による学習処理の流れを示すフローチャートである。CPU11がROM12又はストレージ14から学習処理プログラムを読み出して、RAM13に展開して実行することにより、学習処理が行なわれる。また、画像処理装置10に、学習用データが入力される。
 ステップS100で、CPU11は、取得部30として、入力された学習用データの動画像及び処理結果を取得する。
 ステップS102で、CPU11は、処理部38として、畳み込み処理を含むニューラルネットワークを用いて、学習用データの動画像を処理する。
 ステップS104で、CPU11は、更新部40として、学習用データの動画像に対してニューラルネットワークを用いて処理した結果と、予め求められた処理結果とが一致するように、ニューラルネットワークのパラメータを更新する。
 ステップS106で、CPU11は、予め定められた反復終了条件を満たしたか否かを判定する。反復終了条件を満たしていない場合には、上記ステップS102へ戻り、処理部38、及び更新部40の各処理が繰り返し行われる。これにより、ニューラルネットワークが学習される。
 図9は、画像処理装置10による画像処理の流れを示すフローチャートである。CPU11がROM12又はストレージ14から画像処理プログラムを読み出して、RAM13に展開して実行することにより、画像処理が行なわれる。また、画像処理装置10に、処理対象となる動画像が入力される。
 ステップS107で、CPU11は、取得部50として、入力された動画像を取得する。
 ステップS109で、CPU11は、上述した学習処理により学習されたニューラルネットワークを用いて、動画像を処理する。そして、動画像に対してニューラルネットワークを用いて処理した結果が、表示部16により表示される。
 上記ステップS109は、図10に示す処理ルーチンによって実現される。ここで、動画像の各フレームを、順番に現フレームとする。
 まず、ステップS110で、CPU11は、全体制御部52として、現フレームがキーフレームであるか否かを判定する。現フレームがキーフレームであると判定された場合には、ステップS112へ移行する。一方、現フレームがキーフレームでないと判定された場合には、ステップS114へ移行する。
 ステップS112において、CPU11は、処理部58として、現フレームに対して通常のCNN推論処理を行い、各層の出力特徴マップを全てRAM13に保存する。また、推論結果は処理部58から表示部16に出力される。
 ステップS114において、CPU11は、差分判定部54として、現フレームの画像と累積更新画像との間で画素差分を取り差分領域の判定を行う。ここで累積更新画像とはキーフレームの画像に対して、それ以降の各フレームで差分があると判定された領域をそのフレームの入力画像で置き換えていった画像である。差分領域の判定においては両画像の画素差分値の閾値処理や周辺画素との比較処理等によってノイズの影響を除去し、視覚的に有意な差がある領域のみを差分領域として画素単位で判定する。
 ステップS116において、CPU11は、ブロック設定部56として、当該層について、畳み込み処理のパラメータに応じて、前の層より差分領域を周囲に拡大するように、差分領域を設定し、マージンとして差分領域を1画素幅もしくは数画素幅分拡大して更新領域を設定し、数画素四方のブロック単位で更新領域の少なくとも一部を含むか否かを判定し、更新領域の少なくとも一部を含むブロックを更新ブロックとして設定し、更新ブロック情報としてRAM13に保存する。
 ステップS118、S120において、CPU11は、処理部58として、RAM13から読み込んだ更新ブロック情報に基づいて1層分の処理を行う。具体的には、ステップS118において、CPU11は、処理部58として、当該ブロックが更新ブロックであるか否かを判定する。当該ブロックが更新ブロックでない場合には処理を行わずにステップS124へ移行する。これにより、当該ブロックについて、過去フレームの出力特徴マップをそのまま現フレームの出力特徴マップとする。
 一方、当該ブロックが更新ブロックである場合にはステップS120へ移行する。ステップS120では、CPU11は、処理部58として、更新ブロックに対して、畳み込み処理に必要な周辺画素を含めて入力特徴マップを読み込み、通常のCNN推論処理と同様に畳み込み処理やその結果に対する活性化関数処理等を行う。
 ステップS122では、CPU11は、処理部58として、更新ブロックに対して、出力特徴マップをRAM13上の過去フレームの同層同位置の出力特徴マップに上書きする。
 ステップS124において、CPU11は、全ブロックについて、上記ステップS118~S122の処理を完了したか否かを判定する。上記ステップS118~S122の処理を行っていないブロックが存在する場合には、上記ステップS118へ戻り、当該ブロックについて、上記ステップS118~S122の処理を行う。
 ステップS126において、CPU11は、全ての層について、上記ステップS116~S124の処理を完了したか否かを判定する。全ての層について、上記ステップS116~S124の処理を完了していない場合には、上記ステップS116へ戻り、次の層の処理を行う。一方、全ての層について、上記ステップS116~S124の処理を完了した場合には、ステップS128へ移行する。
 ステップS128において、CPU11は、全てのフレームについて、上記ステップS110~S126の処理を完了したか否かを判定する。全てのフレームについて、上記ステップS110~S126の処理を完了していない場合には、上記ステップS110へ戻り、次のフレームを現フレームとして処理を行う。一方、全てのフレームについて、上記ステップS110~S126の処理を完了した場合には、当該処理ルーチンを終了する。
 上記ステップS116は、図11に示す処理ルーチンにより実現される。
 まず、ステップS130において、CPU11は、ブロック設定部56として、上記ステップS114での差分領域の判定結果を示す情報を取得する。
 ステップS132において、CPU11は、ブロック設定部56として、一つ前の層のカーネルサイズが1×1であるか否かを判定する。一つ前の層のカーネルサイズが1×1である場合には、ステップS140へ移行する。一方、一つ前の層のカーネルサイズが1×1ではなく、3×3である場合には、ステップS134へ移行する。
 ステップS134において、CPU11は、ブロック設定部56として、当該層が、事前に指定した層より後であるか否かを判定する。当該層が、事前に指定した層より後である場合には、ステップS140へ移行する。一方、当該層が、事前に指定した層以前である場合には、ステップS136へ移行する。
 ステップS136において、CPU11は、ブロック設定部56として、当該層について、畳み込み処理のパラメータに応じて、前の層より差分領域を周囲に拡大した場合に、事前に指定した領域を超えるか否かを判定する。前の層より差分領域を周囲に拡大した場合に、事前に指定した領域を超えると判定された場合には、ステップS140へ移行する。一方、前の層より差分領域を周囲に拡大した場合に、事前に指定した領域を超えないと判定された場合には、ステップS138へ移行する。
 上記ステップS134の判定により、事前に指定した層より後の層では差分領域を周辺に拡大することを行わない。また、指定した層以前であっても、上記ステップS136の判定により、事前に指定した領域より外側には差分領域を拡大しない。これにより更新ブロックが特徴マップ全体に広がることを防ぎ、演算量を削減することができる。
 なお、これは画像内の局所的な変化がより広い範囲の推論結果に影響を及ぼさないことが事前に分かっている場合、たとえば画像内にある程度小さな物体しか映っていないことがあらかじめ分かっている場合や、指定した領域の外側で推論結果の変化がないことが、他の推論結果などの情報から事前に判断できる場合に有効である。
 ステップS138において、CPU11は、ブロック設定部56として、差分領域を周辺に1画素拡大する。これは、直前層の畳み込み処理のカーネルサイズが1×1画素より大きい場合は差分領域の影響が周辺に拡大するためである。
 ステップS140において、CPU11は、ブロック設定部56として、一つ前の層が1/2のダウンサンプルを伴うか否かを判定する。一つ前の層が1/2のダウンサンプルを伴わない場合には、ステップS144へ移行する。一方、一つ前の層が1/2のダウンサンプルを伴う場合には、ステップS142へ移行する。
 ステップS142において、CPU11は、ブロック設定部56として、差分領域を画素単位で1/2にダウンサンプルする。この際に2×2画素中に1画素以上差分領域があれば差分領域とする。
 ステップS144において、CPU11は、ブロック設定部56として、一つ前の層がアップサンプルを伴うか否かを判定する。一つ前の層がアップサンプルを伴わない場合には、ステップS148へ移行する。一方、一つ前の層がアップサンプルを伴う場合には、ステップS146へ移行する。
 ステップS146において、CPU11は、ブロック設定部56として、差分領域を画素単位でアップサンプルする。
 ステップS148において、CPU11は、ブロック設定部56として、マージンとして差分領域を1画素幅もしくは数画素幅分拡大して更新領域を設定し、数画素四方のブロック単位で更新領域の少なくとも一部を含むか否かを判定し、更新領域の少なくとも一部を含むブロックを更新ブロックとして設定し、更新ブロック情報としてRAM13に保存する。更新した差分領域情報についてもRAM13に出力する。差分領域情報については画素単位の情報としてもよいし、ブロック単位の情報とそこから拡大した画素幅の情報の組み合わせとしてもよい。
 以上説明したように、第1実施形態に係る画像処理装置は、キーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、畳み込み処理を行う複数の層の各々に対し、差分領域に応じた更新領域を含む更新ブロックを設定し、更新ブロックについて保存されている出力特徴マップを上書きする。また、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する。これにより、簡易な構成で、畳み込み処理を含むニューラルネットワークを用いた処理の演算量を抑制することができる。
 なお、上記実施形態では、差分判定を直前フレームでなく累積更新画像に対して行う場合を例に説明したが、これは、差分なしの判定が同一領域で複数フレーム連続した場合に微小な差分が累積して精度が低下することを回避するためである。そのため、差分判定を直前フレームに対して行い、代わりにキーフレームをより頻繁に挿入するようにしてもよい。また、差分判定を、演算量削減とノイズ影響低減のため入力画像の縮小画像で行うようにしてもよい。
[第2実施形態]
 次に、第2実施形態について説明する。なお、第2実施形態に係る画像処理装置は、第1実施形態と同様の構成であるため、同一符号を付して説明を省略する。
 第1実施形態では、過去フレームの全層の出力特徴マップをRAMに保存し上書き更新していたが、第2実施形態では、メモリ容量や帯域を削減するためにRAMに出力特徴マップを保存する層を限定する点が、第1実施形態と異なっている。
<第2実施形態に係る画像処理装置の構成>
 第2実施形態に係る画像処理装置10のブロック設定部56は、複数のフレームのうちのキーフレーム以外のフレームについて、ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、差分領域に応じた更新領域を含む更新ブロックを設定する。このとき、ブロック設定部56は、予め定められた保存層毎に、畳み込み処理のパラメータに応じて、前の層より差分領域を周囲に拡大するように、差分領域を設定し(図12)、差分領域に応じた更新領域を含む更新ブロックを設定する(図13)。また、ブロック設定部56は、畳み込み処理を行う層毎に、差分領域に応じた処理対象領域を含む処理対象ブロックを設定する(図13)。
 図12は、初層の差分領域に比べて、層が深くなるごとに差分領域が拡大し、通常のCNN処理を行う範囲が拡大し、過去フレームの処理結果を読み込む処理スキップを行う範囲が縮小する例を示している。また、保存層毎に、特徴マップを書き出して上書きする更新ブロックが設定される例を示している。また、無効データの影響部分を考慮して差分領域を拡大して、特徴マップを読み込む部分である処理対象ブロックが設定される例を示している。
 また、図13は、差分領域(点線の矩形)を周囲に拡大した更新領域(一番内側の実線の矩形)を少なくとも一部含む4つのブロック(破線の矩形)が更新ブロックとして設定される例を示している。また、差分領域を更に周囲に拡大した処理対象領域(外側の実線の矩形)を少なくとも一部含む6つのブロック(破線の矩形)が処理対象ブロックとして設定される例を示している。
 また、ブロック設定部56は、事前に指定した領域より拡大しないように差分領域を設定することが好ましい。また、ブロック設定部56は、事前に指定した層より後の層で、差分領域を拡大しないように差分領域を設定することが好ましい。
 処理部58は、複数のフレームのうちのキーフレームについて、ニューラルネットワークを用いてフレームを処理する通常のCNN推論処理を行い、各保存層の出力特徴マップを保存する。
 また、処理部58は、複数のフレームのうちのキーフレーム以外のフレームについて、畳み込み処理を行う複数の層の各々に対し、処理対象ブロックについてニューラルネットワークを用いた処理を行い、保存層の各々に対し、保存されている出力特徴マップの更新ブロックを上書きする。
<第2実施形態に係る画像処理装置の作用>
 次に、第2実施形態に係る画像処理装置10の作用について説明する。なお、第1実施形態と同様の処理については、同一符号を付して説明を省略する。
 画像処理装置10において、上記図8に示す学習処理が行われる。また、画像処理装置10において、上記図9に示す画像処理が行われる。このとき、上記ステップS109は、図14に示す処理ルーチンによって実現される。ここで、動画像の各フレームを、順番に現フレームとする。
 まず、ステップS110で、CPU11は、全体制御部52として、現フレームがキーフレームであるか否かを判定する。現フレームがキーフレームであると判定された場合には、ステップS200へ移行する。一方、現フレームがキーフレームでないと判定された場合には、ステップS114へ移行する。
 ステップS200において、CPU11は、処理部58として、現フレームに対して通常のCNN推論処理を行い、各保存層の出力特徴マップを全てRAM13に保存する。また、推論結果は処理部58から表示部16に出力される。
 ステップS114において、CPU11は、差分判定部54として、現フレームの画像と累積更新画像との間で画素差分を取り差分領域の判定を行う。
 ステップS201において、CPU11は、当該層が初層であるか、又は前の層が保存層であるか否かを判定する。当該層が初層であるか、又は前の層が保存層である場合には、ステップS202へ移行する。一方、当該層が初層ではなく、かつ、前の層が保存層でない場合には、ステップS204へ移行する。
 ステップS202において、CPU11は、ブロック設定部56として、次の保存層までの各層について、畳み込み処理のパラメータに応じて、前の層より差分領域を周囲に拡大するように、差分領域を設定し、次の保存層について、マージンとして差分領域を1画素幅もしくは数画素幅分拡大して更新領域を設定し、数画素四方のブロック単位で更新領域の少なくとも一部を含むか否かを判定し、更新領域の少なくとも一部を含むブロックを更新ブロックとして設定し、更新ブロック情報としてRAM13に保存する。また、次の保存層までの各層について、差分領域を更に拡大して処理対象領域を設定し、ブロック単位で処理対象領域の少なくとも一部を含むか否かを判定し、処理対象領域の少なくとも一部を含むブロックを処理対象ブロックとして設定し、処理対象ブロック情報としてRAM13に保存する。
 例えば、次の保存層までのカーネルサイズが3×3画素の層の数Nを取得し、差分領域をN画素幅分拡大した領域を、次の保存層での差分領域として設定し、マージンとして差分領域を1画素幅もしくは数画素幅分拡大して更新領域を設定し、更新領域の少なくとも一部を含むブロックを更新ブロックとして設定する。また、次の保存層までの各層について、差分領域を更に拡大した処理対象領域を設定し、処理対象領域の少なくとも一部を含むブロックを処理対象ブロックとして設定する。
 なお、これは、保存層以外では、更新ブロックの外側の入力特徴マップが存在せず無効なデータを参照することになり、周囲からN画素幅分無効なデータの影響が浸食するためその分広い範囲を処理する必要があるためである。
 また、次の保存層までの間にダウンサンプルやアップサンプルを含む場合は差分領域の拡大と併せて差分領域のダウンサンプルやアップサンプルを行い更新ブロックや処理対象ブロックの範囲を算出する。
 ステップS204において、処理部58として、当該ブロックが処理対象ブロックであるか否かを判定する。当該ブロックが処理対象ブロックである場合には、ステップS206へ移行する。一方、当該ブロックが処理対象ブロックでない場合には、ステップS124へ移行する。
 ステップS206において、CPU11は、処理部58として、RAM13から、畳み込み処理に必要な周辺画素を含めて入力特徴マップを読み込み、通常のCNN推論処理と同様に入力特徴マップの畳み込み処理やその結果に対する活性化関数処理等を行う。それ以外のブロックについては何も処理をしない。ここで、処理対象ブロックの周辺画素データがメモリに保存されていない場合は無効データを読み込む。
 ステップS208において、CPU11は、処理部58として、当該層が保存層であるか否かを判定する。当該層が保存層でない場合には、ステップS210へ移行する。一方、当該層が保存層である場合には、ステップS212へ移行する。
 ステップS210では、処理対象ブロックの出力特徴マップをRAM13に一時保存する。この処理対象ブロックの出力特徴マップは、次の層の処理まで保存される。
 ステップS212において、CPU11は、処理部58として、当該ブロックが、保存層の更新ブロックであるか否かを判定する。当該ブロックが保存層の更新ブロックでない場合には処理を行わずにステップS124へ移行する。これにより、当該ブロックについて、過去フレームの出力特徴マップをそのまま現フレームの出力特徴マップとする。一方、当該ブロックが更新ブロックである場合にはステップS214へ移行する。
 ステップS214では、CPU11は、処理部58として、保存層の更新ブロックに対して、出力特徴マップをRAM13上の過去フレームの同層同位置の出力特徴マップに上書きする。
 ステップS124において、CPU11は、全ブロックについて、上記ステップS204~S214の処理を完了したか否かを判定する。上記ステップS204~S214の処理を行っていないブロックが存在する場合には、上記ステップS204へ戻り、当該ブロックについて、上記ステップS204~S214の処理を行う。
 ステップS126において、CPU11は、全ての層について、上記ステップS201~S214、S124の処理を完了したか否かを判定する。全ての層について、上記ステップS201~S214、S124の処理を完了していない場合には、上記ステップS201へ戻り、次の層の処理を行う。一方、全ての層について、上記ステップS201~S214、S124の処理を完了した場合には、ステップS128へ移行する。
 ステップS128において、CPU11は、全てのフレームについて、上記ステップS110~126の処理を完了したか否かを判定する。全てのフレームについて、上記ステップS110~S126の処理を完了していない場合には、上記ステップS110へ戻り、次のフレームを現フレームとして処理を行う。一方、全てのフレームについて、上記ステップS110~S126の処理を完了した場合には、当該処理ルーチンを終了する。
 上記ステップS202は、次の保存層までの各層について、図11に示す処理ルーチンと同様の処理ルーチンによって実現される。ただし、ステップS148において、CPU11は、ブロック設定部56として、マージンとして差分領域を1画素幅もしくは数画素幅分拡大して更新領域を設定し、数画素四方のブロック単位で更新領域の少なくとも一部を含むか否かを判定し、更新領域の少なくとも一部を含むブロックを更新ブロックとして設定し、更新ブロック情報としてRAM13に保存する。また、CPU11は、ブロック設定部56として、差分領域を、更新領域より更に拡大して処理対象領域を設定し、ブロック単位で処理対象領域の少なくとも一部を含むか否かを判定し、処理対象領域の少なくとも一部を含むブロックを処理対象ブロックとして設定し、処理対象ブロック情報としてRAM13に保存する。
 なお、第2実施形態に係る画像処理装置の他の構成及び作用については、第1実施形態と同様であるため、説明を省略する。
 以上説明したように、第2実施形態に係る画像処理装置は、キーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、予め定められた保存層の各々に対し、差分領域に応じた更新領域を含む更新ブロックを設定し、複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定し、複数の層の各々に対し、処理対象ブロックについてニューラルネットワークを用いた処理を行い、保存層の各々に対し、保存されている出力特徴マップの更新ブロックを上書きする。また、保存層毎に、畳み込み処理のパラメータに応じて、前の層より差分領域を周囲に拡大するように、差分領域を設定し、差分領域に応じた更新領域を含む更新ブロックを設定する。これにより、簡易な構成で、畳み込み処理を含むニューラルネットワークを用いた処理の演算量を抑制することができる。
 なお、本発明は、上述した実施形態の装置構成及び作用に限定されるものではなく、この発明の要旨を逸脱しない範囲内で様々な変形や応用が可能である。
 例えば、畳み込みに用いるカーネルサイズは1×1画素か3×3画素のどちらかである場合を例に説明したが、これに限定されるものではない。これら以外のカーネルサイズを用いてもよい。例えば、畳み込みに用いるカーネルサイズが5×5画素や7×7画素であってもよい。この場合、前の層で用いたカーネルサイズが5×5画素であれば、差分領域を周辺に2画素ずつ拡大し、前の層で用いたカーネルサイズが7×7画素であれば、差分領域を周辺に3画素ずつ拡大すればよい。
 また、画像処理装置が、学習部と推論部とを備えている場合を例に説明したが、これに限定されるものではない。学習部を備えた装置と、推論部を備えた装置とを別の装置として構成してもよい。電力やサイズ等のハードウェアの制約が大きい場合に、学習部を備えた装置と、推論部を備えた装置とを別の装置として構成する方が好ましい。
 また、上記実施形態でCPUがソフトウェア(プログラム)を読み込んで実行した各種処理を、CPU以外の各種のプロセッサが実行してもよい。この場合のプロセッサとしては、FPGA(Field-Programmable Gate Array)等の製造後に回路構成を変更可能なPLD(Programmable Logic Device)、及びASIC(Application Specific Integrated Circuit)等の特定の処理を実行させるために専用に設計された回路構成を有するプロセッサである専用電気回路等が例示される。また、学習処理及び画像処理を、これらの各種のプロセッサのうちの1つで実行してもよいし、同種又は異種の2つ以上のプロセッサの組み合わせ(例えば、複数のFPGA、及びCPUとFPGAとの組み合わせ等)で実行してもよい。また、これらの各種のプロセッサのハードウェア的な構造は、より具体的には、半導体素子等の回路素子を組み合わせた電気回路である。
 また、上記各実施形態では、学習処理プログラム及び画像処理プログラムがストレージ14に予め記憶(インストール)されている態様を説明したが、これに限定されない。プログラムは、CD-ROM(Compact Disk Read Only Memory)、DVD-ROM(Digital Versatile Disk Read Only Memory)、及びUSB(Universal Serial Bus)メモリ等の非一時的(non-transitory)記憶媒体に記憶された形態で提供されてもよい。また、プログラムは、ネットワークを介して外部装置からダウンロードされる形態としてもよい。
 以上の実施形態に関し、更に以下の付記を開示する。
 (付記項1)
 複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、
 メモリと、
 前記メモリに接続された少なくとも1つのプロセッサと、
 を含み、
 前記プロセッサは、
 処理対象である動画像を取得し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、
 前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記更新ブロックについて保存されている出力特徴マップを上書きする
 ように構成され、
 前記更新ブロックを設定することでは、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
 画像処理装置。
 (付記項2)
 画像処理を実行するように、複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含むコンピュータによって実行可能なプログラムを記憶した非一時的記憶媒体であって、
 前記画像処理は、
 処理対象である動画像を取得し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、
 前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記更新ブロックについて保存されている出力特徴マップを上書きする
 ように構成され、
 前記更新ブロックを設定することでは、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
 非一時的記憶媒体。
 (付記項3)
 複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、
 メモリと、
 前記メモリに接続された少なくとも1つのプロセッサと、
 を含み、
 前記プロセッサは、
 処理対象である動画像を取得し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、前記複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定し、
 前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記保存層の各々の出力特徴マップを保存し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記複数の層の各々に対し、前記処理対象ブロックについて前記ニューラルネットワークを用いた処理を行い、前記保存層の各々に対し、保存されている出力特徴マップの前記更新ブロックを上書きする
 ように構成され、
 前記更新ブロックを設定することでは、前記保存層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
 画像処理装置。
 (付記項4)
 画像処理を実行するように、複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含むコンピュータによって実行可能なプログラムを記憶した非一時的記憶媒体であって、
 前記画像処理は、
 処理対象である動画像を取得し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、前記複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定し、
 前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記保存層の各々の出力特徴マップを保存し、
 前記複数のフレームのうちのキーフレーム以外のフレームについて、前記複数の層の各々に対し、前記処理対象ブロックについて前記ニューラルネットワークを用いた処理を行い、前記保存層の各々に対し、保存されている出力特徴マップの前記更新ブロックを上書きする
 ように構成され、
 前記更新ブロックを設定することでは、前記保存層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
 非一時的記憶媒体。
10   画像処理装置
11   CPU
13   RAM
14   ストレージ
15   入力部
16   表示部
20   学習部
22   推論部
30   取得部
38   処理部
40   更新部
50   取得部
52   全体制御部
54   差分判定部
56   ブロック設定部
58   処理部

Claims (8)

  1.  複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、
     処理対象である動画像を取得する取得部と、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定する差分判定部と、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定するブロック設定部と、
     前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記更新ブロックについて保存されている出力特徴マップを上書きする処理部と、
     を含み、
     前記ブロック設定部は、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
     画像処理装置。
  2.  複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、
     処理対象である動画像を取得する取得部と、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定する差分判定部と、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、前記複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定するブロック設定部と、
     前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記保存層の各々の出力特徴マップを保存し、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、前記複数の層の各々に対し、前記処理対象ブロックについて前記ニューラルネットワークを用いた処理を行い、前記保存層の各々に対し、保存されている出力特徴マップの前記更新ブロックを上書きする処理部と、
     を含み、
     前記ブロック設定部は、前記保存層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
     画像処理装置。
  3.  前記ブロック設定部は、事前に指定した領域より拡大しないように前記差分領域を設定する、請求項1記載の画像処理装置。
  4.  前記ブロック設定部は、事前に指定した領域より拡大しないように前記差分領域を設定する、請求項2記載の画像処理装置。
  5.  前記ブロック設定部は、事前に指定した層より後の層で、前記差分領域を拡大しないように前記差分領域を設定する、請求項1記載の画像処理装置。
  6.  複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置における画像処理方法であって、
     取得部が、処理対象である動画像を取得し、
     差分判定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、
     ブロック設定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、
     処理部が、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、各層の出力特徴マップを保存し、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記更新ブロックについて保存されている出力特徴マップを上書きする
     ことを含み、
     前記ブロック設定部が設定することでは、畳み込み処理を行う層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
     画像処理方法。
  7.  複数のフレームを含む動画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置における画像処理方法であって、
     取得部が、処理対象である動画像を取得し、
     差分判定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、過去フレームとの差分領域を判定し、
     ブロック設定部が、前記複数のフレームのうちのキーフレーム以外のフレームについて、前記ニューラルネットワークの畳み込み処理を行う複数の層のうちの予め定められた保存層の各々に対し、出力特徴マップを分割した複数のブロックのうち、前記差分領域に応じた更新領域を含む更新ブロックを設定し、前記複数の層の各々に対し、前記差分領域に応じた処理対象領域を含む処理対象ブロックを設定し、
     処理部が、前記複数のフレームのうちのキーフレームについて、前記ニューラルネットワークを用いて前記フレームを処理して、前記保存層の各々の出力特徴マップを保存し、
     前記複数のフレームのうちのキーフレーム以外のフレームについて、前記複数の層の各々に対し、前記処理対象ブロックについて前記ニューラルネットワークを用いた処理を行い、前記保存層の各々に対し、保存されている出力特徴マップの前記更新ブロックを上書きする
     ことを含み、
     前記ブロック設定部が設定することでは、前記保存層毎に、畳み込み処理のパラメータに応じて、前の層より前記差分領域を周囲に拡大するように、前記差分領域を設定し、前記差分領域に応じた更新領域を含む更新ブロックを設定する
     画像処理方法。
  8.  請求項1~請求項5の何れか1項記載の画像処理装置としてコンピュータを機能させるための画像処理プログラム。
PCT/JP2022/024149 2022-06-16 2022-06-16 画像処理装置、画像処理方法、及び画像処理プログラム WO2023243040A1 (ja)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/JP2022/024149 WO2023243040A1 (ja) 2022-06-16 2022-06-16 画像処理装置、画像処理方法、及び画像処理プログラム

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2022/024149 WO2023243040A1 (ja) 2022-06-16 2022-06-16 画像処理装置、画像処理方法、及び画像処理プログラム

Publications (1)

Publication Number Publication Date
WO2023243040A1 true WO2023243040A1 (ja) 2023-12-21

Family

ID=89192524

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2022/024149 WO2023243040A1 (ja) 2022-06-16 2022-06-16 画像処理装置、画像処理方法、及び画像処理プログラム

Country Status (1)

Country Link
WO (1) WO2023243040A1 (ja)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018077829A (ja) * 2016-11-09 2018-05-17 パナソニックIpマネジメント株式会社 情報処理方法、情報処理装置およびプログラム
JP2018101317A (ja) * 2016-12-21 2018-06-28 ホーチキ株式会社 異常監視システム
JP2020181404A (ja) * 2019-04-25 2020-11-05 住友電気工業株式会社 画像分類器、画像分類方法及びコンピュータプログラム

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018077829A (ja) * 2016-11-09 2018-05-17 パナソニックIpマネジメント株式会社 情報処理方法、情報処理装置およびプログラム
JP2018101317A (ja) * 2016-12-21 2018-06-28 ホーチキ株式会社 異常監視システム
JP2020181404A (ja) * 2019-04-25 2020-11-05 住友電気工業株式会社 画像分類器、画像分類方法及びコンピュータプログラム

Similar Documents

Publication Publication Date Title
CN109410123B (zh) 基于深度学习的去除马赛克的方法、装置及电子设备
EP3779769B1 (en) Optical flow computing method and computing device
CN112930552A (zh) 大尺寸图像的训练和放大
EP3633559A1 (en) Information processing apparatus, information processing method, non-transitory computer-readable storage medium
US20220351413A1 (en) Target detection method, computer device and non-transitory readable storage medium
CN113327193A (zh) 图像处理方法、装置、电子设备和介质
CN115147580A (zh) 图像处理装置、图像处理方法、移动装置和存储介质
JP2014107686A (ja) 画像処理装置
WO2023243040A1 (ja) 画像処理装置、画像処理方法、及び画像処理プログラム
EP3028250B1 (en) Method and device for enhancing edge of image and digital camera
KR100791374B1 (ko) 색역 내에 존재하는 색상을 영상 적응적으로 조절하는 방법및 장치
KR101582578B1 (ko) 그래픽 처리 장치 및 방법
JP7405370B2 (ja) デプスマップ超解像装置、デプスマップ超解像方法、及びデプスマップ超解像プログラム
CN104517273A (zh) 一种图像超分辨率处理方法及装置
US11164373B2 (en) Graphics processing apparatus
CN113034366A (zh) 无拼接缝sar图像分割并行加速处理方法
JP2011101336A (ja) 階層マスク生成装置、フレーム補間処理装置
CN112184568A (zh) 图像处理方法、装置、电子设备及可读存储介质
CN111626935B (zh) 像素图缩放方法、游戏内容生成方法及装置
WO2022259574A1 (ja) 画像処理装置、画像処理方法、及び画像処理プログラム
JPH01288974A (ja) 画像処理方法
US9947114B2 (en) Modifying gradation in an image frame including applying a weighting to a previously processed portion of the image frame
JP5932855B2 (ja) 画像処理システム、画像処理方法及び画像処理プログラム
JP6199101B2 (ja) 描画方法、描画装置、および描画プログラム
CN116342434B (zh) 一种图像处理方法、装置、设备及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22946857

Country of ref document: EP

Kind code of ref document: A1