-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
64ba298
commit 8e77696
Showing
1 changed file
with
11 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,20 @@ | ||
# MNIST | ||
|
||
### Step 1: Train | ||
Since influence functions are typically computed at the final model | ||
weight, we first train the model (MLP) on the (small) MNIST dataset | ||
before performinig influence analyses. | ||
|
||
```bash | ||
python train.py | ||
``` | ||
|
||
### Step 2: AnaLog | ||
### Step 2: Log extraction & Influence analysis | ||
With the trained model, we first extract and save logs (e.g. | ||
Hessian, gradeint) to disk, and use it to compute influence | ||
scores. Users can specify the gradient projection strategy | ||
(e.g. LoGra) and the Hessian computation strategy. | ||
|
||
```bash | ||
python compute_influences.py | ||
python compute_influences.py --lora none --hessian raw --save grad | ||
``` |