I have written a function to add poisson noise to an image using numpy with np.random.poisson(..)
. The image is already in numpy array form, using grayscale (0-255). I am wandering if it makes more physical sense to provide the numpy function with the pixel values as the rates for the distribution, or use a set value over all the image.
In the first case, the function will be expressed as:
import numpy as np
def poisson_noise(X):
noise = np.random.poisson(X, X.shape)
return noise + X
In the second:
import numpy as np
def poisson_noise(X):
noise = np.random.poisson(CONSTANT_RATE, X.shape)
return noise + X
In the first case, the pixels with higher grayscale value (lighter) will be more influenced by the noise, would that have any physical interpretation ?
Thank you!