Update README.md
Browse files
README.md
CHANGED
@@ -1,3 +1,21 @@
|
|
1 |
-
---
|
2 |
-
license: mit
|
3 |
-
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: mit
|
3 |
+
---
|
4 |
+
Cached SAE acts stored in CSR format. Not especially optimized for others' use/fleshed out.
|
5 |
+
|
6 |
+
If you want to use them, do
|
7 |
+
|
8 |
+
```
|
9 |
+
import torch
|
10 |
+
|
11 |
+
csr_kwargs = torch.load('FEAT_IDX.pt')
|
12 |
+
|
13 |
+
# The matrices are stored in space-efficient formats that're incompatible with torch's sparse csr tensor.
|
14 |
+
# Convert them back before constructing the matrix.
|
15 |
+
csr_kwargs['crow_indices'] = csr_kwargs['crow_indices'].int()
|
16 |
+
csr_kwargs['col_indices'] = csr_kwargs['crow_indices'].int()
|
17 |
+
csr_kwargs['values'] = csr_kwargs['values'].float()/255
|
18 |
+
|
19 |
+
feat_acts = torch.sparse_csr_tensor(**csr_kwargs)
|
20 |
+
```
|
21 |
+
|