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

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

Info

Publication number
WO2023238237A1
WO2023238237A1 PCT/JP2022/022961 JP2022022961W WO2023238237A1 WO 2023238237 A1 WO2023238237 A1 WO 2023238237A1 JP 2022022961 W JP2022022961 W JP 2022022961W WO 2023238237 A1 WO2023238237 A1 WO 2023238237A1
Authority
WO
WIPO (PCT)
Prior art keywords
small area
processing
small
feature
features
Prior art date
Application number
PCT/JP2022/022961
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/022961 priority Critical patent/WO2023238237A1/ja
Publication of WO2023238237A1 publication Critical patent/WO2023238237A1/ja

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • 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.
  • FIGS. 25 and 26 Examples of convolution operations when the kernel size is 3 ⁇ 3 are shown in FIGS. 25 and 26.
  • FIG. 25 shows an example in which a 3 ⁇ 3 kernel is used to perform a convolution operation on a 3 ⁇ 3 input feature map.
  • the product-sum operation is performed nine times, and a 1 ⁇ 1 output feature map is output.
  • FIG. 26 shows an example of performing a convolution operation on a (W+2) ⁇ (H+2) input feature map using a 3 ⁇ 3 kernel.
  • the product-sum operation is repeated nine times while moving the kernel on the input feature map, and a W ⁇ H output feature map is output.
  • FIG. 28 shows an example in which the output small area size is 4 ⁇ 2, the kernel size is 3 ⁇ 3, and 4-bit data representing 0 to 15 is used.
  • the size of the small area of the input feature map is 6 ⁇ 4, and the values of the small area represented by dotted lines are all 0. Since the result of the product-sum operation for 0 is 0, there is no need to perform convolution processing in the arithmetic circuit, and it is possible to skip convolution processing for the small area.
  • the small area corresponding to the predetermined feature is , the small area has a difference from the predetermined feature that is less than or equal to a threshold value, and the small area that corresponds to the feature of the previously processed small area has the feature of the previously processed small area.
  • the difference is the small area that is less than or equal to the threshold value.
  • the convolution process When performing the convolution process, if the features constituting the small area correspond to predetermined features or features of a previously processed small area, the convolution process is not performed on the small area, and the A result processed for a predetermined feature or a result processed in the past is output as a result of processing the small area, and the small area corresponding to the predetermined feature is
  • the small region is such that the difference from the feature of the previously processed small region is less than or equal to a threshold, and the small region corresponding to the feature of the previously processed small region has a difference from the feature of the previously processed small region. This is the small area below the threshold value.
  • FIG. 2 is a flowchart illustrating a process for determining whether small areas have the same value according to the first embodiment;
  • FIG. FIG. 2 is a flowchart illustrating a process for determining whether small areas are consecutively the same in the first embodiment;
  • FIG. FIG. 2 is a flowchart illustrating a process for determining whether small areas have the same value according to the first embodiment;
  • FIG. FIG. 2 is a flowchart illustrating a process for determining whether small areas are consecutively the same in the first embodiment;
  • FIG. It is a flowchart showing the flow of image processing in the first embodiment, the second embodiment, and the third embodiment.
  • FIG. 12 is a flowchart illustrating a process for determining whether small areas have the same value according to the second embodiment. 12 is a flowchart illustrating a process for determining whether small areas are consecutively the same in the second embodiment.
  • FIG. 3 is a diagram for explaining a method of performing convolution processing according to a determination result for a small area.
  • FIG. 3 is a diagram for explaining a method of performing convolution processing on multiple small regions in parallel.
  • FIG. 7 is a diagram for explaining a method of skipping convolution processing for a small region of an input feature map in a modified example.
  • FIG. 7 is a diagram for explaining a method of skipping convolution processing for a small region of an input feature map in a modified example.
  • FIG. 7 is a diagram for explaining a method of skipping convolution processing for a small region of an input feature map in a modified example.
  • FIG. 7 is a diagram for explaining a method of skipping convolution processing for a small region of an input feature map in a modified example.
  • FIG. 3 is a diagram illustrating an example of convolution processing.
  • FIG. 3 is a diagram illustrating an example of convolution processing.
  • FIG. 6 is a diagram illustrating an example of convolution processing for each small region.
  • FIG. 3 is a diagram showing an example of a small area of an input feature map.
  • FIG. 3 is a diagram showing an example of a small area of an input feature map.
  • FIG. 3 is a diagram showing an example of a small area of an input feature map.
  • FIG. 3 is a diagram showing an example of a small area of an input feature map.
  • an equivalency flag indicating the determination result for each small region as to whether or not the small regions have the same value, and a determination result for each small region as to whether or not the small regions are consecutively the same.
  • a continuous flag representing , and small area data that is data of each small area of the input feature map are input to an arithmetic circuit that performs convolution processing.
  • the output feature map that is the result of the convolution process by the arithmetic circuit is written to a RAM or the like.
  • the written output feature map is used as an input feature map in the next layer and subsequent layers, and the above-described determination process and convolution process using process skip are repeated.
  • the size of the small area processed at one time is proportional to the scale of the arithmetic circuit. Furthermore, the larger the size of the small area processed at one time, the higher the throughput of inference processing. However, when attempting to increase the size of a small region in order to increase throughput, the small regions of the input feature map tend to be less likely to have the same value or to be the same continuously. For this reason, it is often not possible to expect a sufficient increase in calculation speed in terms of throughput as the scale of the calculation circuit increases.
  • the feature map is divided into three small regions, but none of the small regions have the same internal values. Moreover, none of the small areas are consecutively the same small area. Therefore, three convolution processes are required without any processing skips.
  • processing speed is increased by increasing the processing skip effect within a range that has little effect on processing accuracy.
  • the convolution process is skipped if the effect on processing accuracy is small.
  • calculation speed is increased by skipping processing even when the size of a small region is large or the bit depth is large.
  • skipping is performed when the difference between small areas of the same value or features in consecutively the same small areas is less than a threshold value. More specifically, processing skip is applied when (1) the difference between pixels in a small region is other than the threshold, and (2) the number of pixels with different features in the small region is less than or equal to the threshold. .
  • Processing is skipped when features within a small area can be considered to be small areas with the same value or consecutively the same small area if the accuracy is reduced.
  • the small area determination it is determined whether the small areas have the same value and whether the small areas are consecutively the same, allowing for a shift in the lower several bits. At this time, after masking the lower bits of the features within the small area to be processed, it is determined whether they all have the same value, and it is also determined whether the small areas are consecutively the same.
  • the setting parameters are the number of bits ⁇ 1 for masking the lower bits when determining whether the small areas have the same value, and the number ⁇ 2 of bits for masking the lower bits when determining whether the small areas are consecutively the same. establish.
  • the setting parameters are the number of bits ⁇ 1 for masking the lower bits when determining whether the small areas have the same value, and the number ⁇ 2 of bits for masking the lower bits when determining whether the small areas are consecutively the same. establish.
  • FIG. 4A shows an example in which small areas are determined to have the same value when the difference between each pixel in the small area is less than or equal to a threshold value.
  • the lower two bits are masked, so that all 24 values become 3, and it is determined that the small areas have the same value, and processing is skipped.
  • FIG. 4B shows an example in which it is determined that the small areas are consecutively the same when the difference between each pixel in the small areas is less than or equal to a threshold value.
  • ⁇ 1 2
  • the kernel size is 3 ⁇ 3
  • the output small area size is 4 ⁇ 2 (the input small area size is 6 ⁇ 4).
  • the lower 2 bits are masked, so all 24 values match between the small area to be processed and the previous small area, and the same small area is not continuously It is determined and processing skip is applied.
  • Processing is skipped when the features within a small area can be considered to be small areas with the same value or consecutively the same small area except for some pixels.
  • the small region determination it is determined whether the small regions have the same value or are continuously the same, allowing for the deviation of several features within the small region.
  • the number of pixels that do not have the same value and the number of pixels that do not match the previous small area are counted. If the count is less than or equal to the threshold, it is determined that the small areas have the same value or are the same continuously, and processing is skipped.
  • the number of pixels ⁇ 1 that are not the same value is allowed when determining whether the small area has the same value, and the number of pixels that are not the same as the previous small area that is allowed when determining whether the small area is the same continuously.
  • a pixel number ⁇ 2 is provided.
  • FIG. 5 shows an example in which small areas are determined to have the same value when the number of pixels different from the feature in the small area is less than or equal to a threshold value.
  • ⁇ 1 3
  • the kernel size is 3 ⁇ 3
  • the output small area size is 4 ⁇ 2 (the input small area size is 6 ⁇ 4).
  • FIG. 6 shows an example in which small areas are determined to be the same continuous small area when the number of pixels different from the feature in the small area is less than or equal to a threshold value.
  • ⁇ 1 3
  • the kernel size is 3 ⁇ 3
  • the output small area size is 4 ⁇ 2 (the input small area size is 6 ⁇ 4).
  • the number of bits ⁇ 1 and ⁇ 2 and the number of pixels ⁇ 1 and ⁇ 2, which correspond to the threshold values, are predetermined so that the accuracy of processing using the neural network is a predetermined accuracy.
  • the values of the numbers of bits ⁇ 1 and ⁇ 2 and the numbers of pixels ⁇ 1 and ⁇ 2 may be dynamically set during the inference process.
  • FIG. 7 is a block diagram showing the hardware configuration of the image processing device 10 of the first embodiment.
  • 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 input unit 15 receives a target image to be processed as input.
  • the learning section 20 includes an acquisition section 30, a processing section 32, and an updating section 34.
  • the input feature map is divided into small regions as shown in FIG. 1 above.
  • the area corresponding to the small area of the output feature map is displayed with a thick line frame, and the small area of the input feature map overlaps with the corresponding small area of the output feature map and the adjacent small area.
  • This area includes an overlapping area.
  • each small region obtained by dividing the input feature map is an overlapping region that overlaps with an adjacent small region, and has an overlapping region that corresponds to the kernel size of the convolution process.
  • the division of small areas is determined at the time of design. For example, it may be determined based on the balance between hardware constraints (size and power) and desired throughput (xxfps, etc.).
  • the kernel size is 3 ⁇ 3
  • the small area of the input feature map is 10 ⁇ 6, and the small area of the output feature map is 8 ⁇ 4, a throughput that can output 32 points simultaneously can be obtained.
  • the small area of the input feature map is 6 ⁇ 4 and the small area of the output feature map is 4 ⁇ 2, the throughput is to output only 8 points at the same time.
  • the division of the small area is determined at the time of design, so the division of the small area does not change depending on the layer.
  • the processing unit 32 determines, for each small region, whether the features constituting the small region correspond to the features of the immediately previously processed small region. If it is determined that the features constituting the small region correspond to the features of the small region processed immediately before, the arithmetic circuit 18 does not perform convolution processing on the small region and The processed results are output as the results of processing the small area.
  • the processing unit 32 determines that the features constituting the small region are the features that were processed immediately before. It is determined that the feature corresponds to the feature of the small region. For example, bits other than the lower predetermined number ⁇ 2 of bits representing the feature in the small region that was processed immediately before are the same as the bits other than the lower predetermined number ⁇ 2 representing the feature in the small region. In this case, it is determined that the features constituting the small region correspond to the features of the small region processed immediately before.
  • the processing unit 32 determines that the feature constituting the small region is different from the feature in the immediately previously processed small region. It is determined that it corresponds to the feature of the area. For example, if the number of pixels with different features is counted compared to the small area that was processed immediately before, and the counted number of pixels is less than the threshold ⁇ 2, then the features that make up the small area are the same as those that were processed immediately before. It is determined that the feature corresponds to the feature of the small region.
  • the updating unit 34 updates the parameters of the neural network so that the result of processing the target image using the neural network matches the processing result obtained in advance.
  • the updating unit 34 also updates the pre-calculation result table of each convolutional layer based on the updated neural network parameters.
  • the processing unit 42 determines, for each small area, whether all the features that make up the small area correspond to small areas with the same value. If it is determined that all the features constituting the small area correspond to small areas with the same value, the arithmetic circuit 18 does not perform convolution processing on the small area, and instead uses the small area stored in the pre-calculation result table. The processing result for the case where all the constituent features have the same value is output as the result of processing the small region.
  • the processing unit 42 determines whether the features forming the small area correspond to the features of the immediately previously processed small area. If it is determined that the features constituting the small region correspond to the features of the small region processed immediately before, the arithmetic circuit 18 does not perform convolution processing on the small region and The processed results are output as the results of processing the small area.
  • the display unit 16 displays the results of processing the target image using the neural network.
  • 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 32 and the updating section 34 are repeatedly performed. This trains the neural network.
  • step S110 the CPU 11, as the processing unit 32, divides the input feature map that is input to the convolutional layer into small regions.
  • step S112 the CPU 11, as the processing unit 32, reads the pre-computation result table of the convolution layer from the RAM 13.
  • the CPU 11 determines that the features constituting the small area to be processed correspond to the small area with the same value, if the difference between the feature and the feature in the small area with the same value is less than or equal to a threshold value.
  • the CPU 11 determines that the feature constituting the small region to be processed corresponds to the small region of the same value.
  • the CPU 11 determines that the features constituting the small region to be processed correspond to the features in the small region processed immediately before. do.
  • the CPU 11 determines that the feature constituting the small area to be processed corresponds to the feature of the small area processed immediately before. Then it is determined.
  • step S116 the CPU 11, as the processing unit 32, outputs each small area data of the input feature map, the pre-calculation result table, and the equivalency flag and continuity flag indicating the determination result in step S114 to the calculation circuit 18. Then, the arithmetic circuit 18 performs convolution processing for each small region. At this time, if the small area to be processed does not correspond to a small area with the same value and does not correspond to the same small area consecutively, the arithmetic circuit 18 performs convolution processing on the small area to be processed. conduct.
  • the arithmetic circuit 18 does not perform convolution processing on the small area to be processed, and instead uses the characteristics constituting the small area stored in the pre-calculation result table.
  • the result processed for the case of the same value is output as the result of processing the small region to be processed.
  • the arithmetic circuit 18 does not perform the convolution process to the small area to be processed, but to the small area processed immediately before.
  • the processed result is output as the result of processing the small region to be processed.
  • step S114 the divided small regions are sequentially processed, and it is determined whether the features constituting the small region to be processed correspond to a small region of the same value or to the features of a small region processed immediately before. judge.
  • the process of determining that a small area corresponds to a small area of the same value when the difference between each pixel of the small area is less than or equal to a threshold value is realized by the processing routine shown in FIG.
  • step S132 the CPU 11, as the processing unit 32, determines whether the features constituting the small area to be processed have the same value based on whether all the features in the small area to be processed after the masking process in step S130 have the same value. It is determined whether or not it corresponds to the small area of .
  • step S140 the CPU 11, as the processing unit 32, performs a masking process to mask a predetermined number ⁇ 2 of lower bits of the feature within the small area to be processed.
  • the process of determining that the small area corresponds to a small area with the same value is realized by the processing routine shown in FIG.
  • step S150 the CPU 11, as the processing unit 32, compares the small region to be processed with small regions of the same value and counts the number of pixels having different characteristics.
  • step S160 the CPU 11, as the processing unit 32, compares the small area to be processed with the small area processed immediately before and counts the number of pixels having different characteristics.
  • step S162 the CPU 11, as the processing unit 32, determines whether the feature constituting the small region to be processed has been processed immediately before, based on whether the number of pixels counted in step S160 is less than or equal to the threshold value ⁇ 2. Determine whether it corresponds to a small area.
  • step S120 the CPU 11, as the acquisition unit 40, acquires the input target image.
  • step S122 the CPU 11, as the processing unit 42, processes the target image using the neural network learned by the learning process described above. Then, the display unit 16 displays the results of processing the target image using the neural network.
  • CNN calculation accuracy it is also possible to feed back changes in CNN calculation accuracy and adaptively change parameter values within a range that has little effect on CNN calculation accuracy. For example, if a threshold value for CNN calculation accuracy is set and the value falls below that threshold during inference processing, the CNN calculation accuracy can be adaptively improved by decreasing ⁇ 1, ⁇ 2, ⁇ 1, and ⁇ 2 by one step. is possible.
  • ⁇ Summary of second embodiment both (1) the case where the difference between pixels in the small region is other than the threshold value, and (2) the case where the number of pixels of pixels with different features in the small region is less than or equal to the threshold value are considered simultaneously. . Specifically, setting parameters ⁇ 1, ⁇ 2, ⁇ 1, and ⁇ 2 are respectively set, and the masking of the lower bits and the counting of the number of pixels having different characteristics within the small area are performed simultaneously.
  • the processing unit 32 determines, for each small region, whether all the features constituting the small region correspond to small regions of the same value. If it is determined that all the features constituting the small region correspond to small regions of the same value, the arithmetic circuit 18 does not perform convolution processing on the small region, and instead uses the small region stored in the pre-calculation result table. The processing result for the case where all the constituent features have the same value is output as the result of processing the small region.
  • the processing unit 32 For each small region, if the difference from the feature in the small region processed immediately before is less than or equal to a threshold value, the processing unit 32 considers the feature to be the same, and If the number of pixels different from the feature in the small region is less than or equal to the threshold value, it is determined that the feature constituting the small region corresponds to the feature of the previously processed small region.
  • the bits other than the lower predetermined number of bits ⁇ 2 representing the feature in the small region to be processed are the same, it is considered to be the same feature, and compared with the small region processed immediately before, The number of pixels with different features is counted, and if the counted number of pixels is less than or equal to the threshold value ⁇ 2, it is determined that all the features constituting the small area correspond to the features of the small area processed immediately before.
  • mask processing is performed to determine whether the small areas are the same continuously (S230).
  • the third embodiment differs from the first embodiment in that the arithmetic circuit performs convolution processing on a plurality of small regions in parallel.
  • the processing unit 32 of the learning unit 20 processes the target image using a neural network including convolution processing.
  • the processing unit 32 performs the convolution process for each small region obtained by dividing the input feature map that is input to the convolution process.
  • Convolution processing for each small area is executed using the arithmetic circuit 18.
  • the processing unit 32 determines for each small area whether or not the small areas have the same value and whether or not the small areas are the same continuously.
  • the small region data of the input feature map, the kernel, the determination result for each small region, and the pre-calculation result table are input to the arithmetic circuit 18, and the arithmetic circuit 18 outputs an output feature map.
  • the processing unit 32 determines, for each small region, whether the features constituting the small region correspond to the features of the immediately previously processed small region. If it is determined that the features constituting the small region correspond to the features of the small region processed immediately before, the arithmetic circuit 18 does not perform convolution processing on the small region and The processed results are output as the results of processing the small area.
  • the arithmetic circuit 18 operates in parallel for a predetermined number of small regions in which all the features constituting the small region do not correspond to the same small region and do not correspond to the features of the small region processed immediately before. Perform convolution processing.
  • the processing unit 42 of the inference unit 22 processes the target image using a neural network including convolution processing.
  • the processing unit 42 performs the convolution process for each small region obtained by dividing the input feature map that is input to the convolution process. Convolution processing for each small area is executed using the arithmetic circuit 18.
  • the processing unit 42 determines, for each small area, whether or not it corresponds to a small area with the same value, and whether or not it corresponds to the same small area continuously.
  • the small region data of the input feature map, the kernel, the determination result for each small region, and the pre-calculation result table are input to the arithmetic circuit 18, and the arithmetic circuit 18 outputs an output feature map.
  • the processing unit 42 determines, for each small region, whether all the features constituting the small region correspond to small regions with the same value. Determine. If it is determined that all the features constituting the small area correspond to small areas with the same value, the arithmetic circuit 18 does not perform convolution processing on the small area, and instead uses the small area stored in the pre-calculation result table. The processing result for the case where all the constituent features have the same value is output as the result of processing the small region.
  • the processing unit 42 determines for each small area whether the features that make up the small area correspond to the features of the immediately previously processed small area. If it is determined that the features constituting the small region correspond to the features of the small region processed immediately before, the arithmetic circuit 18 does not perform convolution processing on the small region and The processed results are output as the results of processing the small area.
  • the arithmetic circuit 18 operates in parallel for a predetermined number of small regions in which all the features constituting the small region do not correspond to the same small region and do not correspond to the features of the small region processed immediately before. Perform convolution processing.
  • the output feature map that is the result of the convolution process performed for each small region as described above becomes the input to the next layer of the neural network.
  • the CPU 11 of the image processing device 210 reads the learning processing program from the ROM 12 or the storage 14, expands it to the RAM 13, and executes it, processing similar to the learning processing shown in FIG. 11 above is performed. Furthermore, learning data is input to the image processing device 10.
  • the above step S102 performs calculation processing for each layer of the neural network.
  • the arithmetic processing of the convolutional layer is realized by the processing routine shown in FIG. 12 above.
  • step S116 if the features constituting the small area to be processed correspond to small areas with the same value, the arithmetic circuit 18 does not perform convolution processing on the small area to be processed, and the features constituting the small area to be processed are stored in the pre-calculation result table. , the processing results for the case where the features constituting the small area have the same value are output as the results of processing the small area that is the processing target.
  • the arithmetic circuit 18 does not perform convolution processing on the small region to be processed, and The result of processing the small area that has been processed is output as the result of processing the small area that is the processing target.
  • the arithmetic circuit 18 performs convolution in parallel on a predetermined number of small regions in which the features constituting the small region do not correspond to small regions of the same value and do not correspond to the features of the small region processed immediately before. Perform processing.
  • the CPU 11 of the image processing device 210 reads the image processing program from the ROM 12 or the storage 14, expands it to the RAM 13, and executes it, thereby performing the same processing as the image processing shown in FIG. 17 above. Further, a target image is input to the image processing device 210.
  • the above step S122 performs calculation processing for each layer of the neural network.
  • the arithmetic processing of the convolutional layer is realized by the processing routine shown in FIG. 12 above.
  • the image processing device has the arithmetic circuit configured to perform convolution processing on a plurality of small regions in parallel, and performs convolution processing for each small region of the input feature map.
  • convolution processing if the features constituting a small region correspond to a small region with the same value or the features of a small region processed immediately before, convolution processing is not performed on the small region, and a predetermined The result of processing the small area of the same value or the result of the previous process is output as the result of processing the small area.
  • processing results are calculated in advance for each of all values (for example, 16 values when a feature is represented by 4-bit data) for a small area of the same value and stored in memory.
  • all values for example, 16 values when a feature is represented by 4-bit data
  • the invention is not limited to this.
  • the values of features that are likely to appear as small regions with the same value are determined in advance through simulations, etc., and the processing results for small regions with the same value are determined in advance only for the values of the top few features with a high probability of appearance. It may be determined in advance and stored in a pre-calculation result table (see FIG. 22). If the small areas have the same value and the processing result has been obtained in advance, the processing result obtained in advance is output without performing convolution processing.
  • FIG. 22 pre-calculation result table
  • the processing results are shown only for each of the same small regions whose feature value is 1, the same small region whose feature value is 4, and the same small region whose feature value is 15. An example is shown in which it is determined in advance. Furthermore, since the processing result is 0 for the same small region whose feature value is 0, it is not stored in the pre-calculation result table. This makes it possible to reduce the size of a pre-computation result table that stores pre-obtained processing results, leading to a reduction in the amount of hardware memory.
  • the processing results may be calculated in advance for each of all values (for example, 16 values if the feature is represented by 4-bit data) and stored in memory.
  • all values for example, 16 values if the feature is represented by 4-bit data
  • the invention is not limited to this.
  • FIG. 23 shows an example in which a small region of the same value with a feature value of 4 appears for the first time in small region 2, a convolution process is performed, and the processing result is stored in the calculation result table.
  • the processing result is read from the calculation result table without performing convolution processing.
  • the calculation result table is reset every time each layer is processed. This eliminates the need for pre-calculation processing. Further, since there is no need to transfer the pre-calculation results of each layer from the RAM etc. to the internal memory of the arithmetic circuit for each layer, it is possible to reduce the amount of data transferred to and from the RAM etc.
  • the image processing device has been described as an example including a learning section and an inference section, 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.
  • 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.
  • a device equipped with an inference section may be mounted on a drone, or used as an IoT or edge device.
  • a single device is generally configured to include a learning section and an inference section when high-speed learning is performed using hardware located in a data center, such as in cloud computing.
  • 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 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 Integrated Circuit), which is used to execute specific processing.
  • 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 is stored on non-transitory storage media such as CD-ROM (Compact Disk Read Only Memory), DVD-ROM (Digital Versatile Disk Read Only Memory), and USB (Universal Serial Bus) 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 images, memory and at least one processor connected to the memory; including;
  • the processor includes: Obtain the target image to be processed, An image processing program for processing the target image using a neural network including the convolution process, When performing the convolution process, the convolution process is performed for each small region obtained by dividing the input feature map that is input to the convolution process, When performing the convolution process for each small area, if the features constituting the small area correspond to predetermined features or features of previously processed small areas, the convolution process for the small area outputting a result of processing the predetermined feature or a result of processing in the past as a result of processing the small area;
  • the small area corresponding to the predetermined feature is a small area in which a difference from the predetermined feature is less than or equal to a threshold value,
  • the small area corresponding to the feature of the previously processed small area is the small area in which a difference from the feature of the previously processed small area is equal to or less than a threshold value.
  • the image processing includes: Obtain the target image to be processed, An image processing program for processing the target image using a neural network including the convolution process,
  • the convolution process is performed for each small region obtained by dividing the input feature map that is input to the convolution process,
  • the convolution process for each small area if the features constituting the small area correspond to predetermined features or features of previously processed small areas, the convolution process for the small area outputting a result of processing the predetermined feature or a result of processing in the past as a result of processing the small area;
  • the small area corresponding to the predetermined feature is a small area in which a difference from the predetermined feature is less than or equal to a threshold value,
  • the small area corresponding to the characteristics of the previously processed small area is a small area in which a difference from the characteristics of the previously processed small area is equal to or

