Commit Graph

37 Commits

Author SHA1 Message Date
Mark Knol
ea6b422bff
very minor spelling error (#762)
* Update frontend.py

* Update frontend.py

Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-18 04:57:08 +01:00
Thomas Mello
e6a9e5d968
fix: disable live prompt parsing, fix #676 2022-09-13 00:37:56 +03:00
Thomas Mello
0dffc3918d fix: advanced editor (#827), close #811
refactor js_Call hook to take all gradio arguments
2022-09-08 16:09:10 +03:00
hlky
a00d827cd8
Dev merge (#819)
* #715 #699 #698 #663 #625 #617 #611 #604 (#716)

* Update README.md

* Add sampler name to metadata (#695)

Co-authored-by: EliEron <example@example.com>

* old-dev-merge

Co-authored-by: EliEron <subanimehd@gmail.com>
Co-authored-by: EliEron <example@example.com>

* img2img-fix (#717)

* Revert "img2img-fix (#717)"

This reverts commit 70d4b1ca2a.

* img2img fixes

* Revert "img2img fixes"

This reverts commit e66eddc621.

* Revert "Revert "img2img-fix (#717)""

This reverts commit bf08b617d4.

* img2img fixed

* - Removed duplicated calls to save_sample.
- Change variables and arguments to be more self-explanatory and easier to understand what they do.

* Moved streamlit files to their proper location, before they were incorrectly added to the repository root folder.

* Added retry dependency for the streamlit version.

* Added .cmd file for easy running and updating the streamlit version of the UI.

* Removed duplicated entry for streamlit on the environment.yaml file.

* Removed some unnecessary lines from the the webui_streamlit.cmd file.

* add gfpgan folder to gitignore, auto gen by imglab

* added placeholder text similar to gradio

* added auto conversion for 4 channel PNG to RGB

* fix: regex escape characters

* Update Readme links to sd-webui when appropriate (#781)

* Update link to sd-webui when appropriate

* added LDSR instruction per devilismyfriend guide

* fix: stack overflow during recursion call (#784)

* Added option to set default sampler name from config file, will be useful for those wanting to change the default sampler and  have it persist even when closing the UI and opening it again.

* Added try and except block to handle basic errors like StopException which is raised by streamlit when you hit the stop button and KeyError which happens also when stopping the generation because it tries to check the model at the end which is not loaded at that time, this can be ignored and so thats the reason for the exception.

* separate css to external file

* Added "git pull" and "git stash" to the commands run by the cmd scripts when launching the UI, this should make it so people who use it can automatically update the code from the repo and be up to date without manually using those commands everytime.

* resolve conflict with master

Co-authored-by: EliEron <subanimehd@gmail.com>
Co-authored-by: EliEron <example@example.com>
Co-authored-by: ZeroCool <ZeroCool940711@users.noreply.github.com>
Co-authored-by: ZeroCool940711 <alejandrogilelias940711@gmail.com>
Co-authored-by: Hafiidz <3688500+Hafiidz@users.noreply.github.com>
Co-authored-by: Thomas Mello <work.mello@gmail.com>
2022-09-08 11:41:04 +01:00
hlky
490bbbc103
Img2img dev (#736)
* #715 #699 #698 #663 #625 #617 #611 #604 (#716)

* Update README.md

* Add sampler name to metadata (#695)

Co-authored-by: EliEron <example@example.com>

* old-dev-merge

Co-authored-by: EliEron <subanimehd@gmail.com>
Co-authored-by: EliEron <example@example.com>

* img2img-fix (#717)

* Revert "img2img-fix (#717)"

This reverts commit 70d4b1ca2a.

* img2img fixes

* Revert "img2img fixes"

This reverts commit e66eddc621.

* Revert "Revert "img2img-fix (#717)""

This reverts commit bf08b617d4.

* img2img fixed

* feat: bring back Crop mode, formatting

Co-authored-by: EliEron <subanimehd@gmail.com>
Co-authored-by: EliEron <example@example.com>
Co-authored-by: Thomas Mello <work.mello@gmail.com>
2022-09-07 20:19:00 +01:00
hlky
e5e1663457
Revert load settings/tkinter 2022-09-04 01:46:17 +01:00
Thomas Mello
435d152c24
fix mask generation (#600) 2022-09-04 01:28:15 +01:00
devilismyfriend
de95a09593
[Various Changes] GoBig fixes, model loading unloading and more (#553)
* added image lab

* first release

model loading/unloading and save procedure added, commented out unused code from frontend

* bug fixes

Changed the image output to a gallery to display multiple items

Fixed results not showing up in output

Fixed RealESRGAN 2x mode not working and hard coded the default value for the reload.

* added GoBig model check

* added LDSR load check

* removed global statements, added model loader/unloader function

* fixed optimized mode

* update

* update

Added send to lab button
Added a print out if latent-diffusion folder isn't found

* brought back the fix faces and upscale in generation tab

* uncommenting img lab flag

* added LDSR instructions

* default imgProcessorTask set to false

* exposed LDSR settings to lab

users need to reclone the LDSR repo to use them.

* Update frontend.py

moving some stuff around to make them more coherent

* restored upscale and fix faces to img2img

* added notice section

* fixed gfpgan/upscaled pictures not showing in 2img interfaces

* send to lab button now sends info as well

* uncommented dimension info update

* added increment buttons to sampler for that k_euler_a action

* image lab settings toggle on and off with selection

* removed wip settings panel

* better model loading handling and removed increment buttons

* explaining

* disabled SD unloading in image lab upscaling with realesgan and face fix

* fixed a conflict with image lab

Co-authored-by: dr3amer <91037083+dr3am37@users.noreply.github.com>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-03 09:07:17 +01:00
cobryan05
6a1a97e31e
Image Lab: Display Png metadata (#528)
This adds a text box to Image Lab that displays the metadata
of any PNG files dropped on it. Can be used to read the info
saved with --save-metadata

Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-03 08:40:02 +01:00
cobryan05
b969428590
Job Manager feature - view images before all are complete, cancel ongoing generations (#460)
* Add max-jobs command line argument

Adds a new command line argument, max-jobs, which will set the number
of concurrent jobs the gradio queue will allow. When set to more than
the default of 1 the gradio UI will be able to process additional
UI commands at the same time.

* JobManager: initial txt2img implementation

Initial implementation of JobManager, applied to txt2img.
Adds 'refresh' and 'cancel' buttons to the UI. These are useful when
generating images with large batch counts. The 'refresh' button will
update the gallery with the currently-generated images, and the cancel
button will cause the generation to stop after the current iteration.

The new job manager can be disabled with the parameter
  --no-job-manager

* JobManager: Add status update text

* JobManager: Replace wrapped inputs as well

* JobManager: Per-session unique keys

* JobManager: Pre and Post call funcs, UI updates

Added pre- and post- function call 'dummy objects' to allow updating
the UI before and after a generate run. Update the visuals of the
buttons and status text in these new functions.

* JobManager: enforce maximum jobs

* JobManager: Move 'call' func code block

It just makes more sense between _pre and _post.

* JobManager: Add session management

Adds support for multiple browser sessions.
A single session cannot run the same job twice.

If there are no available jobs when Generate is clicked, the
generation aborts. It does *not* queue.

* JobManager: add session maintenance

Addded the ability for one session to stop all concurrent sessions,
and to free memory from any 'finished' sessions for which the
browser has been closed (as the images will be stored until the
browser does a final 'refresh' after the job finishes, which will
never happen if the browser closed)

* JobManager: Add img2img support

This *should* add JobManager to img2img, but it is untested
since img2img is broken for me even without my changes.

* Fixed img2img functionality on this pr

* Revert "Fixed img2img functionality on this pr"

This reverts commit 649b1e8e65.

* Img2Img: Fix 'image editor' options not visible

* Fix Img2Img Job Manager integration

* Img2Img UI: Move JobManager above Image Actions

It is helpful if it is on the screen when you hit generate, so
you can notice the button light up when generation starts.

* Improve job status text

* JobManager: Free available job on exception

* JobManager: Add queueing

Adds a simple queueing system to JobManager. If max-jobs concurrent
jobs are already active then any subsequent jobs will block until
a slot frees up.

Note: The UI does not give great feedback to this. The JobManager
status box will say "Loading..."

* JobManager: Fix queue accidentally LIFO

Queues should really be first in, first out.

* JobManager: add draw_gradio_ui function

Reduces a lot of boilerplate code in frontend.py

Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-03 08:30:07 +01:00
Johannes Gäßler
4af33ccda9
Load txt2img setting from files or clipboard (#436)
Functional restore defaults

From file, non-working paste

Working paste settings
2022-09-03 08:24:03 +01:00
hlky
3ea787b5d7
Merge branch 'master' of https://github.com/hlky/stable-diffusion-webui 2022-09-01 18:58:06 +01:00
hlky
decd31ca92
Can't run batches more than 10 after latest commits #218 2022-09-01 18:58:02 +01:00
devilismyfriend
678578c99d
[Image lab] Send to lab button (#444)
* added image lab

* first release

model loading/unloading and save procedure added, commented out unused code from frontend

* bug fixes

Changed the image output to a gallery to display multiple items

Fixed results not showing up in output

Fixed RealESRGAN 2x mode not working and hard coded the default value for the reload.

* added GoBig model check

* added LDSR load check

* removed global statements, added model loader/unloader function

* fixed optimized mode

* update

* update

Added send to lab button
Added a print out if latent-diffusion folder isn't found

* brought back the fix faces and upscale in generation tab

Co-authored-by: dr3amer <91037083+dr3am37@users.noreply.github.com>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-01 18:48:51 +01:00
altryne
45fafec68a
[Big update] - Dynamic params, Ui rehaul, mobile fixes, and simplification of the txt2img tab (#421)
* Merge with master

* params in prompt WIP

Signed-off-by: Alex Volkov <alex.volkov@fundbox.com>

* Added highligted text output, added copy and pastable dynamic params

Signed-off-by: Alex Volkov <alex.volkov@fundbox.com>

* Fixes with working repo

Signed-off-by: altryne <altryne@gmail.com>

* some fixes

Signed-off-by: Alex Volkov <alex.volkov@fundbox.com>
Signed-off-by: altryne <altryne@gmail.com>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-01 14:18:17 +01:00
devilismyfriend
a447938cde
[updates] Image Tab (#433)
* added image lab

* first release

model loading/unloading and save procedure added, commented out unused code from frontend

* bug fixes

Changed the image output to a gallery to display multiple items

Fixed results not showing up in output

Fixed RealESRGAN 2x mode not working and hard coded the default value for the reload.

* added GoBig model check

* added LDSR load check

* removed global statements, added model loader/unloader function

* fixed optimized mode

* update

Co-authored-by: dr3amer <91037083+dr3am37@users.noreply.github.com>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-01 12:56:11 +01:00
hlky
66dac9bcf9
conflict fix 2022-09-01 11:49:29 +01:00
devilismyfriend
1f22b0f5aa
[Feature] Image Processing tab (#401)
* added image lab

* first release

model loading/unloading and save procedure added, commented out unused code from frontend

* bug fixes

Changed the image output to a gallery to display multiple items

Fixed results not showing up in output

Fixed RealESRGAN 2x mode not working and hard coded the default value for the reload.

* added GoBig model check

* added LDSR load check

* removed global statements, added model loader/unloader function

Co-authored-by: dr3amer <91037083+dr3am37@users.noreply.github.com>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-09-01 11:32:11 +01:00
Thomas Mello
773aa60e8a
refactor: python js interface (#381)
* refactor js interface

* rename call_SD to call_JS

* add invocation example to call_JS

* serialize args before passing them to js

* allow override of x
2022-09-01 11:11:22 +01:00
hlky
fecac5c242
Update frontend.py 2022-08-31 14:59:38 +01:00
hlky
7754880f55
#234 2022-08-31 14:34:50 +01:00
hlky
341c13a4de
#172 2022-08-31 14:17:57 +01:00
hlky
dffdaaaf77
#354 + playground.py update 2022-08-31 13:58:49 +01:00
hlky
5059c2780e
txt2img width height 2022-08-31 03:25:32 +01:00
JuanRising
4ec2d328db Add dimensions info (aspect ratio and pixel count) 2022-08-31 03:22:40 +01:00
Thomas Mello
3a376392b3 fix #313 2022-08-30 23:13:51 +01:00
jansteffen
d657f6e9b9 img2img tab layout update
Moved related options to be next to each other, moved other options to be consistent with their positions on txt2img tab.
2022-08-30 23:13:51 +01:00
hlky
94f064fa81
Negative classifier free guidance scale 2022-08-30 18:16:14 +01:00
hlky
53c3aca314
Switch order of batch count and batch size 2022-08-30 14:49:51 +01:00
Thomas Mello
bdac53c5a1
refactor: Painterro UI code is moved to index.js (#316)
* decouple python from js

* bring the painterro btn back

* refactor painterro code

replicate 7ddbd6533a as close as possible

* improve reliability

* fix big brain import

Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-08-30 14:33:27 +01:00
Thomas Mello
8f76c7ad97
refactor: decouple python from js and css (#297)
* decouple python from js

* bring the painterro btn back

Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-08-30 11:37:16 +01:00
anon-hlhl
c73fdd78d9
Implement masking during sampling to improve blending (#308)
* Implement masking during sampling to improve blending

 - Almost inpainting-like behaviour
 - Works best with small erased areas
 - Denoiser strength to 1 results to completely in-paint with no previous image info
 - Uncrop kind of sometimes works, but not really
 - DDIM changes depend on a PR in stable-diffusion core

* Remove old init_masking code on save, as the masked image is applied during sampling

Co-authored-by: anon-hlhl <>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-08-30 11:32:15 +01:00
xraxra
96aba4b36d
Variations (#307)
* variation support

WIP

* removed extra )

* fixed warning

Co-authored-by: xra <mail@xra.dev>
Co-authored-by: hlky <106811348+hlky@users.noreply.github.com>
2022-08-30 11:18:00 +01:00
hlky
c620391c91
#304 2022-08-30 09:32:06 +01:00
_nderscore
7ddbd6533a feat: improve integration with painterro image editor 2022-08-29 23:35:49 +01:00
Nelson Chen
4fac0f2558 Update frontend.py
typo fix small
2022-08-29 12:19:51 +01:00
Alex Volkov
64ca78ca76 Refactored the UI, added a web_playground.py to be run without any models. 2022-08-29 00:41:17 +01:00