P01yH3dr0n commited on
Commit
d46ff0f
1 Parent(s): cecbd37

Update utils.py

Browse files
Files changed (1) hide show
  1. utils.py +4 -1
utils.py CHANGED
@@ -44,7 +44,8 @@ def generate_novelai_image(
44
  ref_str=0.6,
45
  inp_img=None,
46
  overlay=False,
47
- use_inp=False
 
48
  ):
49
  # Assign a random seed if seed is -1
50
  if seed == -1:
@@ -89,6 +90,8 @@ def generate_novelai_image(
89
  payload['model'] = 'nai-diffusion-3-inpainting'
90
  payload['parameters']['mask'] = image2base64(inp_img['layers'][0])
91
  payload['parameters']['image'] = image2base64(inp_img['background'])
 
 
92
  # Send the POST request
93
  response = requests.post(url, json=payload, headers=headers)
94
 
 
44
  ref_str=0.6,
45
  inp_img=None,
46
  overlay=False,
47
+ use_inp=False,
48
+ inp_str=0.7
49
  ):
50
  # Assign a random seed if seed is -1
51
  if seed == -1:
 
90
  payload['model'] = 'nai-diffusion-3-inpainting'
91
  payload['parameters']['mask'] = image2base64(inp_img['layers'][0])
92
  payload['parameters']['image'] = image2base64(inp_img['background'])
93
+ payload['parameters']['extra_noise_seed'] = seed
94
+ payload['parameters']['strength'] = inp_str
95
  # Send the POST request
96
  response = requests.post(url, json=payload, headers=headers)
97