Landscapes

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

Abstract

畳み込み処理を行う際に、畳み込み処理の入力となる入力特徴マップを小領域に分割し、小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、小領域に対する畳み込み処理を行わず、予め定められた特徴に対して処理された結果、又は過去に処理された結果を、小領域を処理した結果として出力する。

Description

画像処理装置、画像処理方法、及び画像処理プログラム
 本開示の技術は、画像処理装置、画像処理方法、及び画像処理プログラムに関する。
 CNN(Convolutional Neural Network)を用いた推論を行う場合、ネットワークは複数の層で構成され、畳み込み層(Convolutional layer)では畳み込み処理を行う。畳み込み処理は積和演算や活性化処理を行う。
 CNNを用いた推論においては、上記の畳み込み演算が全体処理量の大部分を占める。
 ハードウェアとしてCNNを用いた推論エンジンを実装する場合においても、畳み込み演算の性能がエンジン全体の性能に直結する。
 カーネルサイズが3×3である場合における畳み込み演算の例を図25、図26に示す。図25では、3×3のカーネルを用いて、3×3の入力特徴マップに対して畳み込み演算を行う例を示している。この例では、9回の積和演算を行い、1×1の出力特徴マップを出力する。
 また、図26では、3×3のカーネルを用いて、(W+2)×(H+2)の入力特徴マップに対して畳み込み演算を行う例を示している。この例では、カーネルを入力特徴マップ上で動かしながら9回の積和演算を繰り返し行い、W×Hの出力特徴マップを出力する。
 CNNの畳み込み演算を行うハードウェアでは、スループットを高めるため、入力特徴マップをある固定サイズの小領域に分割し、1つの小領域への積和演算を一度に行えるように回路を用意することが多い(図27参照)。図27では、26×14の入力特徴マップを、9個の10×6の小領域に分割し、演算回路が、3×3のカーネルを用いて32点(8×4点)同時に畳み込み処理を行い、8×4の出力特徴マップを出力する例を示している。この例では、入力特徴マップのドット部分が、1つの小領域であり、演算回路が、9個の小領域の各々に対して、32点同時の畳み込み処理を行うことにより、24×12の出力特徴マップを出力する。
 また、演算高速化手法の1つとして、図28に示すように、入力特徴マップの小領域の値が全てゼロの場合に演算をスキップする手法が知られている(例えば、非特許文献1)。図28では、出力される小領域のサイズが4×2であり、カーネルサイズが3×3であり、0~15を表す4ビットデータを用いる場合の例を示している。この例では、入力特徴マップの小領域のサイズが6×4であり、点線で表される小領域の値が全て0となっている。0に対する積和演算の結果は0になるため、演算回路で畳み込み処理を行う必要はなく、当該小領域の畳み込み処理をスキップすることが可能となる。
