mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
Update controlnet-aux to 0.0.6 and add LeReS
This commit is contained in:
parent
862bfa2c36
commit
fc322aa9f7
@ -31,7 +31,7 @@ from controlnet_aux import (
|
|||||||
ZoeDetector,
|
ZoeDetector,
|
||||||
MediapipeFaceDetector,
|
MediapipeFaceDetector,
|
||||||
SamDetector,
|
SamDetector,
|
||||||
# LeresDetector,
|
LeresDetector,
|
||||||
)
|
)
|
||||||
|
|
||||||
from controlnet_aux.util import HWC3, ade_palette
|
from controlnet_aux.util import HWC3, ade_palette
|
||||||
@ -470,27 +470,27 @@ class MediapipeFaceProcessorInvocation(ImageProcessorInvocation, PILInvocationCo
|
|||||||
processed_image = mediapipe_face_processor(image, max_faces=self.max_faces, min_confidence=self.min_confidence)
|
processed_image = mediapipe_face_processor(image, max_faces=self.max_faces, min_confidence=self.min_confidence)
|
||||||
return processed_image
|
return processed_image
|
||||||
|
|
||||||
# class LeresImageProcessorInvocation(ImageProcessorInvocation, PILInvocationConfig):
|
class LeresImageProcessorInvocation(ImageProcessorInvocation, PILInvocationConfig):
|
||||||
# """Applies leres processing to image"""
|
"""Applies leres processing to image"""
|
||||||
# # fmt: off
|
# fmt: off
|
||||||
# type: Literal["leres_image_processor"] = "leres_image_processor"
|
type: Literal["leres_image_processor"] = "leres_image_processor"
|
||||||
# # Inputs
|
# Inputs
|
||||||
# thr_a: float = Field(default=0, description="Leres parameter `thr_a`")
|
thr_a: float = Field(default=0, description="Leres parameter `thr_a`")
|
||||||
# thr_b: float = Field(default=0, description="Leres parameter `thr_b`")
|
thr_b: float = Field(default=0, description="Leres parameter `thr_b`")
|
||||||
# boost: bool = Field(default=False, description="Whether to use boost mode")
|
boost: bool = Field(default=False, description="Whether to use boost mode")
|
||||||
# detect_resolution: int = Field(default=512, ge=0, description="The pixel resolution for detection")
|
detect_resolution: int = Field(default=512, ge=0, description="The pixel resolution for detection")
|
||||||
# image_resolution: int = Field(default=512, ge=0, description="The pixel resolution for the output image")
|
image_resolution: int = Field(default=512, ge=0, description="The pixel resolution for the output image")
|
||||||
# # fmt: on
|
# fmt: on
|
||||||
#
|
|
||||||
# def run_processor(self, image):
|
def run_processor(self, image):
|
||||||
# leres_processor = LeresDetector.from_pretrained("lllyasviel/Annotators")
|
leres_processor = LeresDetector.from_pretrained("lllyasviel/Annotators")
|
||||||
# processed_image = leres_processor(image,
|
processed_image = leres_processor(image,
|
||||||
# thr_a=self.thr_a,
|
thr_a=self.thr_a,
|
||||||
# thr_b=self.thr_b,
|
thr_b=self.thr_b,
|
||||||
# boost=self.boost,
|
boost=self.boost,
|
||||||
# detect_resolution=self.detect_resolution,
|
detect_resolution=self.detect_resolution,
|
||||||
# image_resolution=self.image_resolution)
|
image_resolution=self.image_resolution)
|
||||||
# return processed_image
|
return processed_image
|
||||||
|
|
||||||
|
|
||||||
class TileResamplerProcessorInvocation(ImageProcessorInvocation, PILInvocationConfig):
|
class TileResamplerProcessorInvocation(ImageProcessorInvocation, PILInvocationConfig):
|
||||||
|
@ -39,7 +39,7 @@ dependencies = [
|
|||||||
"click",
|
"click",
|
||||||
"clip_anytorch", # replacing "clip @ https://github.com/openai/CLIP/archive/eaa22acb90a5876642d0507623e859909230a52d.zip",
|
"clip_anytorch", # replacing "clip @ https://github.com/openai/CLIP/archive/eaa22acb90a5876642d0507623e859909230a52d.zip",
|
||||||
"compel>=1.2.1",
|
"compel>=1.2.1",
|
||||||
"controlnet-aux>=0.0.5",
|
"controlnet-aux>=0.0.6",
|
||||||
"timm==0.6.13", # needed to override timm latest in controlnet_aux, see https://github.com/isl-org/ZoeDepth/issues/26
|
"timm==0.6.13", # needed to override timm latest in controlnet_aux, see https://github.com/isl-org/ZoeDepth/issues/26
|
||||||
"datasets",
|
"datasets",
|
||||||
"diffusers[torch]~=0.17.1",
|
"diffusers[torch]~=0.17.1",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user