This commit is contained in:
lllyasviel
2024-01-29 08:26:43 -08:00
parent 1766710141
commit 3f21e6c621
2 changed files with 3 additions and 1 deletions

View File

@@ -23,7 +23,7 @@ class PreprocessorNormalBae(Preprocessor):
self.slider_3 = PreprocessorParameter(visible=False) self.slider_3 = PreprocessorParameter(visible=False)
self.show_control_mode = True self.show_control_mode = True
self.do_not_need_model = False self.do_not_need_model = False
self.sorting_priority = 0.0 # higher goes to top in the list self.sorting_priority = 100 # higher goes to top in the list
def load_model(self): def load_model(self):
if self.model_patcher is not None: if self.model_patcher is not None:

View File

@@ -88,6 +88,7 @@ class PreprocessorNone(Preprocessor):
def __init__(self): def __init__(self):
super().__init__() super().__init__()
self.name = 'None' self.name = 'None'
self.sorting_priority = 10
class PreprocessorCanny(Preprocessor): class PreprocessorCanny(Preprocessor):
@@ -97,6 +98,7 @@ class PreprocessorCanny(Preprocessor):
self.tags = ['Canny'] self.tags = ['Canny']
self.slider_1 = PreprocessorParameter(minimum=0, maximum=256, step=1, value=100, label='Low Threshold', visible=True) self.slider_1 = PreprocessorParameter(minimum=0, maximum=256, step=1, value=100, label='Low Threshold', visible=True)
self.slider_2 = PreprocessorParameter(minimum=0, maximum=256, step=1, value=200, label='High Threshold', visible=True) self.slider_2 = PreprocessorParameter(minimum=0, maximum=256, step=1, value=200, label='High Threshold', visible=True)
self.sorting_priority = 100
def __call__(self, input_image, resolution, slider_1=None, slider_2=None, slider_3=None, **kwargs): def __call__(self, input_image, resolution, slider_1=None, slider_2=None, slider_3=None, **kwargs):
input_image, remove_pad = resize_image_with_pad(input_image, resolution) input_image, remove_pad = resize_image_with_pad(input_image, resolution)