# Create Gaussian noise for artificial dataset with different noise levels

I am creating an artificial dataset corresponding to different noise levels. This is to simulate results of a recognition software (e.g. face recognition). For example, for $noise_{level} = 0.1$, the detection rate should be ~$0.9$ $(=1.0 - noise_{level})$.

For adding a Gaussian noise to the clean dataset, I assumed $\mu = 0.0$, and standard deviation of the noise to be

$\sigma_{noise} = (range_{max} - range_{min}) * noise_{level}$

where $range_{max}$, $range_{min}$ are the maximum and minimum values that the parameter can get, respectively (For example, $1.0$ and $0.0$ for similarity score ranges of face recognition).

However, I cannot achieve corresponding detection rates. I was able to achieve the detection rates I wanted by using uniform noise (changing $noise_{level}\%$ of data with random values) instead, but I was wondering if it is possible to achieve that with Gaussian. If so, what would be a good function for this purpose?

Example for clarification:

Let's say, the clean dataset similarity scores are like this:

     1    2    3    4
1   1.0  0.8  0.2  0.3
2   0.8  1.0  0.4  0.6
3   0.2  0.4  1.0  0.5
4   0.3  0.6  0.5  1.0


For each recognition a Gaussian noise will be added to the similarity scores corresponding to the person detected (For person "1": $[1.0, 0.8, 0.2, 0.3] + [-0.1, 0.2, -0.05, 0.1]$ (noise) ). For person "1" to be detected correctly, the highest similarity score should correspond to person "1". If $noise_{level}$ is low, $\sigma_{noise}$ should be low, then it won't change the scores very much, hence, the detection rate will be high. On the other case, if $noise_{level}$ is high, $\sigma_{noise}$ should be high, and the estimated identity will be more often false.

• If your similarity scores are bounded on the unit interval, you do not want Gaussian noise on the scores themselves--the Gaussian distribution is unbounded... – Richard Border Mar 28 '18 at 15:59
• Yes, you are right. For the bounded parameters, I am using truncated normal distribution to estimate the noise. – u-_-u Mar 28 '18 at 16:01
• gaussian noise would normally be defined by standard deviation of the noise,not max-min range. So the standard deviation of your distribution is the standard deviation you want to achieve for yoru noise. This would also negate the need for bounding (unless the underlying process you are modelling has bounding in place). – ReneBt Mar 28 '18 at 16:05
• Let me correct myself. I am using truncated normal distribution to create the database, not to add the noise, the noise is sampled from a Gaussian distribution. I do bound the overall sum (clean value + noise) to the parameter range though (e.g. $0.2 + -1.3 = -1.1$ which cannot be a similarity score, so it is replaced with $0.0$). I know this beats the purpose of a Gaussian distribution, but in this case, the values can be varying for each sample, compared to the uniform case, where the values remain mostly the same. – u-_-u Mar 28 '18 at 16:18