A computer implemented method for verifying an integrity of convolution operations of a convolutional neural network, CNN,, the method comprising the steps of: (a) instructing an adding unit to generate an extended input by adding a test pattern side-by-side to an original input image; (b) instructing the CNN to generate an output for verification by applying the convolution operations to the extended input; and (c) instructing a comparing unit to verify the integrity of the convolution operations of the CNN by comparing the output for verification with an output for reference generated by applying the convolution operations to the test pattern by the CNN on a condition that the integrity of the CNN is guaranteed, wherein the step of (a) further comprises, instructing the adding unit to add a zero pattern to the original input image and to add the test pattern so that the zero pattern is located between the original input image and the test pattern, and setting a thickness of the zero pattern such that the test pattern cannot affect the result of the convolution operations on the original input image, wherein in step (c) the output for reference is compared with a specific area of the output for verification corresponding to the test pattern and if at least one of values included in the output for reference is not identical to its corresponding value included in the specific area, at least part of parameters of the CNN are determined to have errors. (a) instructing an adding unit to generate an extended input by adding a test pattern side-by-side to an original input image; (b) instructing the CNN to generate an output for verification by applying the convolution operations to the extended input; and (c) instructing a comparing unit to verify the integrity of the convolution operations of the CNN by comparing the output for verification with an output for reference generated by applying the convolution operations to the test pattern by the CNN on a condition that the integrity of the CNN is guaranteed, wherein the step of (a) further comprises, instructing the adding unit to add a zero pattern to the original input image and to add the test pattern so that the zero pattern is located between the original input image and the test pattern, and setting a thickness of the zero pattern such that the test pattern cannot affect the result of the convolution operations on the original input image, wherein in step (c) the output for reference is compared with a specific area of the output for verification corresponding to the test pattern and if at least one of values included in the output for reference is not identical to its corresponding value included in the specific area, at least part of parameters of the CNN are determined to have errors. wherein the step of (a) further comprises, instructing the adding unit to add a zero pattern to the original input image and to add the test pattern so that the zero pattern is located between the original input image and the test pattern, and setting a thickness of the zero pattern such that the test pattern cannot affect the result of the convolution operations on the original input image, wherein in step (c) the output for reference is compared with a specific area of the output for verification corresponding to the test pattern and if at least one of values included in the output for reference is not identical to its corresponding value included in the specific area, at least part of parameters of the CNN are determined to have errors.