diff --git a/invokeai/app/invocations/upscale.py b/invokeai/app/invocations/upscale.py index d1e98b3479..d2f53a5b9f 100644 --- a/invokeai/app/invocations/upscale.py +++ b/invokeai/app/invocations/upscale.py @@ -11,7 +11,7 @@ from pydantic import ConfigDict from invokeai.app.invocations.primitives import ImageField, ImageOutput from invokeai.app.services.image_records.image_records_common import ImageCategory, ResourceOrigin -from invokeai.backend.image_util.esrgan import RealESRGANer +from invokeai.backend.image_util.realesrgan.realesrgan import RealESRGANer from invokeai.backend.util.devices import choose_torch_device from .baseinvocation import BaseInvocation, InputField, InvocationContext, WithMetadata, WithWorkflow, invocation diff --git a/invokeai/backend/image_util/realesrgan/LICENSE b/invokeai/backend/image_util/realesrgan/LICENSE new file mode 100644 index 0000000000..552a1eeaf0 --- /dev/null +++ b/invokeai/backend/image_util/realesrgan/LICENSE @@ -0,0 +1,29 @@ +BSD 3-Clause License + +Copyright (c) 2021, Xintao Wang +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/invokeai/backend/image_util/realesrgan/__init__.py b/invokeai/backend/image_util/realesrgan/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/invokeai/backend/image_util/esrgan.py b/invokeai/backend/image_util/realesrgan/realesrgan.py similarity index 99% rename from invokeai/backend/image_util/esrgan.py rename to invokeai/backend/image_util/realesrgan/realesrgan.py index fa351dc426..042b1b2f4e 100644 --- a/invokeai/backend/image_util/esrgan.py +++ b/invokeai/backend/image_util/realesrgan/realesrgan.py @@ -15,6 +15,7 @@ from invokeai.backend.util.devices import choose_torch_device """ Adapted from https://github.com/xinntao/Real-ESRGAN/blob/master/realesrgan/utils.py +License is BSD3, copied to `LICENSE` in this directory. The adaptation here has a few changes: - Remove print statements, use `tqdm` to show progress