From 5f73918a9447d63dcee9a73c6f9e2e23bec96abe Mon Sep 17 00:00:00 2001 From: Lucy Farnik Date: Wed, 13 Dec 2023 12:39:20 +0000 Subject: [PATCH] Fixed typo that threw out half of activations --- sae_training/train_sae_on_language_model.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sae_training/train_sae_on_language_model.py b/sae_training/train_sae_on_language_model.py index c9e3685b..8c3f335a 100644 --- a/sae_training/train_sae_on_language_model.py +++ b/sae_training/train_sae_on_language_model.py @@ -93,7 +93,7 @@ def train_sae_on_language_model( # Forward and Backward Passes optimizer.zero_grad() x = activation_store.next_batch() - sae_out, feature_acts, loss, mse_loss, l1_loss = sparse_autoencoder(activation_store.next_batch()) + sae_out, feature_acts, loss, mse_loss, l1_loss = sparse_autoencoder(x) n_training_tokens += batch_size with torch.no_grad():