diff options
author | evshiron <evshiron@gmail.com> | 2022-11-04 18:36:47 +0000 |
---|---|---|
committer | evshiron <evshiron@gmail.com> | 2022-11-04 18:36:47 +0000 |
commit | b8435e632f7ba0da12a2c8e9c788dda519279d24 (patch) | |
tree | 24640bd14279201c296aaf185351327b3b815c1d /modules/shared.py | |
parent | 89722fb5e4eda2adc5d3a6abf8babf8a58e80d69 (diff) | |
download | stable-diffusion-webui-gfx803-b8435e632f7ba0da12a2c8e9c788dda519279d24.tar.gz stable-diffusion-webui-gfx803-b8435e632f7ba0da12a2c8e9c788dda519279d24.tar.bz2 stable-diffusion-webui-gfx803-b8435e632f7ba0da12a2c8e9c788dda519279d24.zip |
add --cors-allow-origins cmd opt
Diffstat (limited to 'modules/shared.py')
-rw-r--r-- | modules/shared.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/shared.py b/modules/shared.py index a9e28b9c..e83cbcdf 100644 --- a/modules/shared.py +++ b/modules/shared.py @@ -86,6 +86,7 @@ parser.add_argument("--nowebui", action='store_true', help="use api=True to laun parser.add_argument("--ui-debug-mode", action='store_true', help="Don't load model to quickly launch UI")
parser.add_argument("--device-id", type=str, help="Select the default CUDA device to use (export CUDA_VISIBLE_DEVICES=0,1,etc might be needed before)", default=None)
parser.add_argument("--administrator", action='store_true', help="Administrator rights", default=False)
+parser.add_argument("--cors-allow-origins", type=str, help="Allowed CORS origins", default=None)
cmd_opts = parser.parse_args()
restricted_opts = {
@@ -147,9 +148,9 @@ class State: self.interrupted = True
def nextjob(self):
- if opts.show_progress_every_n_steps == -1:
+ if opts.show_progress_every_n_steps == -1:
self.do_set_current_image()
-
+
self.job_no += 1
self.sampling_step = 0
self.current_image_sampling_step = 0
@@ -198,7 +199,7 @@ class State: return
if self.current_latent is None:
return
-
+
if opts.show_progress_grid:
self.current_image = sd_samplers.samples_to_image_grid(self.current_latent)
else:
|