Closed iszihan closed 2 months ago
The linear classifier is solved via least squares at this code snippet: https://github.com/snap-research/weights2weights/blob/76f0bde99ab8e48a25d825f202115300aef8efc3/editing.py#L43C1-L44C1
The pseudoinverse is precomputed and we provide the file at https://huggingface.co/snap-research/weights2weights. It can also be calculated use the proj_1000.pt file by computing torch.inverse(A.T@A)@A.T
As question says.