perf: clear residuals after computing direction (#15)

Co-authored-by: mad-cat-lon <113548315+mad-cat-lon@users.noreply.github.com>
This commit is contained in:
red40maxxer 2025-11-17 11:48:22 -05:00 committed by GitHub
parent 09730bad70
commit 7bad84b4f1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 0 deletions

View File

@ -39,6 +39,7 @@ from .utils import (
get_trial_parameters,
load_prompts,
print,
empty_cache,
)
@ -195,6 +196,9 @@ def run():
p=2,
dim=1,
)
# we don't need the residuals after computing refusal directions
del good_residuals, bad_residuals
empty_cache()
trial_index = 0
start_time = time.perf_counter()