Angshuman Parashar, Minsoo Rhu, Anurag Mukkara, Antonio Puglielli, Rangharajan Venkatesan, Brucek Khailany, Joel Emer, Stephen W. Keckler, William J. Dally, "SCNN: An Accelerator for Compressed-sparse Convolutional Neural Networks", arXiv:1708.04485, 23 May 2017
 ここで、スループットを高めるために、小領域のサイズを大きくしようとすると、入力特徴マップの小領域の値が全てゼロとなることが少なくなり、十分な演算高速化が期待できない。例えば、図29Aに示すように、出力特徴マップの小領域のサイズが4×2である場合(入力特徴マップの小領域のサイズが6×4である場合)には、入力特徴マップの点線で表される小領域の値が全てゼロとなる。一方、図29Bに示すように、出力特徴マップの小領域のサイズが8×4である場合(入力特徴マップの小領域のサイズが10×6である場合)には、入力特徴マップの点線で表される小領域にゼロでない値が含まれる。
 また、小領域のサイズは演算スループットに直結するため、変更が難しい場合が多い。
 開示の技術は、上記の点に鑑みてなされたものであり、畳み込み処理を含むニューラルネットワークを用いた処理を高速化することができる画像処理装置、画像処理方法、及び画像処理プログラムを提供することを目的とする。
 本開示の第1態様は、画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、処理対象である対象画像を取得する取得部と、前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理する処理部とを含み、前記処理部は、前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である。
 本開示の第2態様は、画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置における画像処理方法であって、取得部が、処理対象である対象画像を取得し、処理部が、前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理することを含み、前記処理部が前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である。
 本開示の第3態様は、画像を対象とする畳み込み処理を含むニューラルネットワークを含むコンピュータに、処理対象である対象画像を取得し、前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理することを実行させるための画像処理プログラムであって、前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である。
 開示の技術によれば、畳み込み処理を含むニューラルネットワークを用いた処理を高速化することができる。
入力特徴マップの小領域を説明するための図である。 入力特徴マップの小領域に対する畳み込み処理をスキップする方法を説明するための図である。 入力特徴マップの小領域を説明するための図である。 同値の小領域と判定する方法を説明するための図である。 連続して同一の小領域と判定する方法を説明するための図である。 同値の小領域と判定する方法を説明するための図である。 連続して同一の小領域と判定する方法を説明するための図である。 第1実施形態、第2実施形態、及び第3実施形態の画像処理装置として機能するコンピュータの一例の概略ブロック図である。 第1実施形態、第2実施形態、及び第3実施形態の画像処理装置の機能構成を表すブロック図である。 第1実施形態、第2実施形態、及び第3実施形態の画像処理装置の学習部の機能構成を表すブロック図である。 第1実施形態、第2実施形態、及び第3実施形態の画像処理装置の推論部の機能構成を表すブロック図である。 第1実施形態、第2実施形態、及び第3実施形態の学習処理の流れを表すフローチャートである。 第1実施形態、第2実施形態、及び第3実施形態の学習処理及び画像処理における畳み込み処理の流れを表すフローチャートである。 第1実施形態の同値の小領域であるかの判定処理の流れを表すフローチャートである。 第1実施形態の連続して同一の小領域であるかの判定処理の流れを表すフローチャートである。 第1実施形態の同値の小領域であるかの判定処理の流れを表すフローチャートである。 第1実施形態の連続して同一の小領域であるかの判定処理の流れを表すフローチャートである。 第1実施形態、第2実施形態、及び第3実施形態の画像処理の流れを表すフローチャートである。 第2実施形態の同値の小領域であるかの判定処理の流れを表すフローチャートである。 第2実施形態の連続して同一の小領域であるかの判定処理の流れを表すフローチャートである。 小領域に対する判定結果に応じて畳み込み処理を行う方法を説明するための図である。 複数の小領域に対して並列に畳み込み処理を行う方法を説明するための図である。 変形例における入力特徴マップの小領域に対する畳み込み処理をスキップする方法を説明するための図である。 変形例における入力特徴マップの小領域に対する畳み込み処理をスキップする方法を説明するための図である。 変形例における入力特徴マップの小領域に対する畳み込み処理をスキップする方法を説明するための図である。 畳み込み処理の一例を示す図である。 畳み込み処理の一例を示す図である。 小領域ごとの畳み込み処理の一例を示す図である。 入力特徴マップの小領域の一例を示す図である。 入力特徴マップの小領域の一例を示す図である。 入力特徴マップの小領域の一例を示す図である。
 以下、開示の技術の実施形態の一例を、図面を参照しつつ説明する。なお、各図面において同一又は等価な構成要素及び部分には同一の参照符号を付与している。また、図面の寸法比率は、説明の都合上誇張されており、実際の比率とは異なる場合がある。
