From ae230f29cf659475de076bf8b852e23935d0f93d Mon Sep 17 00:00:00 2001 From: Extraltodeus Date: Fri, 8 Mar 2024 10:43:10 +0100 Subject: [PATCH] fixed potential typo Seems like it was an oversight, feel free to reject if I was wrong. --- clipperpweight.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clipperpweight.py b/clipperpweight.py index d00ce5b..5de0328 100644 --- a/clipperpweight.py +++ b/clipperpweight.py @@ -87,7 +87,7 @@ class CLIPTextEncodePerpWeight: cond[i][j] = token_vector + (weight * perp) elif (weight > 0.0) and (weight < 1.0): cond[i][j] = weight * token_vector - elif (weight > -1.0) and (weight_g < 0.0): + elif (weight > -1.0) and (weight < 0.0): cond[i][j] = -1 * (zero_vector + (abs(weight) * (token_vector - zero_vector))) elif weight == -1.0: cond[i][j] = -1 * token_vector