Skip to content

Commit

Permalink
typechecker
Browse files Browse the repository at this point in the history
  • Loading branch information
jbloomAus committed Mar 19, 2024
1 parent 8d4a080 commit fa6cc49
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sae_training/sparse_autoencoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,8 @@ def initialize_b_dec(self, all_activations: torch.Tensor):
def initialize_b_dec_with_geometric_median(self, all_activations: torch.Tensor):
previous_b_dec = self.b_dec.clone().cpu()
out = compute_geometric_median(
all_activations, skip_typechecks=True, maxiter=100, per_component=False
all_activations,
maxiter=100,
).median

previous_distances = torch.norm(all_activations - previous_b_dec, dim=-1)
Expand Down

0 comments on commit fa6cc49

Please sign in to comment.