- Prepare by installing the conda environment using
conda env create --file=env.yaml, which will install the environmentmemlocin python 3.9. - Add folders
logs,checkpointsand subfolders to the root folder by runningbash setup_folders.sh. - Train models by running
run_all.sh trainingfrom withinsrc/submit_scripts/. Model checkpoints will be stored to thecheckpoints/<dataset>folder, and during training / analysis progress information will be saved tologs/<analysis_type>. - Subsequently, analyses can be conducted by running
run_all.sh <analysis>from withinsrc/submit_scriptswhere analysis is one ofswapping | retraining | gradients | probing | centroid_analysis. - Individual analyses can be visualised using the corresponding notebooks (
visualise_layer_swapping.ipynb,visualise_layer_retraining.ipynb,visualise_gradients.py,visualise_probing.ipynb), that start with cells for the control setup (section 3.2), followed by cells the main results analysis (section 4). - Centroid analysis can be performed using
visualise_centroid_analysis.ipynb, after first executingvisualise_mmaps.ipynbfor all models / datasets, to compute the generalisation scores used in the centroid analysis correlation analysis. - Afterwards, summary visualisations can be computed using
summarising_visualisations.ipynb. - For the appendix experiments using the 1.3B models, execute
run_all.sh <mode>from withinsrc/submit_scripts_big/first usingtraining, followed byswappingandcentroid_analysis.
vernadankers/memorisation_localisation
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|