<開示の技術の実施形態の概要>
 開示の技術では、畳み込み層の入力特徴マップのデータをRAM(Random Access Memory)等から読み込んだ後に、小領域ごとに、小領域内の全ての特徴が同値である小領域であるか、連続して同一の小領域であるかをそれぞれ判定する。以下、入力特徴マップの小領域の内部が全て同一の特徴となるものを「同値の小領域」と称する。また、小領域内の特徴が、一つ前の小領域と全く同一となるものを「連続して同一の小領域」と称する。図1では、「同値の小領域」の一例として、点線で囲まれている小領域内の全ての特徴が4である例を示している。また、「連続して同一の小領域」の一例として、細い破線で囲まれている小領域内の特徴と、太い破線で囲まれている小領域内の特徴とが、同一である例を示している。ここで、同値である小領域であるかを判定するのは、入力画像でも同値となっているときが多いためである。また、連続して同一の小領域であるかを判定するのは、入力画像でも同じような領域が続くときが多いためである。例えば、入力画像の10×6領域の上1行目の10点の値が10で下3行目の50点の値が12である場合である。同値である領域、連続して同一の小領域のどちらの場合も、入力画像が複雑な絵の領域ではなく平坦で均一気味な領域の場合があてはまる。
 また、図2に示すように、同値の小領域であるか否かの小領域ごとの判定結果を表す同値フラグと、連続して同一の小領域であるか否かの小領域ごとの判定結果を表す連続フラグと、入力特徴マップの各小領域のデータである小領域データとを、畳み込み処理を行う演算回路に入力する。
 演算回路において、処理対象となる小領域が、同値の小領域であるか、又は連続して同一の小領域である場合には、畳み込み処理を行わない処理スキップを行う。連続して同一の小領域である場合、直前に処理対象となった小領域と同じ処理結果となるため、直前に処理対象となった小領域の処理結果を連続して出力するだけでよく、処理が高速化される。図2では、小領域3内の特徴と小領域4内の特徴とが同一であるため、小領域4に対して処理スキップを行う例を示している。
 また、同値の小領域については、処理結果が限定される。特徴を示す値が4ビットである場合には、処理結果は16パターンであり、特徴を示す値が8ビットである場合には、処理結果は256パターンとなる。全パターンの処理結果を事前計算して事前計算結果テーブルをRAMに格納しておき、各層の処理ごとに、RAMから演算回路の内部メモリに事前計算結果テーブルを読み込んでおく。これにより、同値の小領域に対しては畳み込み処理を行わずに、内部メモリ参照のみで処理結果が得られるため、処理が高速化される。図2では、小領域2が同値の小領域であるため、小領域2に対して処理スキップを行い、事前計算結果テーブルに格納された、全ての特徴が4である場合の処理結果を参照して出力する例を示している。
 また、図2に示すように、演算回路による畳み込み処理の結果である出力特徴マップをRAM等に書き出す。書き出した出力特徴マップは次層以降で入力特徴マップとして使用され、再度、上述した判定処理と、処理スキップを用いた畳み込み処理を行うことが繰り返される。
 ここで、一度に処理する小領域のサイズは、演算回路の規模と比例する。また、一度に処理する小領域のサイズを大きくするほど、推論処理のスループットは向上する。しかしながら、スループットを高めるために、小領域のサイズを大きくしようとすると、入力特徴マップの小領域が、同値の小領域、又は連続して同一の小領域となることが少なくなる傾向にある。このため、演算回路の規模の増加に対して、スループットとしては十分な演算高速化が期待できないことが多い。
 例えば、図3に示すように、出力特徴マップの小領域のサイズを4×2ではなく4×4にした場合(入力特徴マップの小領域のサイズが6×4ではなく6×6である場合)、特徴マップは3個の小領域に分割されるが、いずれの小領域も内部が全て同値になることはない。また、いずれの小領域も連続して同一の小領域となることもない。このため、処理スキップは発生せずに3回分の畳み込み処理が必要となる。
 出力特徴マップの小領域のサイズが4×2だった場合は、6つの小領域のうち1つが同値の小領域で、1つが連続して同一の小領域であったため(上記図2を参照)、2回の処理スキップが発生して4回分の畳み込み処理だけでよい。
 出力特徴マップの小領域のサイズを4×2から4×4にするにはハードウェアとして演算回路の規模を2倍にする必要があるが、一方で処理スキップが発生しなくなることで実際のスループットは4/3倍しか増えていないこととなる。演算回路あたりのスループットは、(4/3)/2=2/3倍と、下がっている。このように、スキップ率は小領域のサイズの向上に伴って下がる傾向にあり、そのために処理スキップによる演算回路の高速化の効果が低くなることがある。
 そこで、本実施形態では、ニューラルネットワークを用いた畳み込み処理において、処理精度への影響が少ない範囲で処理スキップ効果を高めて演算高速化を行う。
 具体的には、小領域の内部が全て同値でない小領域、または小領域の内部が全て連続して同一でない小領域であっても、処理精度への影響が少ない場合には畳み込み処理のスキップを適用することで、小領域のサイズが大きい場合やビット深度が大きい場合でも処理スキップによる演算高速化を行う。
 処理精度への影響が少ない場合として、同値の小領域又は連続して同一の小領域内の特徴との違いが、閾値以下である場合にスキップする。より具体的には、(1)小領域の画素毎の違いが閾値以外である場合、(2)小領域内の特徴が異なる画素の画素数が閾値以下である場合、に処理スキップを適用する。
 「(1)小領域の画素毎の違いが閾値以下である場合」について以下に詳細を説明する。
 小領域内の特徴について、精度を落とせば同値の小領域または連続して同一の小領域とみなせる場合に、処理スキップを行う。
 小領域判定にて、下位の数ビットがずれていることを許容した上で同値の小領域であるか、及び連続して同一の小領域であるかを判定する。このとき、処理対象の小領域内の特徴について下位ビットをマスクしてから、全て同値かどうか判定し、また、連続して同一の小領域であるかを判定する。
 このとき、設定パラメータとして、同値の小領域であるかの判定時に下位ビットをマスクするビット数α1と、連続して同一の小領域であるかの判定時に下位ビットをマスクするビット数α2とを設ける。
 このとき、設定パラメータとして、同値の小領域であるかの判定時に下位ビットをマスクするビット数α1と、連続して同一の小領域であるかの判定時に下位ビットをマスクするビット数α2とを設ける。
 例えば、図4Aに示すように、α=2とし、下位2ビットを無視するために、2進数「1101」(すなわち、10進数「13」)における下位2ビット「01」がマスクされて、2進数「11」(すなわち、10進数「3」)とみなされる。これは、「>>α」と、αビットだけ右シフトすることと等しい。また、2αで割ったときの商の値とすることと等しい(13%(2)=13%4=3)。
 図4Aに、小領域の画素毎の違いが閾値以下である場合に、同値の小領域であると判定する例を示す。この例では、α1=2、カーネルサイズ3×3、出力される小領域サイズ4×2(入力6×4)である。α1=0、すなわち小領域の内部の値でそのまま判定処理を行う場合は、6×4=24つの値が全て同値ではないため、同値の小領域と判定なされない。一方で、α1=2の場合、下位2ビットがマスクされることで、24つの値が全て3となり、同値の小領域であると判定され処理スキップが行われる。
 図4Bに、小領域の画素毎の違いが閾値以下である場合に、連続して同一の小領域であると判定する例を示す。この例では、α1=2、カーネルサイズ3×3、出力される小領域サイズ4×2(入力される小領域サイズ6×4)である。α2=0、すなわち小領域の内部の値でそのまま判定処理を行う場合は、6×4=24つの値が、処理対象の小領域と直前の小領域とで全く一致してはおらず、連続して同一の小領域と判定されない。一方で、α2=2の場合、下位2ビットがマスクされることで、24つの値が、処理対象の小領域と直前の小領域とで全て一致することとなり、連続して同一の小領域と判定され処理スキップが適用される。
 「(2)小領域内の特徴と異なる画素の画素数が閾値以下である場合」について以下に詳細を説明する。
 小領域内の特徴について、一部の画素を除けば同値の小領域または連続して同一の小領域とみなせる場合に、処理スキップを行う。
 小領域判定にて、小領域内で数個の特徴がずれていることを許容した上で同値の小領域または連続して同一の小領域であるかの判定を行う。
 このとき、小領域内の特徴について、同値でなかった画素数、直前の小領域と一致しなかった画素数をそれぞれカウントする。カウント数が閾値以下である場合、同値の小領域又は連続して同一の小領域と判定し、処理スキップを行う。
 また、設定パラメータとして、同値の小領域であるかの判定時に許容される同値でない画素数β1と、連続して同一の小領域であるかの判定時に許容される、直前の小領域と同一でない画素数β2を設ける。
 図5に、小領域内の特徴と異なる画素の画素数が閾値以下である場合に、同値の小領域であると判定する例を示す。この例では、β1=3、カーネルサイズ3×3、出力される小領域サイズ4×2(入力される小領域サイズ6×4)である。
 β1=0、すなわち同値でないものが1つでも存在することを許容しない場合は、6×4=24つの値が全て同値ではないため、同値の小領域と判定されない。一方で、β1=3の場合、同値でない画素数が3個まで許容される。図5において同値でないものは「17」、「16」の計2つであるため、2<=β1であり、同値の小領域と判定されて処理スキップが行われる。
 図6に、小領域内の特徴と異なる画素の画素数が閾値以下である場合に、連続して同一の小領域であると判定する例を示す。この例では、β1=3、カーネルサイズ3×3、出力される小領域サイズ4×2(入力される小領域サイズ6×4)である。
 β2=0、すなわち処理対象の小領域と直前の小領域とで一致しないものが1つでも存在することを許容しない場合は、6×4=24つの値が全て一致してはいないため、連続して同一の小領域と判定されない。
 一方で、β2=3の場合、一致しない画素数が3個まで許容される。図6において処理対象の小領域と直前の小領域とで一致しないものは{「25」と「28」}、{「8」と「12」}の計2つであるため、β2よりも少なく、連続して同一の小領域と判定され処理スキップが行われる。
 また、閾値に相当するビット数α1、α2、画素数β1、β2は、ニューラルネットワークを用いた処理の精度が所定の精度となるように予め定められたものである。なお、ビット数α1、α2、画素数β1、β2の値を推論処理中に動的に設定してもよい。
