Skip to content

Commit f9abc6f

Browse files
fix --png_compression command line argument (#2950)
- The value of png_compression was always 6, despite the value provided to the --png_compression argument. This fixes the bug. - It also fixes an inconsistency between the maximum range of png_compression and the help text. - Closes #2945
2 parents d9dab1b + d840c59 commit f9abc6f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

invokeai/backend/args.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -490,7 +490,7 @@ def _create_arg_parser(self):
490490
"-z",
491491
type=int,
492492
default=6,
493-
choices=range(0, 9),
493+
choices=range(0, 10),
494494
dest="png_compression",
495495
help="level of PNG compression, from 0 (none) to 9 (maximum). Default is 6.",
496496
)
@@ -943,7 +943,6 @@ def _create_dream_cmd_parser(self):
943943
"--png_compression",
944944
"-z",
945945
type=int,
946-
default=6,
947946
choices=range(0, 10),
948947
dest="png_compression",
949948
help="level of PNG compression, from 0 (none) to 9 (maximum). [6]",

0 commit comments

Comments
 (0)