Commit Graph

356 Commits

Author SHA1 Message Date
Lincoln Stein
1139884493
Merge branch 'main' into fix/mps-fallback 2023-02-04 11:11:59 -05:00
Lincoln Stein
a42b25339f
Merge branch 'main' into bugfix/txt2mask 2023-02-04 10:25:30 -05:00
Lincoln Stein
61c3886843
Merge branch 'main' into bugfix/use-cu117-wheel 2023-02-04 09:43:52 -05:00
Lincoln Stein
6bf73a0cf9
Merge branch 'main' into bugfix/use-cu117-wheel 2023-02-04 09:17:45 -05:00
Lincoln Stein
5145df21d9
Merge branch 'main' into bugfix/merge-fixes 2023-02-04 09:17:01 -05:00
psychedelicious
a1b1a48fb3
Fixes PYTORCH_ENABLE_MPS_FALLBACK not set correctly
`torch` wasn't seeing the environment variable. I suspect this is because it was imported before the variable was set, so was running with a different environment.

Many `torch` ops are supported on MPS so this wasn't noticed immediately, but some samplers like k_dpm_2 still use unsupported operations and need this fallback.
2023-02-04 17:27:33 +11:00
Lincoln Stein
0cc2a8176e bump version 2023-02-03 23:50:57 -05:00
Lincoln Stein
2e3cd03b27
Merge branch 'main' into bugfix/use-cu117-wheel 2023-02-03 18:15:54 -05:00
Lincoln Stein
d569c9dec6 remove dead code 2023-02-03 17:35:35 -05:00
Matthias Wild
01a2b8c05b
Adapt latest changes to Dockerfile (#2478)
* remove non maintained Dockerfile

* adapt Docker related files to latest changes
- also build the frontend when building the image
- skip user response if INVOKE_MODEL_RECONFIGURE is set
- split INVOKE_MODEL_RECONFIGURE to support more than one argument

* rename `docker-build` dir to `docker`

* update build-container.yml
- rename image to invokeai
- add cpu flavor
- add metadata to build summary
- enable caching
- remove build-cloud-img.yml

* fix yarn cache path, link copyjob
2023-02-03 22:34:47 +00:00
Lincoln Stein
b23664c794 registration of mask images was off due to typo
- Problem found and fixed by @spezialspezial
- Closes #2470
2023-02-03 17:32:35 -05:00
Lincoln Stein
7fa3a499bb fix crash on Windows10 when configure script given no HF token
Crashes would occur in the invokeai-configure script if no HF token
was found in cache and the user declines to provide one when prompted.
The reason appears to be that on Linux systems getpass_asterisk()
raises an EOFError when no input is provided

On windows10, getpass_asterisk() does not raise the EOFError, but
returns an empty string instead. This patch detects this and raises
the exception so that the control logic is preserved.
2023-02-03 16:06:49 -05:00
Lincoln Stein
fc857f9d91
Merge branch 'main' into lstein/enhance-merge-models-gui 2023-02-03 12:36:23 -05:00
Lincoln Stein
d351e365d6
Merge branch 'main' into lstein/enhance-merge-models-gui 2023-02-03 10:27:32 -05:00
Lincoln Stein
9ae55c91cc quench safety checker warnings from diffusers 2023-02-03 10:14:51 -05:00
Lincoln Stein
9e46badc40 convert no longer creates StableDiffusionGenerator pipelines unless asked to 2023-02-03 10:04:32 -05:00
Lincoln Stein
ca0f3ec0e4 fix launcher shell script to use correct names for ti and merge functions 2023-02-03 09:45:57 -05:00
Eugene Brodsky
c38b0b906d (config) fix invokeai-configure path handling after manual install 2023-02-03 08:06:27 -05:00
Lincoln Stein
c79678a643 prevent crash when no default model defined 2023-02-03 02:27:50 -05:00
Lincoln Stein
3f193d2b97 attempted correction of white screen issue 2023-02-02 23:47:55 -05:00
Lincoln Stein
ddd5137cc6 Update version 2023-02-02 21:17:53 -05:00
Lincoln Stein
b9aef33ae8 enhance console gui for invokeai-merge
- Added modest adaptive behavior; if the screen is wide enough the three
  checklists of models will be arranged in a horizontal row.
- Added color support
2023-02-02 20:26:45 -05:00
Lincoln Stein
2202288eb2
Merge branch 'main' into dev/installer 2023-02-02 15:17:40 -05:00
Lincoln Stein
fc3378bb74
Load legacy ckpt files as diffusers models (#2468)
* refactor ckpt_to_diffuser to allow converted pipeline to remain in memory

- This idea was introduced by Damian
- Note that although I attempted to use the updated HuggingFace module
  pipelines/stable_diffusion/convert_from_ckpt.py, it was unable to
  convert safetensors files for reasons I didn't dig into.
- Default is to extract EMA weights.

* add --ckpt_convert option to load legacy ckpt files as diffusers models

- not quite working - I'm getting artifacts and glitches in the
  converted diffuser models
- leave as draft for time being

* do not include safety checker in converted files

* add ability to control which vae is used

API now allows the caller to pass an external VAE model to the
checkpoint conversion process. In this way, if an external VAE is
specified in the checkpoint's config stanza, this VAE will be used
when constructing the diffusers model.

Tested with both regular and inpainting 1.X models.

Not tested with SD 2.X models!

---------

Co-authored-by: Jonathan <34005131+JPPhoto@users.noreply.github.com>
Co-authored-by: Damian Stewart <null@damianstewart.com>
2023-02-02 20:15:44 +00:00
Lincoln Stein
d58574ca46
Merge branch 'main' into dev/installer 2023-02-02 13:53:11 -05:00
Lincoln Stein
3810d6a4ce numerous tweaks
1. only load triton on linux machines
2. require pip >= 23.0 so that editable installs can run without setup.py
3. model files default to SD-1.5, not 2.1
4. use diffusers model of inpainting rather than ckpt
5. selected a new set of initial models based on # of likes at huggingface
2023-02-02 00:28:38 -05:00
Kevin Turner
44d36a0e0b fix(img2img): do not attempt to do a zero-step img2img when strength is low 2023-02-01 18:42:54 -08:00
Lincoln Stein
8ce9f07223
Merge branch 'main' into dev/installer 2023-02-01 17:50:22 -05:00
Kevin Turner
8cdc65effc
Merge branch 'main' into fix_2418_simplified 2023-01-31 17:45:54 -08:00
mauwii
6fdc9ac224 re-enable INVOKE_MODEL_RECONFIGURE 2023-02-01 01:21:07 +01:00
Lincoln Stein
e6d52d7ce6
Merge branch 'main' into fix_2418_simplified 2023-01-31 18:11:56 -05:00
Lincoln Stein
56e2d22b6e
Merge branch 'main' into feat/solid-infill 2023-01-31 18:02:17 -05:00
Lincoln Stein
0066187651
Merge branch 'main' into feat/solid-infill 2023-01-31 17:53:09 -05:00
Lincoln Stein
d3d24fa816 fill color is parameterized 2023-01-31 17:52:33 -05:00
Kevin Turner
4d58fed6b0
Merge branch 'main' into fix/inpainting-blank-slate 2023-01-31 11:04:56 -08:00
Kevin Turner
eed802f5d9
Merge branch 'main' into fix/hires_inpaint 2023-01-31 09:34:29 -08:00
Lincoln Stein
1c377b7995 further improvements to ability to find location of data files
- implement the following pattern for finding data files under both
  regular and editable install conditions:

  import invokeai.foo.bar as bar
  path = bar.__path__[0]

- this *seems* to work reliably with Python 3.9. Testing on 3.10 needs
  to be performed.
2023-01-31 12:24:55 -05:00
Lincoln Stein
fc8e3dbcd3 fix crash when editing name of model
- fixes a spurious "unknown model name" error when trying to edit the
  short name of an existing model.
- relaxes naming requirements to include the ':' and '/' characters
  in model names
2023-01-31 09:59:58 -05:00
mauwii
ab9daf1241
remove frontend from configure_invokeai.py
since it does not get accessed there at all
2023-01-31 08:15:48 +01:00
Lincoln Stein
9ad4c03277 Various fixes
1) Downgrade numpy to avoid dependency conflict with numba
2) Move all non ldm/invoke files into `invokeai`. This includes assets, backend, frontend, and configs.
3) Fix up way that the backend finds the frontend and the generator finds the NSFW caution.png icon.
2023-01-30 18:42:17 -05:00
Damian Stewart
5299324321 workaround for pytorch bug, fixes #2418 2023-01-30 18:45:53 +01:00
Damian Stewart
478c379534 for cac make t_start=0.1 the default 2023-01-30 15:30:01 +01:00
Jonathan
5ce62e00c9
Merge branch 'main' into diffusers_cross_attention_control_reimplementation 2023-01-29 13:52:01 -06:00
Kevin Turner
5a8c28de97 Merge remote-tracking branch 'origin/main' into fix/hires_inpaint 2023-01-29 10:51:59 -08:00
Jonathan
07e03b31b7
Update --hires_fix (#2414)
* Update --hires_fix

Change `--hires_fix` to calculate initial width and height based on the model's resolution (if available) and with a minimum size.
2023-01-29 12:27:01 -06:00
Eugene Brodsky
5ee5c5a012 (training) correctly import TI module; fix type annotation 2023-01-28 19:09:16 -05:00
Eugene Brodsky
2c0bee2a6d (config) ensure the correct 'invokeai' command is displayed to the user after configuration 2023-01-28 17:39:33 -05:00
Eugene Brodsky
34e0d7aaa8 (config) rename all mentions of scripts/configure_invokeai.py to the new invokeai-configure command 2023-01-28 17:39:33 -05:00
Eugene Brodsky
47dbe7bc0d (assets) move 'caution.png' to avoid including entire 'assets' dir in the wheel
reduces wheel size to 3MB from 27MB
2023-01-28 17:39:33 -05:00
Eugene Brodsky
2ff47cdecf (scripts) rename/reorganize CLI scripts
- add torch MPS fallback directly to CLI.py
- rename CLI scripts with `invoke-...` prefix
- delete long-deprecated scripts
- add a missing package dependency
- delete setup.py as obsolete
2023-01-28 17:39:33 -05:00