- 03 Nov, 2022 2 commits
-
-
Suraj Patil authored
* make accelerate hard dep * default fast init * move params to cpu when device map is None * handle device_map=None * handle torch < 1.9 * remove device_map="auto" * style * add accelerate in torch extra * remove accelerate from extras["test"] * raise an error if torch is available but not accelerate * update installation docs * Apply suggestions from code review Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * improve defautl loading speed even further, allow disabling fats loading * address review comments * adapt the tests * fix test_stable_diffusion_fast_load * fix test_read_init * temp fix for dummy checks * Trigger Build * Apply suggestions from code review Co-authored-by:
Anton Lozhkov <anton@huggingface.co> Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> Co-authored-by:
Anton Lozhkov <anton@huggingface.co>
-
Anton Lozhkov authored
* Allow saving `None` pipeline components * support flax as well * style
-
- 02 Nov, 2022 1 commit
-
-
Patrick von Platen authored
* [Loading] Ignore unneeded files * up
-
- 31 Oct, 2022 2 commits
-
-
Patrick von Platen authored
* [Better scheduler docs] Improve usage examples of schedulers * finish * fix warnings and add test * finish * more replacements * adapt fast tests hf token * correct more * Apply suggestions from code review Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Integrate compatibility with euler Co-authored-by:
Pedro Cuenca <pedro@huggingface.co>
-
Anton Lozhkov authored
* Fix pipelines user_agent, ignore CI requests * fix circular import * N/A versions * N/A versions
-
- 27 Oct, 2022 1 commit
-
-
Anton Lozhkov authored
-
- 26 Oct, 2022 2 commits
-
-
Pi Esposito authored
* add method to enable cuda with minimal gpu usage to stable diffusion * add test to minimal cuda memory usage * ensure all models but unet are onn torch.float32 * move to cpu_offload along with minor internal changes to make it work * make it test against accelerate master branch * coming back, its official: I don't know how to make it test againt the master branch from accelerate * make it install accelerate from master on tests * go back to accelerate>=0.11 * undo prettier formatting on yml files * undo prettier formatting on yml files againn
-
Yuta Hayashibe authored
-
- 25 Oct, 2022 1 commit
-
-
Patrick von Platen authored
* start * add more logic * Update src/diffusers/models/unet_2d_condition_flax.py * match weights * up * make model work * making class more general, fixing missed file rename * small fix * make new conversion work * up * finalize conversion * up * first batch of variable renamings * remove c and c_prev var names * add mid and out block structure * add pipeline * up * finish conversion * finish * upload * more fixes * Apply suggestions from code review * add attr * up * uP * up * finish tests * finish * uP * finish * fix test * up * naming consistency in tests * Apply suggestions from code review Co-authored-by:
Suraj Patil <surajp815@gmail.com> Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> Co-authored-by:
Nathan Lambert <nathan@huggingface.co> Co-authored-by:
Anton Lozhkov <anton@huggingface.co> * remove hardcoded 16 * Remove bogus * fix some stuff * finish * improve logging * docs * upload Co-authored-by:
Nathan Lambert <nol@berkeley.edu> Co-authored-by:
Suraj Patil <surajp815@gmail.com> Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> Co-authored-by:
Nathan Lambert <nathan@huggingface.co> Co-authored-by:
Anton Lozhkov <anton@huggingface.co>
-
- 24 Oct, 2022 1 commit
-
-
apolinario authored
* Update README.md Additionally add FLAX so the model card can be slimmer and point to this page * Find and replace all * v-1-5 -> v1-5 * revert test changes * Update README.md Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * Update docs/source/quicktour.mdx Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Update README.md Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Update docs/source/quicktour.mdx Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Update README.md Co-authored-by:
Suraj Patil <surajp815@gmail.com> * Revert certain references to v1-5 * Docs changes * Apply suggestions from code review Co-authored-by:
apolinario <joaopaulo.passos+multimodal@gmail.com> Co-authored-by:
anton-l <anton@huggingface.co> Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> Co-authored-by:
Suraj Patil <surajp815@gmail.com>
-
- 21 Oct, 2022 1 commit
-
-
Patrick von Platen authored
* [Tests] Move stable diffusion into their own files * up
-
- 20 Oct, 2022 2 commits
-
-
Patrick von Platen authored
[DiffusionPipeline.from_pretrained] add warning when passing unused kwargs
-
Patrick von Platen authored
* [Stable Diffusion] Add components function * uP
-
- 19 Oct, 2022 1 commit
-
-
Patrick von Platen authored
* finish * up * Apply suggestions from code review Co-authored-by:
Anton Lozhkov <anton@huggingface.co> * Update src/diffusers/pipeline_utils.py * Finish Co-authored-by:
Anton Lozhkov <anton@huggingface.co>
-
- 16 Oct, 2022 1 commit
-
-
Patrick von Platen authored
[DeviceMap] Make sure stable diffusion can be loaded from older transformers versiosn
-
- 13 Oct, 2022 1 commit
-
-
Patrick von Platen authored
* Give more customizable options for safety checker * Apply suggestions from code review * Update src/diffusers/pipelines/stable_diffusion/pipeline_stable_diffusion.py * Finish * make style * Apply suggestions from code review Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * up Co-authored-by:
Pedro Cuenca <pedro@huggingface.co>
-
- 12 Oct, 2022 4 commits
-
-
Anton Lozhkov authored
* Add diffusers version and pipeline class to the Hub UA * Fallback to class name for pipelines * Update src/diffusers/modeling_utils.py Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * Update src/diffusers/modeling_flax_utils.py Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * Remove autoclass Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com>
-
anton-l authored
-
Patrick von Platen authored
* [Dummy imports] Better error message * Test: load pipeline with LMS scheduler. Fails with a cryptic message if scipy is not installed. * Correct Co-authored-by:Pedro Cuenca <pedro@huggingface.co>
-
- 10 Oct, 2022 1 commit
-
-
Patrick von Platen authored
* add accelerate to load models with smaller memory footprint * remove low_cpu_mem_usage as it is reduntant * move accelerate init weights context to modelling utils * add test to ensure results are the same when loading with accelerate * add tests to ensure ram usage gets lower when using accelerate * move accelerate logic to single snippet under modelling utils and remove it from configuration utils * format code using to pass quality check * fix imports with isor * add accelerate to test extra deps * only import accelerate if device_map is set to auto * move accelerate availability check to diffusers import utils * format code * add device map to pipeline abstraction * lint it to pass PR quality check * fix class check to use accelerate when using diffusers ModelMixin subclasses * use low_cpu_mem_usage in transformers if device_map is not available * NoModuleLayer * comment out tests * up * uP * finish * Update src/diffusers/pipelines/stable_diffusion/safety_checker.py * finish * uP * make style Co-authored-by:Pi Esposito <piero.skywalker@gmail.com>
-
- 07 Oct, 2022 1 commit
-
-
apolinario authored
* Swap fp16 error to warning Also remove the associated test * Formatting * warn -> warning * Update src/diffusers/pipeline_utils.py Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * make style Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com>
-
- 06 Oct, 2022 3 commits
-
-
Patrick von Platen authored
-
Patrick von Platen authored
* [Custom Pipelines] * uP * make style * finish * finish * remove ipdb * upload * fix * finish docs * Apply suggestions from code review Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> Co-authored-by:
apolinario <joaopaulo.passos@gmail.com> * finish * final uploads * remove unnecessary test Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> Co-authored-by:
apolinario <joaopaulo.passos@gmail.com>
-
Anton Lozhkov authored
* Raise an error when moving an fp16 pipeline to CPU * Raise an error when moving an fp16 pipeline to CPU * style * Update src/diffusers/pipeline_utils.py Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Update src/diffusers/pipeline_utils.py Co-authored-by:
Suraj Patil <surajp815@gmail.com> * Improve the message * cuda * Update tests/test_pipelines.py Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> Co-authored-by:
Suraj Patil <surajp815@gmail.com>
-
- 05 Oct, 2022 1 commit
-
-
Patrick von Platen authored
* up * uP * uP * make style * Apply suggestions from code review * up * finish
-
- 24 Sep, 2022 1 commit
-
-
Ryan Russell authored
* docs: `src/diffusers` readability improvements Signed-off-by:
Ryan Russell <git@ryanrussell.org> * docs: `make style` lint Signed-off-by:
Ryan Russell <git@ryanrussell.org> Signed-off-by:
Ryan Russell <git@ryanrussell.org>
-
- 23 Sep, 2022 1 commit
-
-
cloudhan authored
-
- 21 Sep, 2022 1 commit
-
-
Mishig Davaadorj authored
-
- 20 Sep, 2022 1 commit
-
-
Patrick von Platen authored
* [Flax] Fix unet and ddim scheduler * correct * finish
-
- 16 Sep, 2022 2 commits
-
-
Patrick von Platen authored
* [Download] Smart downloading * add test * finish test * update * make style
-
Yuta Hayashibe authored
* Fix typos * Add a typo check action * Fix a bug * Changed to manual typo check currently Ref: https://github.com/huggingface/diffusers/pull/483#pullrequestreview-1104468010 Co-authored-by:
Anton Lozhkov <aglozhkov@gmail.com> * Removed a confusing message * Renamed "nin_shortcut" to "in_shortcut" * Add memo about NIN Co-authored-by:
Anton Lozhkov <aglozhkov@gmail.com>
-
- 08 Sep, 2022 3 commits
-
-
Anton Lozhkov authored
* initial export and design * update imports * custom prover, import fixes * Update src/diffusers/onnx_utils.py Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * Update src/diffusers/onnx_utils.py Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * remove push_to_hub * Update src/diffusers/onnx_utils.py Co-authored-by:
Suraj Patil <surajp815@gmail.com> * remove torch_device * numpify the rest of the pipeline * torchify the safety checker * revert tensor * Code review suggestions + quality * fix tests * fix provider, add an end-to-end test * style Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> Co-authored-by:
Suraj Patil <surajp815@gmail.com>
-
Patrick von Platen authored
* Start * up * up * finish
-
Pedro Cuenca authored
* Initial support for mps in Stable Diffusion pipeline. * Initial "warmup" implementation when using mps. * Make some deterministic tests pass with mps. * Disable training tests when using mps. * SD: generate latents in CPU then move to device. This is especially important when using the mps device, because generators are not supported there. See for example https://github.com/pytorch/pytorch/issues/84288. In addition, the other pipelines seem to use the same approach: generate the random samples then move to the appropriate device. After this change, generating an image in MPS produces the same result as when using the CPU, if the same seed is used. * Remove prints. * Pass AutoencoderKL test_output_pretrained with mps. Sampling from `posterior` must be done in CPU. * Style * Do not use torch.long for log op in mps device. * Perform incompatible padding ops in CPU. UNet tests now pass. See https://github.com/pytorch/pytorch/issues/84535 * Style: fix import order. * Remove unused symbols. * Remove MPSWarmupMixin, do not apply automatically. We do apply warmup in the tests, but not during normal use. This adopts some PR suggestions by @patrickvonplaten. * Add comment for mps fallback to CPU step. * Add README_mps.md for mps installation and use. * Apply `black` to modified files. * Restrict README_mps to SD, show measures in table. * Make PNDM indexing compatible with mps. Addresses #239. * Do not use float64 when using LDMScheduler. Fixes #358. * Fix typo identified by @patil-suraj Co-authored-by:
Suraj Patil <surajp815@gmail.com> * Adapt example to new output style. * Restore 1:1 results reproducibility with CompVis. However, mps latents need to be generated in CPU because generators don't work in the mps device. * Move PyTorch nightly to requirements. * Adapt `test_scheduler_outputs_equivalence` ton MPS. * mps: skip training tests instead of ignoring silently. * Make VQModel tests pass on mps. * mps ddim tests: warmup, increase tolerance. * ScoreSdeVeScheduler indexing made mps compatible. * Make ldm pipeline tests pass using warmup. * Style * Simplify casting as suggested in PR. * Add Known Issues to readme. * `isort` import order. * Remove _mps_warmup helpers from ModelMixin. And just make changes to the tests. * Skip tests using unittest decorator for consistency. * Remove temporary var. * Remove spurious blank space. * Remove unused symbol. * Remove README_mps. Co-authored-by:
Suraj Patil <surajp815@gmail.com> Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
-
- 05 Sep, 2022 1 commit
-
-
Patrick von Platen authored
* add outputs for models * add for pipelines * finish schedulers * better naming * adapt tests as well * replace dict access with . access * make schedulers works * finish * correct readme * make bcp compatible * up * small fix * finish * more fixes * more fixes * Apply suggestions from code review Co-authored-by:
Suraj Patil <surajp815@gmail.com> Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Update src/diffusers/models/vae.py Co-authored-by:
Pedro Cuenca <pedro@huggingface.co> * Adapt model outputs * Apply more suggestions * finish examples * correct Co-authored-by:
Suraj Patil <surajp815@gmail.com> Co-authored-by:
Pedro Cuenca <pedro@huggingface.co>
-
- 30 Aug, 2022 1 commit
-
-
hysts authored
* Refactor progress bar of pipeline __call__ * Make any tqdm configs available * remove init * add some tests * remove file * finish * make style * improve progress bar test Co-authored-by:Patrick von Platen <patrick.v.platen@gmail.com>
-
- 22 Aug, 2022 1 commit
-
-
Patrick von Platen authored
-
- 19 Aug, 2022 2 commits
-
-
Pedro Cuenca authored
* Implement `pipeline.to(device)` * DiffusionPipeline.to() decides best device on None. * Breaking change: torch_device removed from __call__ `pipeline.to()` now has PyTorch semantics. * Use kwargs and deprecation notice Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> * Apply torch_device compatibility to all pipelines. * style Co-authored-by:
Patrick von Platen <patrick.v.platen@gmail.com> Co-authored-by:
anton-l <anton@huggingface.co>
-
Suraj Patil authored
* add SafetyChecker * better name, fix checker * add checker in main init * remove from main init * update logic to detect pipeline module * style * handle all safety logic in safety checker * draw text * can't draw * small fixes * treat special care as nsfw * remove commented lines * update safety checker
-