[第1実施形態]
<第1実施形態に係る画像処理装置の構成>
 図7は、第1実施形態の画像処理装置10のハードウェア構成を示すブロック図である。
 図7に示すように、画像処理装置10は、CPU(Central Processing Unit)11、ROM(Read Only Memory)12、RAM13、ストレージ14、入力部15、表示部16、通信インタフェース(I/F)17、及び演算回路18を有する。各構成は、バス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(登録商標)等の規格が用いられる。
 演算回路18は、ニューラルネットワークの畳み込み層における畳み込み処理を実行する。具体的には、演算回路18は、入力特徴マップの小領域と、カーネルとを受け付け、当該小領域内の各点の畳み込み処理の結果である、出力特徴マップの小領域を出力する。
 次に、画像処理装置10の機能構成について説明する。図8は、画像処理装置10の機能構成の例を示すブロック図である。
 画像処理装置10は、機能的には、図8に示すように、学習部20及び推論部22を備えている。
 学習部20は、図9に示すように、取得部30、処理部32、及び更新部34を備えている。
 取得部30は、入力された学習用データの対象画像及び処理結果を取得する。
 処理部32は、畳み込み処理を含むニューラルネットワークを用いて対象画像を処理する。処理部32は、畳み込み処理を行う際に、畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに畳み込み処理を行う。小領域ごとの畳み込み処理は、演算回路18を用いて実行される。このとき、入力特徴マップの小領域データとカーネルとが演算回路18に入力され、演算回路18から、小領域ごとの畳み込み処理の結果を表す出力特徴マップが出力される。
 ここで、入力特徴マップは、上記図1に示すように小領域に分割される。上記図1では、出力特徴マップの小領域に対応する領域を太線の枠で表示しており、入力特徴マップの小領域は、対応する出力特徴マップの小領域と、隣り合う小領域と重複した重複領域とを含む領域である。このように、入力特徴マップを分割した小領域は、隣り合う小領域と重複した重複領域であって、かつ、畳み込み処理のカーネルサイズに応じた重複領域を有する。なお、小領域の分割について、設計時に決めておく。例えば、ハードウェアの制約(サイズや電力)と所望のスループット(xxfpsなど)のバランスで決めればよい。カーネルサイズを3×3とし、入力特徴マップの小領域を10×6とし、出力特徴マップの小領域を8×4とすれば、同時に32点出力できるスループットが得られる。このとき、積和演算回路は、288個(=(3×3)×8×4)必要となる。また、入力特徴マップの小領域を6×4とし、出力特徴マップの小領域を4×2とすれば、同時に8点のみ出力するスループットになる。このとき、積和演算回路は72個(=(3×3)×4×2)必要となる。また、積和演算をハードウェアで実現する場合には、小領域の分割は設計時に決めるため、層によって小領域の分割は変化しない。
 演算回路18は、小領域ごとに畳み込み処理を行う際に、当該小領域を構成する全ての特徴が、同値の小領域と対応する場合、当該小領域に対する畳み込み処理を行わず、予め定められた、小領域を構成する全ての特徴が当該同値である場合に対して処理された結果を、当該小領域を処理した結果として出力する。
 具体的には、処理部32が、小領域ごとに、当該小領域を構成する全ての特徴が、同値の小領域と対応するか否かを判定する。当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する全ての特徴が当該同値である場合に対して処理された結果を、当該小領域を処理した結果として出力する。
 より具体的には、処理部32が、小領域ごとに、同値の小領域内の特徴との違いが、閾値以下である場合、当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定する。例えば、処理対象の小領域内の特徴を表す下位の所定ビット数α1のビット以外のビットが同一である場合、当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定する。
 また、処理部32が、小領域ごとに、同値の小領域内の特徴と異なる画素の画素数が閾値以下である場合、当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定する。例えば、同値の小領域と比較して、特徴が異なる画素の画素数をカウントし、カウントした画素数が閾値β1以下である場合、当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定する。
 また、演算回路18は、小領域ごとに畳み込み処理を行う際に、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応する場合、当該小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、当該小領域を処理した結果として出力する。
 具体的には、処理部32が、小領域ごとに、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応するか否かを判定する。当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、当該小領域を処理した結果として出力する。
 より具体的には、処理部32が、小領域ごとに、直前に処理された小領域内の特徴との違いが、閾値以下である場合、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。例えば、直前に処理された小領域内の特徴を表す下位の所定ビット数α2のビット以外のビットが、当該小領域内の特徴を表す下位の所定ビット数α2のビット以外のビットと同一である場合、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。
 また、処理部32が、小領域ごとに、直前に処理された小領域内の特徴と異なる画素の画素数が閾値以下である場合、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。例えば、直前に処理された小領域と比較して、特徴が異なる画素の画素数をカウントし、カウントした画素数が閾値β2以下である場合、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。
 更新部34は、対象画像に対してニューラルネットワークを用いて処理した結果と、予め求められた処理結果とが一致するように、ニューラルネットワークのパラメータを更新する。また、更新部34は、更新されたニューラルネットワークのパラメータに基づいて、各畳み込み層の事前計算結果テーブルを更新する。
 予め定められた反復終了条件を満たすまで、処理部32及び更新部34の各処理が繰り返し行われる。これにより、ニューラルネットワークが学習される。
 推論部22は、図10に示すように、取得部40及び処理部42を備えている。
 取得部40は、入力された処理対象である対象画像を取得する。
 処理部42は、畳み込み処理を含むニューラルネットワークを用いて対象画像を処理する。処理部42は、畳み込み処理を行う際に、畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに畳み込み処理を行う。小領域ごとの畳み込み処理は、演算回路18を用いて実行される。このとき、入力特徴マップの小領域データとカーネルとが演算回路18に入力され、演算回路18から、小領域ごとの畳み込み処理の結果を表す出力特徴マップが出力される。
 処理部42は、処理部32と同様に、小領域ごとに、当該小領域を構成する全ての特徴が、同値の小領域に対応するか否かを判定する。当該小領域を構成する全ての特徴が、同値の小領域に対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する全ての特徴が当該同値である場合に対して処理された結果を、当該小領域を処理した結果として出力する。
 また、処理部42は、処理部32と同様に、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応するか否かを判定する。当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、当該小領域を処理した結果として出力する。
 対象画像に対してニューラルネットワークを用いて処理した結果が、表示部16により表示される。
<第1実施形態に係る画像処理装置の作用>
 次に、第1実施形態に係る画像処理装置10の作用について説明する。
 図11は、画像処理装置10による学習処理の流れを示すフローチャートである。CPU11がROM12又はストレージ14から学習処理プログラムを読み出して、RAM13に展開して実行することにより、学習処理が行なわれる。また、画像処理装置10に、学習用データが入力される。
 ステップS100で、CPU11は、取得部30として、入力された学習用データの処理対象である対象画像及び処理結果を取得する。
 ステップS102で、CPU11は、処理部32として、畳み込み処理を含むニューラルネットワークを用いて、学習用データの対象画像を処理する。
 ステップS104で、CPU11は、更新部34として、学習用データの対象画像に対してニューラルネットワークを用いて処理した結果と、予め求められた処理結果とが一致するように、ニューラルネットワークのパラメータを更新し、事前計算結果テーブルを更新する。
 ステップS106で、CPU11は、予め定められた反復終了条件を満たしたか否かを判定する。反復終了条件を満たしていない場合には、上記ステップS102へ戻り、処理部32、及び更新部34の各処理が繰り返し行われる。これにより、ニューラルネットワークが学習される。
 上記ステップS102は、ニューラルネットワークの各層の演算処理を行う。ここで、畳み込み層の演算処理は、図12に示す処理ルーチンによって実現される。
 ステップS110において、CPU11は、処理部32として、当該畳み込み層の入力となる入力特徴マップを小領域に分割する。
 ステップS112において、CPU11は、処理部32として、RAM13から、当該畳み込み層の事前計算結果テーブルを読み出す。
 ステップS114において、CPU11は、処理部32として、分割した小領域を順に処理対象とし、処理対象の小領域を構成する特徴が、同値の小領域と対応するか、又は直前に処理された小領域の特徴と対応するかを判定する。
 具体的には、CPU11が、同値の小領域内の特徴との違いが、閾値以下である場合、処理対象の小領域を構成する特徴が、同値の小領域と対応すると判定する。
 また、CPU11が、同値の小領域内の特徴と異なる画素の画素数が閾値以下である場合、処理対象の小領域を構成する特徴が、同値の小領域と対応すると判定する。
 また、CPU11が、直前に処理された小領域内の特徴との違いが、閾値以下である場合、処理対象の小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。
 また、CPU11が、直前に処理された小領域内の特徴と異なる画素の画素数が閾値以下である場合、処理対象の小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。
 ステップS116において、CPU11は、処理部32として、入力特徴マップの各小領域データ、事前計算結果テーブル、及び上記ステップS114の判定結果を示す同値フラグ及び連続フラグを、演算回路18に出力する。そして、演算回路18は、小領域ごとに畳み込み処理を行う。このとき、処理対象の小領域が、同値の小領域に対応せず、かつ、連続して同一の小領域にも対応しない場合には、演算回路18は、処理対象の小領域に対する畳み込み処理を行う。処理対象の小領域が、同値の小領域に対応する場合、演算回路18は、処理対象である小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する特徴が当該同値である場合に対して処理された結果を、処理対象である小領域を処理した結果として出力する。
 また、処理対象である小領域が、連続して同一の小領域に対応する場合、演算回路18は、処理対象である小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、処理対象である小領域を処理した結果として出力する。
 そして、処理ルーチンを終了し、各小領域に対する処理結果からなる出力特徴マップを出力し、次の層の入力特徴マップとする。
 上記ステップS114は、分割した小領域を順に処理対象とし、処理対象の小領域を構成する特徴が、同値の小領域と対応するか、又は直前に処理された小領域の特徴と対応するかを判定する。ここで、小領域の画素毎の違いが閾値以下である場合に、同値の小領域と対応すると判定する処理は、図13に示す処理ルーチンによって実現される。
 ステップS130において、CPU11は、処理部32として、処理対象の小領域内の特徴について下位の所定ビット数α1のビットをマスクするマスク処理を行う。
 ステップS132において、CPU11は、処理部32として、上記ステップS130のマスク処理後の処理対象の小領域内の特徴が、全て同値かどうかに基づいて、処理対象の小領域を構成する特徴が、同値の小領域と対応するか否かを判定する。
 また、小領域の画素毎の違いが閾値以下である場合に、連続して同一の小領域と対応すると判定する処理は、図14に示す処理ルーチンによって実現される。
 ステップS140において、CPU11は、処理部32として、処理対象の小領域内の特徴について下位の所定ビット数α2のビットをマスクするマスク処理を行う。
 ステップS142において、CPU11は、処理部32として、上記ステップS140のマスク処理後の処理対象の小領域内の特徴が、マスク処理後の、直前に処理された小領域内の特徴と同一であるかどうかに基づいて、処理対象の小領域を構成する特徴が、直前に処理された小領域と対応するか否かを判定する。
 また、小領域内の特徴と異なる画素の画素数が閾値以下である場合に、同値の小領域と対応すると判定する処理は、図15に示す処理ルーチンによって実現される。
 ステップS150において、CPU11は、処理部32として、処理対象の小領域について、同値の小領域と比較して、特徴が異なる画素の画素数をカウントする。
 ステップS152において、CPU11は、処理部32として、上記ステップS150でカウントされた画素数が、閾値β1以下であるかどうかに基づいて、処理対象の小領域を構成する特徴が、同値の小領域と対応するか否かを判定する。
 また、小領域内の特徴と異なる画素の画素数が閾値以下である場合に、連続して同一の小領域と対応すると判定する処理は、図16に示す処理ルーチンによって実現される。
 ステップS160において、CPU11は、処理部32として、処理対象の小領域について、直前に処理された小領域と比較して、特徴が異なる画素の画素数をカウントする。
 ステップS162において、CPU11は、処理部32として、上記ステップS160でカウントされた画素数が、閾値β2以下であるかどうかに基づいて、処理対象の小領域を構成する特徴が、直前に処理された小領域と対応するか否かを判定する。
 図17は、画像処理装置10による画像処理の流れを示すフローチャートである。CPU11がROM12又はストレージ14から画像処理プログラムを読み出して、RAM13に展開して実行することにより、画像処理が行なわれる。また、画像処理装置10に、対象画像が入力される。
 ステップS120で、CPU11は、取得部40として、入力された対象画像を取得する。
 ステップS122で、CPU11は、処理部42として、上述した学習処理により学習されたニューラルネットワークを用いて、対象画像を処理する。そして、対象画像に対してニューラルネットワークを用いて処理した結果が、表示部16により表示される。
 上記ステップS122は、ニューラルネットワークの各層の演算処理を行う。ここで、畳み込み層の演算処理は、上記図12に示す処理ルーチンによって実現される。
 以上説明したように、第1実施形態に係る画像処理装置は、入力特徴マップの小領域ごとに畳み込み処理を行う際に、小領域を構成する特徴が、同値の小領域に対応する場合、又は直前に処理された小領域の特徴と対応する場合、当該小領域に対する畳み込み処理を行わず、予め定められた同値の小領域に対して処理された結果、又は直前に処理された結果を、当該小領域を処理した結果として出力する。これにより、畳み込み処理を含むニューラルネットワークを用いた処理を高速化することができる。
 スループット向上のために入力特徴マップを分割した小領域のサイズを大きくする場合や、CNN演算精度を高めるために入力特徴マップを表現するビット深度を大きくする場合には、従来手法では、小領域の内部が全てゼロとなることが少なくなり、演算を高速化できないことが多い。例えば、入力特徴マップの特徴を4ビットデータで表す場合には、小領域の内部が全てゼロとなるのに対し、入力特徴マップの特徴を6ビットデータで表す場合には、小領域の内部が全てゼロとならない。一方、本実施形態では、同値の小領域又は連続して同一の小領域に対応する小領域において、従来手法と比べて十分な演算高速化が見込める。
 また、マスクするビット数α1、α2、特徴が異なる画素数の上限数β1、β2が設定パラメータとなる。パラメータ値が大きいほどスキップ率が高くなり高速化されやすく、小さいほどCNN演算精度への影響が少ない。
 事前実験等によってニューラルネットワークに適した値を決定することが可能である。事前実験によって、一定以上のCNN演算精度を出せて、かつその中で最もスキップ性能が高くなることが多いような、α1,α2、β1、β2を決めることができる。
 もしくは、CNN演算精度の変化をフィードバックしてCNN演算精度への影響が少ない範囲で適応的にパラメータ値を変更することも可能である。例えば、CNN演算精度の閾値を設定しておき、推論処理の途中でその閾値を下回った場合、α1、α2、β1、β2を一段階小さくすることで、CNN演算精度を適応的に向上させることが可能である。
 上記のような処理により,CNN演算精度への影響を一定値以下に抑えながら、大幅なスキップ率の向上が可能となり、CNN演算処理全体の高速化が期待できる。
