Remove cstr
This commit is contained in:
+4
-11
@@ -2,14 +2,6 @@ import importlib
|
||||
import traceback
|
||||
import time
|
||||
|
||||
from cstr import cstr as cstr_instancer
|
||||
|
||||
cstr = cstr_instancer()
|
||||
#! MESSAGE TEMPLATES
|
||||
cstr.add_code("msg", f"{cstr.color.LIGHTBLUE}WAS Extras: {cstr.color.END}")
|
||||
cstr.add_code("warning", f"{cstr.color.LIGHTBLUE}WAS Extras {cstr.color.LIGHTYELLOW}Warning: {cstr.color.END}")
|
||||
cstr.add_code("error", f"{cstr.color.LIGHTRED}WAS Extras {cstr.color.END}Error: {cstr.color.END}")
|
||||
|
||||
extras = [
|
||||
".ConditioningBlend",
|
||||
".DebugThis",
|
||||
@@ -19,12 +11,13 @@ extras = [
|
||||
".BLVaeEncode"
|
||||
]
|
||||
|
||||
PREFIX = '\33[31m\33[94m[WAS Extras]\33[0m '
|
||||
|
||||
NODE_CLASS_MAPPINGS = {}
|
||||
NODE_DISPLAY_NAME_MAPPINGS = {}
|
||||
module_timings = {}
|
||||
|
||||
cstr("Loading extra custom nodes...").msg.print()
|
||||
|
||||
print(f"{PREFIX}Loading extra custom nodes...")
|
||||
|
||||
for module_name in extras:
|
||||
start_time = time.time()
|
||||
@@ -50,7 +43,7 @@ for module_name in extras:
|
||||
|
||||
__all__ = ['NODE_CLASS_MAPPINGS', 'NODE_DISPLAY_NAME_MAPPINGS']
|
||||
|
||||
cstr("Import times for extras:").msg.print()
|
||||
print(f"{PREFIX} Import times for extras:")
|
||||
for module, (timing, success, error) in module_timings.items():
|
||||
print(f" {timing:.1f} seconds{('' if success else ' (IMPORT FAILED)')}: {module}")
|
||||
if error:
|
||||
|
||||
+2
-10
@@ -10,14 +10,6 @@ import comfy.samplers
|
||||
import comfy.model_management
|
||||
import nodes
|
||||
|
||||
from cstr import cstr as cstr_instancer
|
||||
|
||||
cstr = cstr_instancer()
|
||||
#! MESSAGE TEMPLATES
|
||||
cstr.add_code("msg", f"{cstr.color.LIGHTBLUE}KSampler Sequence: {cstr.color.END}")
|
||||
cstr.add_code("warning", f"{cstr.color.LIGHTBLUE}KSampler Sequence {cstr.color.LIGHTYELLOW}Warning: {cstr.color.END}")
|
||||
cstr.add_code("error", f"{cstr.color.LIGHTRED}KSampler Sequence {cstr.color.END}Error: {cstr.color.END}")
|
||||
|
||||
def slerp(strength, tensor_from, tensor_to, epsilon=1e-6):
|
||||
"""
|
||||
Perform Spherical Linear Interpolation (Slerp) between two tensors.
|
||||
@@ -125,7 +117,7 @@ if "BNK_CLIPTextEncodeAdvanced" in nodes.NODE_CLASS_MAPPINGS:
|
||||
USE_BLK = True
|
||||
|
||||
if USE_BLK:
|
||||
cstr(f"Found `{cstr.color.BOLD}ComfyUI_ADV_CLIP_emb{cstr.color.END}`. Using {cstr.color.LIGHTYELLOW}BLK Advanced CLIPTextEncode{cstr.color.END} for Conditioning Sequencing").msg.print()
|
||||
print(f"Found `\33[1mComfyUI_ADV_CLIP_emb\33[0m`. Using \33[93mBLK Advanced CLIPTextEncode\33[0m for Conditioning Sequencing")
|
||||
blk_adv = BLK_ADV()
|
||||
|
||||
class CLIPTextEncodeSequence:
|
||||
@@ -235,7 +227,7 @@ class KSamplerSeq:
|
||||
|
||||
seq_seed = seed if loop_count <= 0 else self.update_seed(seq_seed, seed_mode_seq)
|
||||
|
||||
cstr(f"Loop count: {loop_count}, Seed: {seq_seed}").msg.print()
|
||||
print(f"Loop count: {loop_count}, Seed: {seq_seed}")
|
||||
|
||||
last_positive_conditioning = positive_conditioning[0] if positive_conditioning else None
|
||||
last_negative_conditioning = negative_conditioning[0] if negative_conditioning else None
|
||||
|
||||
Reference in New Issue
Block a user