├── .DS_Store ├── LICENSE ├── README.md ├── representationsurgery.png └── src ├── args.py ├── datasets ├── cars.py ├── common.py ├── dtd.py ├── eurosat.py ├── gtsrb.py ├── mnist.py ├── registry.py ├── resisc45.py ├── sun397.py ├── svhn.py └── templates.py ├── eval.py ├── finetune.py ├── heads.py ├── logs ├── result-ViT-B-16.md ├── result-ViT-B-32.md └── result-ViT-L-14.md ├── main_AdaMerging_with_surgery.py ├── main_AdaMerging_with_surgery_online.py ├── main_TaskArithmetic_with_surgery.py ├── main_TiesMerging_with_surgery.py ├── main_WeightAveraging_with_surgery.py ├── merging_cofficient.py ├── merging_model.py ├── modeling.py ├── task_vectors.py ├── ties_merging_utils.py └── utils.py /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/.DS_Store -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/README.md -------------------------------------------------------------------------------- /representationsurgery.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/representationsurgery.png -------------------------------------------------------------------------------- /src/args.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/args.py -------------------------------------------------------------------------------- /src/datasets/cars.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/cars.py -------------------------------------------------------------------------------- /src/datasets/common.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/common.py -------------------------------------------------------------------------------- /src/datasets/dtd.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/dtd.py -------------------------------------------------------------------------------- /src/datasets/eurosat.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/eurosat.py -------------------------------------------------------------------------------- /src/datasets/gtsrb.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/gtsrb.py -------------------------------------------------------------------------------- /src/datasets/mnist.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/mnist.py -------------------------------------------------------------------------------- /src/datasets/registry.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/registry.py -------------------------------------------------------------------------------- /src/datasets/resisc45.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/resisc45.py -------------------------------------------------------------------------------- /src/datasets/sun397.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/sun397.py -------------------------------------------------------------------------------- /src/datasets/svhn.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/svhn.py -------------------------------------------------------------------------------- /src/datasets/templates.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/datasets/templates.py -------------------------------------------------------------------------------- /src/eval.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/eval.py -------------------------------------------------------------------------------- /src/finetune.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/finetune.py -------------------------------------------------------------------------------- /src/heads.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/heads.py -------------------------------------------------------------------------------- /src/logs/result-ViT-B-16.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/logs/result-ViT-B-16.md -------------------------------------------------------------------------------- /src/logs/result-ViT-B-32.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/logs/result-ViT-B-32.md -------------------------------------------------------------------------------- /src/logs/result-ViT-L-14.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/logs/result-ViT-L-14.md -------------------------------------------------------------------------------- /src/main_AdaMerging_with_surgery.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/main_AdaMerging_with_surgery.py -------------------------------------------------------------------------------- /src/main_AdaMerging_with_surgery_online.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/main_AdaMerging_with_surgery_online.py -------------------------------------------------------------------------------- /src/main_TaskArithmetic_with_surgery.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/main_TaskArithmetic_with_surgery.py -------------------------------------------------------------------------------- /src/main_TiesMerging_with_surgery.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/main_TiesMerging_with_surgery.py -------------------------------------------------------------------------------- /src/main_WeightAveraging_with_surgery.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/main_WeightAveraging_with_surgery.py -------------------------------------------------------------------------------- /src/merging_cofficient.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/merging_cofficient.py -------------------------------------------------------------------------------- /src/merging_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/merging_model.py -------------------------------------------------------------------------------- /src/modeling.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/modeling.py -------------------------------------------------------------------------------- /src/task_vectors.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/task_vectors.py -------------------------------------------------------------------------------- /src/ties_merging_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/ties_merging_utils.py -------------------------------------------------------------------------------- /src/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EnnengYang/RepresentationSurgery/HEAD/src/utils.py --------------------------------------------------------------------------------