[第2実施形態]
 次に、第2実施形態について説明する。なお、第1実施形態と同様の構成であるため、同一符号を付して説明を省略する。
 第2実施形態では、小領域判定において、マスク処理後に、小領域内の特徴が異なる画素の画素数をカウントして、カウントした画素数が閾値以下であるか否かに基づいて、同値の小領域または連続して同一の小領域に対応するか否かを判定する点が、第1実施形態と異なっている。
<第2実施形態の概要>
 第2実施形態では、(1)小領域の画素毎の違いが閾値以外である場合、(2)小領域内の特徴が異なる画素の画素数が閾値以下である場合、の双方を同時に考慮する。具体的には、設定パラメータα1、α2、β1、β2をそれぞれ設定し、下位ビットのマスクと、小領域内の特徴が異なる画素の画素数のカウントとを同時に行う。
 これにより、画素毎の違いが閾値以下であれば、いくつ存在しても許容し、画素毎の違いが閾値以上となる画素数が、一定数β1、β2以下まで許容する、という条件で、処理スキップが行われる。
<第2実施形態に係る画像処理装置の構成>
 処理部32が、小領域ごとに、当該小領域を構成する全ての特徴が、同値の小領域と対応するか否かを判定する。当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する全ての特徴が当該同値である場合に対して処理された結果を、当該小領域を処理した結果として出力する。
 具体的には、処理部32が、小領域ごとに、同値の小領域内の特徴との違いが、閾値以下であれば、同一の特徴とみなした上で、同値の小領域内の特徴と異なる画素の画素数が閾値以下である場合、当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定する。例えば、処理対象の小領域内の特徴を表す下位の所定ビット数α1のビット以外のビットが同一であれば、同一の特徴とみなした上で、同値の小領域と比較して、特徴が異なる画素の画素数をカウントし、カウントした画素数が閾値β1以下である場合、当該小領域を構成する全ての特徴が、同値の小領域と対応すると判定する。
 また、処理部32が、小領域ごとに、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応するか否かを判定する。当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、当該小領域を処理した結果として出力する。
 具体的には、処理部32が、小領域ごとに、直前に処理された小領域内の特徴との違いが、閾値以下であれば、同一の特徴とみなした上で、直前に処理された小領域内の特徴と異なる画素の画素数が閾値以下である場合、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。
 例えば、処理対象の小領域内の特徴を表す下位の所定ビット数α2のビット以外のビットが同一であれば、同一の特徴とみなした上で、直前に処理された小領域と比較して、特徴が異なる画素の画素数をカウントし、カウントした画素数が閾値β2以下である場合、当該小領域を構成する全ての特徴が、直前に処理された小領域の特徴と対応すると判定する。
<第2実施形態に係る画像処理装置の作用>
 畳み込み層の演算処理は、上記図12に示す処理ルーチンによって実現される。ここで、ステップS114では、CPU11は、処理部32として、分割した小領域を順に処理対象とし、処理対象の小領域を構成する特徴が、同値の小領域と対応するか、又は直前に処理された小領域の特徴と対応するかを判定する。
 具体的には、CPU11が、同値の小領域内の特徴との違いが、閾値以下であれば、同一の特徴とみなした上で、同値の小領域内の特徴と異なる画素の画素数が閾値以下である場合、処理対象の小領域を構成する特徴が、同値の小領域と対応すると判定する。
 また、CPU11が、直前に処理された小領域内の特徴との違いが、閾値以下であれば、同一の特徴とみなした上で、直前に処理された小領域内の特徴と異なる画素の画素数が閾値以下である場合、処理対象の小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定する。
 上記ステップS114は、分割した小領域を順に処理対象とし、処理対象の小領域を構成する特徴が、同値の小領域と対応するか、又は直前に処理された小領域の特徴と対応するかを判定する。ここで、小領域の画素毎の違いが閾値以下であれば、同一の特徴とみなした上で、小領域内の特徴と異なる画素の画素数が閾値以下である場合に、同値の小領域と対応すると判定する処理は、図18に示す処理ルーチンによって実現される。
 ステップS130において、CPU11は、処理部32として、処理対象の小領域内の特徴について下位の所定ビット数α1のビットをマスクするマスク処理を行う。
 ステップS200において、CPU11は、処理部32として、マスク処理後の処理対象の小領域について、同値の小領域と比較して、特徴が異なる画素の画素数をカウントする。
 ステップS202において、CPU11は、処理部32として、上記ステップS200でカウントされた画素数が、閾値β1以下であるかどうかに基づいて、処理対象の小領域を構成する特徴が、同値の小領域と対応するか否かを判定する。
 また、小領域の画素毎の違いが閾値以下であれば、同一の特徴とみなした上で、小領域内の特徴と異なる画素の画素数が閾値以下である場合に、連続して同一の小領域と対応すると判定する処理は、図19に示す処理ルーチンによって実現される。
 ステップS140において、CPU11は、処理部32として、処理対象の小領域内の特徴について下位の所定ビット数α2のビットをマスクするマスク処理を行う。
 ステップS210において、CPU11は、処理部32として、マスク処理後の処理対象の小領域について、マスク処理後の、直前に処理された小領域と比較して、特徴が異なる画素の画素数をカウントする。
 ステップS212において、CPU11は、処理部32として、上記ステップS210でカウントされた画素数が、閾値β2以下であるかどうかに基づいて、処理対象の小領域を構成する特徴が、直前に処理された小領域と対応するか否かを判定する。
 次に、図20を用いて、畳み込み層の演算処理の一例を示す。
 まず、入力特徴マップとして、小領域1つを与える(S220)。図20では、8ビット精度、kernelサイズ3×3、出力する小領域サイズ4×2の場合を示す。この場合、処理対象の小領域のサイズは6×4となる。小領域内の24つの特徴をf(t:0~23)として表す。
 そして、同値の小領域であるかの判定のためのマスク処理を行う(S222)。与えられるパラメータα1により、f’=f≫α1としてマスク処理後の小領域内の特徴f’を算出する。
 また、同値の小領域であるかの判定のためのカウント処理を行う(S224)。マスク処理後の小領域に対して、1つ目の値f’をxとし、xと同値でないf’の個数をカウントし、y個とする。
 y≦β1の場合、処理対象の小領域内の特徴を表す下位の所定ビット数α1のビット以外のビットが同一であれば、同一の特徴とみなした上で、同値の小領域と比較して、特徴が異なる画素の画素数が、閾値β1以下であると判断し、当該小領域が、同値の小領域と判定する(S226)。同値フラグを1に立てる。
 同値フラグ1の場合、処理スキップを行う(S228)。x(=f’)が、小領域の代表値であり、事前計算結果テーブルに格納された、xに相当する畳み込み処理の結果を、出力データとしてそのまま利用すればよい。
 例えばa1=4の場合、f’は8-4=4ビット相当なので、f’は16段階の値しかとらない。それぞれの場合に出力がどうなるか、という畳み込み処理の結果を事前にしておき、事前計算結果テーブルとして保存しておく。
 同値の小領域が入力の場合は、畳み込み処理の結果も内部の値がすべて同値になるので、16段階の入力値に対してそれぞれ1つの値のみ保存しておくだけでよい。この場合、入力の代表値xに対する出力データをdxとして、畳み込み処理の結果のサイズ4×2の中の8つの値をすべてdxで埋めて、畳み込み処理の結果とすればよく、実際の積和演算なしでデータリードだけで演算結果を取得可能となる。
 また、連続して同一の小領域であるかの判定のためのマスク処理を行う(S230)。与えられるパラメータα2により、f’’=f≫α2としてマスク処理後の小領域内の特徴f’’を算出する。
 また、次の小領域の際に利用できるように、マスク処理後の値(6×4=24つの値)を保存しておく(S232)。g’’(t:0~23)とする。
 連続して同一の小領域であるかの判定のためのカウント処理を行う(S234)。マスク処理後の小領域の特徴f’’と直前の小領域の特徴g’’に対して、同じ値となっていない画素数をカウントし、z個とする。
 z≦β2の場合、処理対象の小領域内の特徴を表す下位の所定ビット数α2のビット以外のビットが同一であれば、同一の特徴とみなした上で、同値の小領域と比較して、特徴が異なる画素の画素数が閾値β2以下であると判断し、当該小領域が、連続して同一の小領域と判定する(S236)。連続フラグを1に立てる。
 連続フラグ1の場合、処理スキップを行う(S238)。前回の畳み込み処理の結果をそのまま利用する。前回の畳み込み処理の結果(4×2=8つの値)を毎回保持しておき、連続フラグ1のときはそのデータをリードすることで畳み込み処理の結果とすればよく、実際の積和演算なしでデータリードだけで演算結果を取得可能となる。
 同値フラグ及び連続フラグのどちらも0の場合、処理スキップはできないため、通常通りに演算回路18で積和演算を行うことで、畳み込み処理の結果を得る。
 なお、第2実施形態に係る画像処理装置の他の構成及び作用については、第1実施形態と同様であるため、説明を省略する。
 以上説明したように、第2実施形態に係る画像処理装置は、入力特徴マップの小領域ごとに畳み込み処理を行う際に、小領域を構成する特徴が、同値の小領域に対応する場合、又は直前に処理された小領域の特徴と対応する場合、当該小領域に対する畳み込み処理を行わず、予め定められた同値の小領域に対して処理された結果、又は直前に処理された結果を、当該小領域を処理した結果として出力する。これにより、畳み込み処理を含むニューラルネットワークを用いた処理を高速化することができる。
 また、小領域判定において、マスク処理後に、小領域内の特徴が異なる画素の画素数をカウントして、カウントした画素数が閾値以下であるか否かに基づいて、同値の小領域または連続して同一の小領域に対応するか否かを判定することにより、比較用の演算回路やデータ格納用の内部メモリ量を抑えることができる。例えば8ビットの特徴マップにおいて、小領域判定も8ビットにした場合と、下位ビットをマスクして小領域判定を行う場合とでは、同値の小領域であるかの判定と連続して同一の小領域であるかの判定で各ビットが一致するかどうかを判定するAND回路の数が減る。
 また、同値の小領域であるかの判定用にはそれぞれの値に対する結果をテーブルとして保持する必要がある。例えば8ビットの特徴マップにおいて、同値の小領域であるかの判定も8ビットにした場合、同値の小領域の入力値としては0~255の256段階がとりうる。また、同値の小領域であるかの判定を4ビットにすれば同値の小領域の入力値としては0~15の16段階でよく、同値の小領域であるかの判定のためのテーブル用のメモリ量を大幅に削減することが可能となる。
