Visit ComfyUI Online for ready-to-use ComfyUI environment
Compares two values, returns max/min based on mode, useful for dynamic value selection in AI art projects.
The ImpactMinMax
node is designed to compare two values and return either the maximum or minimum of the two, based on a specified mode. This node is particularly useful in scenarios where you need to dynamically determine the higher or lower value between two inputs, which can be essential in various decision-making processes within your AI art projects. By leveraging this node, you can automate the selection of optimal values, ensuring that your workflows are both efficient and effective.
The mode
parameter is a boolean that determines whether the node will return the maximum or minimum value between the two inputs. When set to True
, the node returns the maximum value (label_on
: "max"), and when set to False
, it returns the minimum value (label_off
: "min"). The default value is True
, meaning the node will return the maximum value by default. This parameter is crucial as it directly influences the outcome of the comparison.
The a
parameter represents the first value to be compared. This can be of any type that supports comparison operations. The value of a
is one of the two inputs that the node will evaluate to determine the maximum or minimum value based on the mode
parameter.
The b
parameter represents the second value to be compared. Similar to a
, this can be of any type that supports comparison operations. The value of b
is the other input that the node will evaluate to determine the maximum or minimum value based on the mode
parameter.
The output parameter is an integer that represents either the maximum or minimum value between the two inputs a
and b
, depending on the mode
parameter. This output is essential as it provides the result of the comparison, which can then be used in subsequent nodes or processes within your AI art workflow.
mode
parameter before executing the node. Setting it to True
will return the maximum value, while setting it to False
will return the minimum value.ImpactMinMax
node in conjunction with other logic nodes to create more complex decision-making workflows. For example, you can use it to dynamically adjust parameters based on certain conditions.a
and b
are of types that cannot be compared using the greater-than or less-than operators.a
and b
are of comparable types. For instance, both should be integers, floats, or any other types that support comparison operations.mode
parameter is not set to a boolean value.mode
parameter is either True
or False
. This can be done by explicitly setting the parameter in the node configuration.a
and b
are not provided.a
and b
parameters are supplied with valid values before executing the node.© Copyright 2024 RunComfy. All Rights Reserved.