refactor: shorter class names
This commit is contained in:
+3
-1
@@ -9,7 +9,9 @@
|
||||
# v3.0.0
|
||||
|
||||
- From now on, the major version number will reflect the Comfy's node API version used.
|
||||
- `❗ MAJOR` internal change: All the nodes migrated to Comfy's nodes v3 API schema.
|
||||
- `❗ MAJOR` internal changes:
|
||||
- **All the nodes migrated to Comfy's nodes v3 API schema.**
|
||||
- Shorter class names.
|
||||
- Increased widget precision for various float inputs.
|
||||
- No other new features or changes in behavior.
|
||||
|
||||
|
||||
+13
-13
@@ -10,25 +10,25 @@ try:
|
||||
class BestResolutionExtension(_ComfyExtension):
|
||||
@_override
|
||||
async def get_node_list(self) -> list[type[_io.ComfyNode]]:
|
||||
from .node_crop_pad import BestResolutionUpscaledCropPad
|
||||
from .node_scale import BestResolutionScale
|
||||
from .node_crop_pad import BRUpscaledCropPad
|
||||
from .node_scale import BRScale
|
||||
from .node_upscale_by import ImageUpscaleByWithModel
|
||||
from .nodes_prims import BestResolutionPrimResPriority, BestResolutionPrimCropPadStrategy
|
||||
from .nodes_simple import BestResolutionSimple, BestResolutionFromAspectRatio, BestResolutionFromArea
|
||||
from .nodes_upscale import BestResolutionFromAreaUpscale
|
||||
from .nodes_prims import PrimResPriority, PrimCropPadStrategy
|
||||
from .nodes_simple import BRSimple, BRFromAspectRatio, BRFromArea
|
||||
from .nodes_upscale import BRFromAreaUpscale
|
||||
|
||||
return [
|
||||
BestResolutionFromArea,
|
||||
BestResolutionFromAreaUpscale,
|
||||
BestResolutionFromAspectRatio,
|
||||
BestResolutionSimple,
|
||||
BRFromArea,
|
||||
BRFromAreaUpscale,
|
||||
BRFromAspectRatio,
|
||||
BRSimple,
|
||||
|
||||
BestResolutionScale,
|
||||
BRScale,
|
||||
|
||||
BestResolutionPrimCropPadStrategy,
|
||||
BestResolutionPrimResPriority,
|
||||
PrimCropPadStrategy,
|
||||
PrimResPriority,
|
||||
|
||||
BestResolutionUpscaledCropPad,
|
||||
BRUpscaledCropPad,
|
||||
|
||||
ImageUpscaleByWithModel,
|
||||
]
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ from .funcs_crop_pad import upscaled_crop_pad as _upscaled_crop_pad
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionUpscaledCropPad(_io.ComfyNode):
|
||||
class BRUpscaledCropPad(_io.ComfyNode):
|
||||
"""
|
||||
If the original resolution can't be scaled to the higher one uniformly (i.e., without stretching),
|
||||
this node detects the appropriate values for cropping/out-painting.
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ from .__docstring_formatter import format_docstring as _format_docstring
|
||||
from .funcs import simple_result_from_approx_wh as _simple_result_from_approx_wh
|
||||
|
||||
|
||||
class BestResolutionScale(_io.ComfyNode):
|
||||
class BRScale(_io.ComfyNode):
|
||||
"""
|
||||
Scale width and height by the same value + round them.
|
||||
"""
|
||||
|
||||
+2
-2
@@ -15,7 +15,7 @@ from .__docstring_formatter import format_docstring as _format_docstring
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionPrimResPriority(_io.ComfyNode):
|
||||
class PrimResPriority(_io.ComfyNode):
|
||||
"""
|
||||
'priority' selector for "Best Resolution" upscale-nodes.
|
||||
"""
|
||||
@@ -45,7 +45,7 @@ class BestResolutionPrimResPriority(_io.ComfyNode):
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionPrimCropPadStrategy(_io.ComfyNode):
|
||||
class PrimCropPadStrategy(_io.ComfyNode):
|
||||
"""
|
||||
'strategy' selector for "Upscaled Crop/Pad" node in "Best Resolution" pack.
|
||||
"""
|
||||
|
||||
+5
-5
@@ -22,7 +22,7 @@ from .funcs import (
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionSimple(_io.ComfyNode):
|
||||
class BRSimple(_io.ComfyNode):
|
||||
"""
|
||||
The simplest node for easier selection of an optimal resolution:
|
||||
only rounding performed, desired image size specified directly.
|
||||
@@ -67,7 +67,7 @@ class BestResolutionSimple(_io.ComfyNode):
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionFromAspectRatio(_io.ComfyNode):
|
||||
class BRFromAspectRatio(_io.ComfyNode):
|
||||
"""
|
||||
A more advanced node for easier selection of an optimal resolution:
|
||||
image size selected indirectly - by one of the sides + aspect ratio.
|
||||
@@ -89,7 +89,7 @@ class BestResolutionFromAspectRatio(_io.ComfyNode):
|
||||
|
||||
hidden=[_io.Hidden.unique_id],
|
||||
|
||||
outputs=list(BestResolutionSimple._schema.outputs),
|
||||
outputs=list(BRSimple._schema.outputs),
|
||||
|
||||
is_output_node=True,
|
||||
)
|
||||
@@ -124,7 +124,7 @@ class BestResolutionFromAspectRatio(_io.ComfyNode):
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionFromArea(_io.ComfyNode):
|
||||
class BRFromArea(_io.ComfyNode):
|
||||
"""
|
||||
The most efficient way of selecting an optimal resolution:
|
||||
image size selected indirectly - by the total desired resolution (area) + aspect ratio.
|
||||
@@ -155,7 +155,7 @@ class BestResolutionFromArea(_io.ComfyNode):
|
||||
|
||||
hidden=[_io.Hidden.unique_id],
|
||||
|
||||
outputs=list(BestResolutionSimple._schema.outputs),
|
||||
outputs=list(BRSimple._schema.outputs),
|
||||
|
||||
is_output_node=True,
|
||||
)
|
||||
|
||||
+2
-2
@@ -21,11 +21,11 @@ from .funcs import (
|
||||
float_width_height_from_area as _float_width_height_from_area,
|
||||
upscale_result_from_approx_wh as _upscale_result_from_approx_wh
|
||||
)
|
||||
from .nodes_simple import BestResolutionFromArea as _BestResolutionFromArea
|
||||
from .nodes_simple import BRFromArea as _BestResolutionFromArea
|
||||
|
||||
# ----------------------------------------------------------
|
||||
|
||||
class BestResolutionFromAreaUpscale(_io.ComfyNode):
|
||||
class BRFromAreaUpscale(_io.ComfyNode):
|
||||
"""
|
||||
The most efficient way of selecting an optimal resolution:
|
||||
image size selected indirectly - by the total desired resolution (area) + aspect ratio...
|
||||
|
||||
Reference in New Issue
Block a user