[第3実施形態]
 第3実施形態では、演算回路において複数の小領域に対して並列に畳み込み処理を行う点が、第1実施形態と異なっている。
<第3実施形態の概要>
 第3実施形態では、図21に示すように、演算回路において、入力特徴マップの複数の小領域に対して並列に畳み込み処理を行う。図21では、演算回路が、入力特徴マップの小領域のサイズを6×4とし、4個の小領域に対して並列に畳み込み処理を行い、32点の畳み込み処理の結果を同時に出力する例を示している。
 このとき、小領域ごとに、同値の小領域であるか、又は連続して同一の小領域であるかの判定を行う。図21の例では、小領域1が、同値の小領域であり、小領域3が、連続して同一の小領域であり、小領域1と小領域3の畳み込み処理がスキップされている。また、小領域0、小領域2、小領域4、及び小領域5に対して並列に畳み込み処理が行われ、結果として、1度に、6つの小領域に対する処理結果が得られている。
 このように、小領域ごとに、同値の小領域であるか、又は連続して同一の小領域であるかの判定を行い、演算回路を用いて、複数の小領域に対して並列に畳み込み処理を行うことにより、同値の小領域である確率、及び連続して同一の小領域である確率を増加させて、畳み込み処理をスキップさせる確率を増加させることができる。
<第3実施形態に係る画像処理装置の構成>
 第3実施形態の画像処理装置について説明する。第1実施形態と同様の構成となる部分については、同一符号を付して説明を省略する。
 第3実施形態の画像処理装置210のハードウェア構成は、上記図7に示す画像処理装置10のハードウェア構成と同様である。
 画像処理装置210の演算回路18は、入力特徴マップの小領域データと、カーネルとを受け付け、所定数の小領域に対して並列に畳み込み処理を行うことを繰り返し、各小領域内の各点の畳み込み処理の結果である、出力特徴マップを出力する。
 学習部20の処理部32は、畳み込み処理を含むニューラルネットワークを用いて対象画像を処理する。処理部32は、畳み込み処理を行う際に、畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに畳み込み処理を行う。小領域ごとの畳み込み処理は、演算回路18を用いて実行される。このとき、処理部32は、小領域ごとに、同値の小領域であるか否か、及び連続して同一の小領域であるか否かを判定する。入力特徴マップの小領域データとカーネルと小領域ごとの判定結果と事前計算結果テーブルとが演算回路18に入力され、演算回路18から、出力特徴マップが出力される。
 具体的には、処理部32は、畳み込み処理を行う際に、小領域ごとに、当該小領域を構成する全ての特徴が、同値の小領域に対応するか否かを判定する。当該小領域を構成する全ての特徴が、同値の小領域に対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する全ての特徴が当該同値である場合に対して処理された結果を、当該小領域を処理した結果として出力する。
 また、処理部32が、小領域ごとに、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応するか否かを判定する。当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、当該小領域を処理した結果として出力する。
 また、演算回路18は、小領域を構成する全ての特徴が同値の小領域に対応せず、かつ、直前に処理された小領域の特徴と対応しない、所定数の小領域に対して並列に畳み込み処理を行う。
 上記のように小領域ごとに行われた畳み込み処理の結果である出力特徴マップが、ニューラルネットワークの次の層の入力となる。
 推論部22の処理部42は、処理部32と同様に、畳み込み処理を含むニューラルネットワークを用いて対象画像を処理する。処理部42は、畳み込み処理を行う際に、畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに畳み込み処理を行う。小領域ごとの畳み込み処理は、演算回路18を用いて実行される。このとき、処理部42は、小領域ごとに、同値の小領域に対応するか否か、及び連続して同一の小領域に対応するか否かを判定する。入力特徴マップの小領域データとカーネルと小領域ごとの判定結果と事前計算結果テーブルとが演算回路18に入力され、演算回路18から、出力特徴マップが出力される。
 具体的には、処理部42は、処理部32と同様に、畳み込み処理を行う際に、小領域ごとに、当該小領域を構成する全ての特徴が、同値の小領域に対応するか否かを判定する。当該小領域を構成する全ての特徴が、同値の小領域に対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する全ての特徴が当該同値である場合に対して処理された結果を、当該小領域を処理した結果として出力する。
 また、処理部42は、処理部32と同様に、小領域ごとに、当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応するか否かを判定する。当該小領域を構成する特徴が、直前に処理された小領域の特徴と対応すると判定された場合、演算回路18は、当該小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、当該小領域を処理した結果として出力する。
 また、演算回路18は、小領域を構成する全ての特徴が同値の小領域に対応せず、かつ、直前に処理された小領域の特徴と対応しない、所定数の小領域に対して並列に畳み込み処理を行う。
 上記のように小領域ごとに行われた畳み込み処理の結果である出力特徴マップが、ニューラルネットワークの次の層の入力となる。
