mirror of
https://github.com/iperov/DeepFaceLab.git
synced 2025-07-06 04:52:13 -07:00
"Enable autobackup" option is replaced by
"Autobackup every N hour" 0..24 (default 0 disabled), Autobackup model files with preview every N hour
This commit is contained in:
parent
ee27bb0aac
commit
5620763ccf
3 changed files with 21 additions and 15 deletions
|
@ -154,9 +154,14 @@ class SampleProcessor(object):
|
|||
if motion_blur is not None:
|
||||
chance, mb_max_size = motion_blur
|
||||
chance = np.clip(chance, 0, 100)
|
||||
|
||||
rnd_state = np.random.RandomState (sample_rnd_seed)
|
||||
mblur_rnd_chance = rnd_state.randint(100)
|
||||
mblur_rnd_kernel = rnd_state.randint(mb_max_size)+1
|
||||
mblur_rnd_deg = rnd_state.randint(360)
|
||||
|
||||
if np.random.randint(100) < chance:
|
||||
img = imagelib.LinearMotionBlur (img, np.random.randint( mb_max_size )+1, np.random.randint(360) )
|
||||
if mblur_rnd_chance < chance:
|
||||
img = imagelib.LinearMotionBlur (img, mblur_rnd_kernel, mblur_rnd_deg )
|
||||
|
||||
if gaussian_blur is not None:
|
||||
chance, kernel_max_size = gaussian_blur
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue