fix channel to variables mapping for image and video
This commit is contained in:
@@ -91,12 +91,12 @@ class ImageMathNode(io.ComfyNode):
|
||||
"x": F.get("F1", 0.0) if F.get("F1") is not None else 0.0,
|
||||
"y": F.get("F2", 0.0) if F.get("F2") is not None else 0.0,
|
||||
"z": F.get("F3", 0.0) if F.get("F3") is not None else 0.0,
|
||||
"X": getIndexTensorAlongDim(ae, 3),
|
||||
"Y": getIndexTensorAlongDim(ae, 2),
|
||||
"X": getIndexTensorAlongDim(ae, 2),
|
||||
"Y": getIndexTensorAlongDim(ae, 1),
|
||||
"B": getIndexTensorAlongDim(ae, 0),
|
||||
"batch": getIndexTensorAlongDim(ae, 0),
|
||||
"C": getIndexTensorAlongDim(ae, 1),
|
||||
"channel": getIndexTensorAlongDim(ae, 1),
|
||||
"C": getIndexTensorAlongDim(ae, 3),
|
||||
"channel": getIndexTensorAlongDim(ae, 3),
|
||||
"W": float(ae.shape[2]),
|
||||
"width": float(ae.shape[2]),
|
||||
"H": float(ae.shape[1]),
|
||||
|
||||
@@ -92,12 +92,12 @@ class VideoMathNode(io.ComfyNode):
|
||||
"x": F.get("F1", 0.0) if F.get("F1") is not None else 0.0,
|
||||
"y": F.get("F2", 0.0) if F.get("F2") is not None else 0.0,
|
||||
"z": F.get("F3", 0.0) if F.get("F3") is not None else 0.0,
|
||||
"X": getIndexTensorAlongDim(ae, 3),
|
||||
"Y": getIndexTensorAlongDim(ae, 2),
|
||||
"X": getIndexTensorAlongDim(ae, 2),
|
||||
"Y": getIndexTensorAlongDim(ae, 1),
|
||||
"B": getIndexTensorAlongDim(ae, 0),
|
||||
"batch": getIndexTensorAlongDim(ae, 0),
|
||||
"C": getIndexTensorAlongDim(ae, 1),
|
||||
"channel": getIndexTensorAlongDim(ae, 1),
|
||||
"C": getIndexTensorAlongDim(ae, 3),
|
||||
"channel": getIndexTensorAlongDim(ae, 3),
|
||||
"W": float(ae.shape[2]),
|
||||
"width": float(ae.shape[2]),
|
||||
"H": float(ae.shape[1]),
|
||||
|
||||
Reference in New Issue
Block a user