Given an original image and a convolved version of it, I need to calculate the convolution kernel. For example, given:

[![original image][1]][1]

and

[![convolved image][2]][2]

I would like to calculate the convolution kernel that generated the second image from the first (a gaussian in this case). 

The images will be similar to the example, but I can change the configuration slightly to make the process easier (change the shape, have a number of shapes etc.)


  [1]: https://i.sstatic.net/U2oQP.jpg
  [2]: https://i.sstatic.net/N7i6S.jpg