mirror of
https://github.com/iperov/DeepFaceLab.git
synced 2025-08-19 21:13:20 -07:00
Fix scaling
This commit is contained in:
parent
84c22511c0
commit
4a3d1d971e
1 changed files with 2 additions and 2 deletions
|
@ -228,11 +228,11 @@ class SampleProcessor(object):
|
||||||
|
|
||||||
if noise_type == 'gaussian':
|
if noise_type == 'gaussian':
|
||||||
noise = np.random.normal(scale=noise_scale, size=img.shape)
|
noise = np.random.normal(scale=noise_scale, size=img.shape)
|
||||||
img += noise
|
img += noise / 255.0
|
||||||
# pass
|
# pass
|
||||||
elif noise_type == 'laplace':
|
elif noise_type == 'laplace':
|
||||||
noise = np.random.laplace(scale=noise_scale, size=img.shape)
|
noise = np.random.laplace(scale=noise_scale, size=img.shape)
|
||||||
img += noise
|
img += noise / 255.0
|
||||||
# pass
|
# pass
|
||||||
elif noise_type == 'poisson':
|
elif noise_type == 'poisson':
|
||||||
noise_lam = (15 * np.random.random() + 15)
|
noise_lam = (15 * np.random.random() + 15)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue