-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Cutn to the web interface sidebar. #20
Open
ZeroCool940711
wants to merge
12
commits into
tnwei:main
Choose a base branch
from
ZeroCool940711:main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ytorch, torchvision and pytorch-lightning.
…on the web interface.
…and step size/learning rate. - Added a small try block for the prev_image.png to reduce an issue that happens when the image is open on an external program and the model tries to load or save the file which resulted in a error, this should happen less frequently. - Added some extra information to the Streamlit progress bar, as I was not able to replace it by the stqdm library I tried to implement some of the features of said library like the number of iterations per seconds. - Added some lines to save the image of each step/frame that was created, these are the same images used to create the video when we hit the stop button, this should be useful to see step by step what the app has done as sometimes the video might be too fast or too low quality to see correctly what it has done. - Fixed an issue where the app could not run using the CPU only as it was by default trying to use at least one GPU. - Changed the format of the Zoom Factor field on the sidebar from "%.1e" to "%.4f", this should give better control of small increments and a better idea of what value it currently has.
… the new changes would throw an error or you would need to manually change these files for it to work.
…two commits ago that I forgot to upload.
This pull request introduces 3 alerts when merging dbb5546 into 82aff79 - view on LGTM.com new alerts:
|
This pull request introduces 3 alerts when merging eb8577b into 82aff79 - view on LGTM.com new alerts:
|
…e and limited the float to 2 decimal places so it looks better. This is only shown when using a fixed number of steps and the percent will not show if the number of steps is -1 as when using -1 its supposed to run until you stop it so there is no point in showing the progress bar and the percent completed.
…to upload these folders to the repository.
… the way to access this exception on the newest version of the library.
This pull request introduces 3 alerts when merging 7adecea into 82aff79 - view on LGTM.com new alerts:
|
…use. By default it will be using the Adam optimizer, just like before, but a few others have been added to the drop menu under this option.
…h-optimizer is used for a few options on the list of customizable optimizers from the previous commit while retry is used to avoid a small issue when saving the preview image to disk where some times it could make the whole app crash if the file was been written to fast to disk and an external image viewer had the image open, this would raise a PermissionError or OSError, with the retry library we give it a couple of tries without crashing the app.
This pull request introduces 3 alerts when merging 29e90b2 into 82aff79 - view on LGTM.com new alerts:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds a small but kind of important QOL change that I made, it will add an option to customize the
Cutn
value from the web interface.By having an option to change the number of cuts or
cutn
value we can reduce the amount of VRAM the app uses and so we can use higher resolutions than we were able to use before, for comparison, when using the previous default value which was 64 cutn I could only use a resolution of up to 400x400 with my Nvidia RTX 3050, after having an option to customize the cutn when using a value of 32 cutn I can use a resolution up to 512x512 and with a value of 25 cutn I was able to get up 1024x1024 a couple of times before adding any other option. It does come with some downsides but it's better to have the option to adjust that value than not having it at all. With a lower number of cuts we use less VRAM but the quality of the result image also decrease, a higher number of cuts give a better quality but also uses more VRAM on your GPU, if I'm not mistaken this is the value that is sent to CLIP to match the image to the text prompt, the more cuts we sent the better idea CLIP has of our current image and so it can match the text to the image better.I also modified the
environment.yml
file so we can use a newer version ofpytorch
,torchvision
andpytorch-lightning
.