Split some of the dependencies that are prone to problems into ComfyUI_LayerStyle_Advance
This commit is contained in:
+9
-4
@@ -1,11 +1,16 @@
|
||||
from .imagefunc import *
|
||||
import torch
|
||||
import copy
|
||||
import cv2
|
||||
import numpy as np
|
||||
from PIL import Image
|
||||
from .imagefunc import log, guidedFilter
|
||||
|
||||
|
||||
NODE_NAME = 'Sharp & Soft'
|
||||
|
||||
class SharpAndSoft:
|
||||
|
||||
def __init__(self):
|
||||
pass
|
||||
self.NODE_NAME = 'Sharp & Soft'
|
||||
|
||||
@classmethod
|
||||
def INPUT_TYPES(self):
|
||||
@@ -61,7 +66,7 @@ class SharpAndSoft:
|
||||
details = (imgB / imgG - 1) * detail_mult + 1
|
||||
dup[index] = np.clip(details * imgG - imgB + image, 0, 1)
|
||||
|
||||
log(f"{NODE_NAME} Processed {dup.shape[0]} image(s).", message_type='finish')
|
||||
log(f"{self.NODE_NAME} Processed {dup.shape[0]} image(s).", message_type='finish')
|
||||
return (torch.from_numpy(dup),)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user