<第3実施形態に係る画像処理装置の作用>
 次に、第3実施形態に係る画像処理装置10の作用について説明する。
 画像処理装置210のCPU11がROM12又はストレージ14から学習処理プログラムを読み出して、RAM13に展開して実行することにより、は、上記図11に示す学習処理と同様の処理が行なわれる。また、画像処理装置10に、学習用データが入力される。
 上記ステップS102は、ニューラルネットワークの各層の演算処理を行う。ここで、畳み込み層の演算処理は、上記図12に示す処理ルーチンによって実現される。
 ステップS116では、処理対象の小領域を構成する特徴が、同値の小領域に対応する場合、演算回路18は、処理対象である小領域に対する畳み込み処理を行わず、事前計算結果テーブルに格納された、小領域を構成する特徴が当該同値である場合に対して処理された結果を、処理対象である小領域を処理した結果として出力する。
 また、処理対象である小領域を構成する特徴が、直前に処理された小領域の特徴と対応する場合、演算回路18は、処理対象である小領域に対する畳み込み処理を行わず、直前に処理された小領域に対して処理された結果を、処理対象である小領域を処理した結果として出力する。
 また、演算回路18は、小領域を構成する特徴が、同値の小領域に対応せず、かつ、直前に処理された小領域の特徴と対応しない所定数の小領域に対して、並列に畳み込み処理を行う。
 画像処理装置210のCPU11がROM12又はストレージ14から画像処理プログラムを読み出して、RAM13に展開して実行することにより、上記図17に示す画像処理と同様の処理が行なわれる。また、画像処理装置210に、対象画像が入力される。
 上記ステップS122は、ニューラルネットワークの各層の演算処理を行う。ここで、畳み込み層の演算処理は、上記図12に示す処理ルーチンによって実現される。
 なお、第3実施形態の画像処理装置210の他の構成及び作用については第1実施形態と同様であるため、説明を省略する。
 以上説明したように、第3実施形態に係る画像処理装置は、演算回路を、複数の小領域に対して並列に畳み込み処理を行うように構成し、入力特徴マップの小領域ごとに畳み込み処理を行う際に、小領域を構成する特徴が、同値の小領域に対応する場合、又は直前に処理された小領域の特徴と対応する場合、当該小領域に対する畳み込み処理を行わず、予め定められた同値の小領域に対して処理された結果、又は直前に処理された結果を、当該小領域を処理した結果として出力する。これにより、ビット深度や並列処理用単位が大きく、全てがゼロとなる小領域について畳み込み処理をスキップすることが期待できないような場合であっても、演算精度やスループットの低下なしで処理スキップによる高速化を期待できる。
 なお、本発明は、上述した実施形態の装置構成及び作用に限定されるものではなく、この発明の要旨を逸脱しない範囲内で様々な変形や応用が可能である。
 例えば、同値の小領域について、全ての値(例えば、特徴が4ビットデータで表される場合、16つの値)の各々に対して事前に処理結果を計算してメモリに保存しておく場合を例に説明したが、これに限定されるものではない。同値の小領域として出現する可能性の高い特徴の値を、シミュレーション等を行って予め決めておき、出現確率の高い上位いくつかの特徴の値のみについてのみ、同値の小領域に対する処理結果を予め求めておき、事前計算結果テーブルに保存しておくようにしてもよい(図22参照)。同値の小領域であって、処理結果が予め求められたものである場合に、畳み込み処理を行わずに、予め求められた処理結果を出力する。図22では、特徴の値が1である同値の小領域、特徴の値が4である同値の小領域、及び特徴の値が15である同値の小領域の各々に対してのみ、処理結果を予め求めておく例を示している。また、特徴の値が0である同値の小領域に対しては、処理結果が0であるため、事前計算結果テーブルに保存していない。これにより、予め求められた処理結果を格納する事前計算結果テーブルのサイズを削減でき、ハードウェアのメモリ量削減につながる。
 また、同値の小領域について、全ての値(例えば、特徴が4ビットデータで表される場合、16つの値)の各々に対して事前に処理結果を計算してメモリに保存しておく場合を例に説明したが、これに限定されるものではない。特徴の値がある値である同値の小領域が初めて出現したときには畳み込み処理を行ってその処理結果を計算結果テーブルに保存し、特徴の値が当該値である同値の小領域が2回目以降出現したときには、畳み込み処理を行わずに計算結果テーブルから処理結果を読み込むようにしてもよい(図23参照)。図23では、小領域2で、特徴の値が4である同値の小領域が初めて出現し、畳み込み処理を行って、処理結果を計算結果テーブルに格納する例を示している。この例では、特徴の値が4である同値の小領域が2回目以降出現したときに、畳み込み処理を行わずに、計算結果テーブルから処理結果を読み込む。また、各層を処理するたびに計算結果テーブルをリセットする。これにより、事前計算の処理の手間が不要となる。また、各層の事前計算結果を層ごとにRAM等から演算回路の内部メモリに転送する必要がないため、RAM等との転送データ量を削減することが可能である。
 また、連続して同一の小領域に対応するか否かを判定する場合を例に説明したが、これに限定されるものではない。例えば、いくつか前に処理した小領域と対応する小領域であるか否かを判定し、いくつか前に処理した小領域と対応する小領域である場合に、畳み込み処理を行わずに、当該いくつか前に処理した小領域の処理結果を出力するようにしてもよい(図24参照)。図24では、いくつか前に処理した小領域と対応するか否かを示す同一フラグに加えて、いくつ前の小領域と対応したかを示す小領域間隔のパラメータも用いて、小領域4が、小領域1と対応すると判断し、畳み込み処理を行わずに、小領域1と同一の処理結果を出力する例を示している。この場合、上限となる小領域間隔を設定し、上限となる小領域間隔の分だけ、小領域に対する処理結果を演算回路の内部メモリに保存しておく必要がある。これにより、処理スキップできる確率が増加するため高速化が期待できる。
 また、小領域が、同値の小領域と対応するか否かを判定する場合を例に説明したが、これに限定されるものではない。小領域が、同値の小領域以外の予め定められた特徴パターンと対応するか否かを判定するようにしてもよい。例えば、予め定められた頻出の特徴パターンに対する処理結果を予め求めておき、小領域が、予め定められた頻出の特徴パターンと対応するか否かを判定し、小領域が、予め定められた頻出の特徴パターンと対応する場合に、畳み込み処理を行わずに、予め求めた処理結果を出力するようにしてもよい。
 また、画像処理装置が、学習部と推論部とを備えている場合を例に説明したが、これに限定されるものではない。学習部を備えた装置と、推論部を備えた装置とを別の装置として構成してもよい。電力やサイズ等のハードウェアの制約が大きい場合に、学習部を備えた装置と、推論部を備えた装置とを別の装置として構成する方が好ましい。例えば、推論部を備えた装置を、ドローンにのせたり、IoTやエッジデバイスとして用いる場合である。また、一つの装置が学習部と推論部とを備えるように構成するのは、クラウドコンピューティングのようにデータセンタに置いてあるハードウェアを使って高速に学習させる場合が一般的である。
 また、上記実施形態で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)
 画像処理を実行するように、画像を対象とする畳み込み処理を含むニューラルネットワークを含むコンピュータによって実行可能なプログラムを記憶した非一時的記憶媒体であって、
 前記画像処理は、
 処理対象である対象画像を取得し、
 前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理することを実行させるための画像処理プログラムであって、
 前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、
 前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、
 前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、
 前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である
 非一時的記憶媒体。
10、210 画像処理装置
11 CPU
13 RAM
18 演算回路
20 学習部
22 推論部
30、40 取得部
32、42 処理部
34 更新部

Claims (8)

  1.  画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置であって、
     処理対象である対象画像を取得する取得部と、
     前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理する処理部とを含み、
     前記処理部は、前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、
     前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、
     前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、
     前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である
     画像処理装置。
  2.  前記特徴との違いが閾値以下である前記小領域は、画素毎の特徴の違いが閾値以下である小領域である請求項1記載の画像処理装置。
  3.  前記特徴との違いが閾値以下である前記小領域は、下位の所定ビット数のビット以外のビットが、前記特徴と同一である請求項2記載の画像処理装置。
  4.  前記特徴との違いが閾値以下である前記小領域は、前記特徴が異なる画素の画素数が閾値以下である小領域である請求項1記載の画像処理装置。
  5.  前記閾値は、前記ニューラルネットワークを用いた前記処理の精度が所定の精度となるように予め定められたものである請求項1記載の画像処理装置。
  6.  前記予め定められた特徴は、前記小領域内の特徴が同一のものである請求項1記載の画像処理装置。
  7.  画像を対象とする畳み込み処理を含むニューラルネットワークを含む画像処理装置における画像処理方法であって、
     取得部が、処理対象である対象画像を取得し、
     処理部が、前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理することを含み、
     前記処理部が前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、
     前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、
     前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、
     前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である
     画像処理方法。
  8.  画像を対象とする畳み込み処理を含むニューラルネットワークを含むコンピュータに、
     処理対象である対象画像を取得し、
     前記畳み込み処理を含むニューラルネットワークを用いて前記対象画像を処理することを実行させるための画像処理プログラムであって、
     前記畳み込み処理を行う際に、前記畳み込み処理の入力となる入力特徴マップを分割した小領域ごとに前記畳み込み処理を行い、
     前記小領域ごとに前記畳み込み処理を行う際に、前記小領域を構成する特徴が、予め定められた特徴、又は過去に処理された小領域の特徴と対応する場合、前記小領域に対する前記畳み込み処理を行わず、前記予め定められた特徴に対して処理された結果、又は過去に処理された結果を、前記小領域を処理した結果として出力し、
     前記予め定められた特徴と対応する前記小領域は、前記予め定められた特徴との違いが、閾値以下である前記小領域であり、
     前記過去に処理された小領域の特徴と対応する前記小領域は、前記過去に処理された小領域の特徴との違いが、閾値以下である前記小領域である
     画像処理プログラム。
PCT/JP2022/022961 2022-06-07 2022-06-07 画像処理装置、画像処理方法、及び画像処理プログラム WO2023238237A1 (ja)

Priority Applications (1)

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

Applications Claiming Priority (1)

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

Publications (1)

Publication Number Publication Date
WO2023238237A1 true WO2023238237A1 (ja) 2023-12-14

Family

ID=89118084

Family Applications (1)

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

Country Status (1)

Country Link
WO (1) WO2023238237A1 (ja)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190114532A1 (en) * 2017-10-13 2019-04-18 Ajou University Industry-Academic Cooperation Foundation Apparatus and method for convolution operation of convolution neural network

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190114532A1 (en) * 2017-10-13 2019-04-18 Ajou University Industry-Academic Cooperation Foundation Apparatus and method for convolution operation of convolution neural network

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
GISSI-HF INVESTIGATORS: "Effect of n-3 polyunsaturated fatty acids in patients with chronic heart failure (the GISSI-HF trial): a randomised, double-blind, placebo-controlled trial", THE LANCET, ELSEVIER, AMSTERDAM, NL, vol. 372, no. 9645, 4 October 2008 (2008-10-04), AMSTERDAM, NL , pages 1223 - 1230, XP002617314, ISSN: 0140-6736, DOI: 10.1016/s0140-6736(08)61239-8 *

Similar Documents

Publication Publication Date Title
US10586149B2 (en) Convolutional neural network based image data processing apparatus, method for controlling the same, and storage medium storing program
CN111199273A (zh) 卷积计算方法、装置、设备及存储介质
CN105389290B (zh) 有效插值
US10642578B2 (en) Approximating functions
CN111768458A (zh) 一种基于卷积神经网络的稀疏图像处理方法
WO2023238237A1 (ja) 画像処理装置、画像処理方法、及び画像処理プログラム
CN109032667B (zh) 一种分子动力学模拟中邻接表快速建立方法和系统
US10902087B2 (en) Device and method for accelerating matrix multiply operations as a sum of outer products
JP2022102966A (ja) 情報処理装置、情報処理方法
WO2022259427A1 (ja) 画像処理装置、画像処理方法、及び画像処理プログラム
US9519948B2 (en) Data processing apparatus, data processing method, and non-transitory computer readable medium
CN115578272A (zh) 一种图像处理方法、装置及计算设备
US11886874B2 (en) Arithmetic operation device and arithmetic operation method
CN114662647A (zh) 处理用于神经网络的层的数据
US11494165B2 (en) Arithmetic circuit for performing product-sum arithmetic
CN109388428B (zh) 图层遍历方法、控制装置及数据处理系统
TWI830940B (zh) 資訊處理電路以及資訊處理電路的設計方法
JP2009037565A (ja) ベクトル量子化装置及び方法
WO2024004221A1 (ja) 演算処理装置、演算処理方法、及び演算処理プログラム
WO2023243040A1 (ja) 画像処理装置、画像処理方法、及び画像処理プログラム
US20220351334A1 (en) Method and electronic device for multi-functional image restoration
WO2023105694A1 (ja) 推論装置、算定装置、設定方法、算定方法、及び算定プログラム
US20240236295A1 (en) Image data decompression
TW202147162A (zh) 資訊處理電路及資訊處理電路之設計方法
US10298812B2 (en) Halftone mask manufacturing method and halftone mask manufacturing system

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: 22945745

Country of ref document: EP

Kind code of ref document: A1