fix sampler defaults, facehires strength check

This commit is contained in:
Vladimir Mandic
2024-06-11 08:55:04 -04:00
parent 1fe7d922b8
commit d302ffbfa4
4 changed files with 22 additions and 5 deletions
+2
View File
@@ -48,6 +48,7 @@ def generate(args): # pylint: disable=redefined-outer-name
options['sampler_name'] = args.sampler
options['width'] = int(args.width)
options['height'] = int(args.height)
options['restore_faces'] = args.faces
data = post('/sdapi/v1/txt2img', options)
t1 = time.time()
if 'images' in data:
@@ -71,6 +72,7 @@ if __name__ == "__main__":
parser.add_argument('--height', required=False, default=512, help='image height')
parser.add_argument('--steps', required=False, default=20, help='number of steps')
parser.add_argument('--seed', required=False, default=-1, help='initial seed')
parser.add_argument('--faces', action='store_true', help='restore faces')
parser.add_argument('--sampler', required=False, default='Euler a', help='sampler name')
parser.add_argument('--output', required=False, default=None, help='output image file')
parser.add_argument('--model', required=False, help='model name')