1. A method for reducing noise generated by absorption of x-ray photons in an image sensor having a number of pixels, wherein said method comprises the steps of: identifying (S 1 ; S 15 ) so-called hot pixels affected by absorption of x-rays, calculating (S 2 ; S 16 ), for each hot pixel, directional gradients in a number of different directions in a pixel neighborhood of the hot pixel, the gradient, for each direction, being calculated based on neighborhood pixel values in the considered direction, selecting (S 3 ; S 17 ), for each hot pixel, at least one direction among those directions having the lowest gradients, determining (S 4 ; S 18 ), for each hot pixel, a replacement value based on neighborhood pixel values in the selected direction(s), and replacing (S 5 ; S 19 ), for each hot pixel, the value of the hot pixel with the determined replacement value.