tanganke commited on
Commit
549c76c
·
verified ·
1 Parent(s): 739d0a3

Upload folder using huggingface_hub

Browse files
Files changed (4) hide show
  1. README.md +76 -0
  2. config.json +133 -0
  3. model.safetensors +3 -0
  4. preprocessor_config.json +22 -0
README.md ADDED
@@ -0,0 +1,76 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: microsoft/resnet-18
3
+ library_name: transformers
4
+ tags:
5
+ - fusion-bench
6
+ - merge
7
+ ---
8
+ # Deep Model Fusion
9
+
10
+ Fine-tuned ResNet model on dataset resisc45.
11
+
12
+ ## Models Merged
13
+
14
+ This is a merged model created using [fusion-bench](https://github.com/tanganke/fusion_bench).
15
+
16
+ The following models were included in the merge:
17
+
18
+
19
+
20
+
21
+ ## Configuration
22
+
23
+ The following YAML configuration was used to produce this model:
24
+
25
+ ### Algorithm Configuration
26
+
27
+ ```yaml
28
+ _recursive_: false
29
+ _target_: fusion_bench.method.classification.image_classification_finetune.ImageClassificationFineTuning
30
+ _usage_: null
31
+ _version_: 0.2.25.dev0
32
+ dataloader_kwargs:
33
+ batch_size: 128
34
+ num_workers: 8
35
+ pin_memory: true
36
+ label_smoothing: 0
37
+ lr_scheduler: null
38
+ max_epochs: -1
39
+ max_steps: 4000
40
+ optimizer:
41
+ _target_: torch.optim.SGD
42
+ lr: 0.01
43
+ momentum: 0.9
44
+ weight_decay: 0.0001
45
+ save_interval: 1000
46
+ save_on_train_epoch_end: true
47
+ save_top_k: -1
48
+ training_data_ratio: 1.0
49
+ ```
50
+
51
+ ### Model Pool Configuration
52
+
53
+ ```yaml
54
+ _recursive_: false
55
+ _target_: fusion_bench.modelpool.resnet_for_image_classification.ResNetForImageClassificationPool
56
+ _usage_: null
57
+ _version_: 0.2.25.dev0
58
+ models:
59
+ _pretrained_:
60
+ config_path: microsoft/resnet-18
61
+ dataset_name: resisc45
62
+ pretrained: true
63
+ test_datasets: null
64
+ train_datasets:
65
+ resisc45:
66
+ _target_: datasets.load_dataset
67
+ path: tanganke/resisc45
68
+ split: train
69
+ type: transformers
70
+ val_datasets:
71
+ resisc45:
72
+ _target_: datasets.load_dataset
73
+ path: tanganke/resisc45
74
+ split: test
75
+ ```
76
+
config.json ADDED
@@ -0,0 +1,133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "ResNetForImageClassification"
4
+ ],
5
+ "depths": [
6
+ 2,
7
+ 2,
8
+ 2,
9
+ 2
10
+ ],
11
+ "downsample_in_bottleneck": false,
12
+ "downsample_in_first_stage": false,
13
+ "dtype": "float32",
14
+ "embedding_size": 64,
15
+ "hidden_act": "relu",
16
+ "hidden_sizes": [
17
+ 64,
18
+ 128,
19
+ 256,
20
+ 512
21
+ ],
22
+ "id2label": {
23
+ "0": "airplane",
24
+ "1": "airport",
25
+ "2": "baseball diamond",
26
+ "3": "basketball court",
27
+ "4": "beach",
28
+ "5": "bridge",
29
+ "6": "chaparral",
30
+ "7": "church",
31
+ "8": "circular farmland",
32
+ "9": "cloud",
33
+ "10": "commercial area",
34
+ "11": "dense residential",
35
+ "12": "desert",
36
+ "13": "forest",
37
+ "14": "freeway",
38
+ "15": "golf course",
39
+ "16": "ground track field",
40
+ "17": "harbor",
41
+ "18": "industrial area",
42
+ "19": "intersection",
43
+ "20": "island",
44
+ "21": "lake",
45
+ "22": "meadow",
46
+ "23": "medium residential",
47
+ "24": "mobile home park",
48
+ "25": "mountain",
49
+ "26": "overpass",
50
+ "27": "palace",
51
+ "28": "parking lot",
52
+ "29": "railway",
53
+ "30": "railway station",
54
+ "31": "rectangular farmland",
55
+ "32": "river",
56
+ "33": "roundabout",
57
+ "34": "runway",
58
+ "35": "sea ice",
59
+ "36": "ship",
60
+ "37": "snowberg",
61
+ "38": "sparse residential",
62
+ "39": "stadium",
63
+ "40": "storage tank",
64
+ "41": "tennis court",
65
+ "42": "terrace",
66
+ "43": "thermal power station",
67
+ "44": "wetland"
68
+ },
69
+ "label2id": {
70
+ "airplane": 0,
71
+ "airport": 1,
72
+ "baseball diamond": 2,
73
+ "basketball court": 3,
74
+ "beach": 4,
75
+ "bridge": 5,
76
+ "chaparral": 6,
77
+ "church": 7,
78
+ "circular farmland": 8,
79
+ "cloud": 9,
80
+ "commercial area": 10,
81
+ "dense residential": 11,
82
+ "desert": 12,
83
+ "forest": 13,
84
+ "freeway": 14,
85
+ "golf course": 15,
86
+ "ground track field": 16,
87
+ "harbor": 17,
88
+ "industrial area": 18,
89
+ "intersection": 19,
90
+ "island": 20,
91
+ "lake": 21,
92
+ "meadow": 22,
93
+ "medium residential": 23,
94
+ "mobile home park": 24,
95
+ "mountain": 25,
96
+ "overpass": 26,
97
+ "palace": 27,
98
+ "parking lot": 28,
99
+ "railway": 29,
100
+ "railway station": 30,
101
+ "rectangular farmland": 31,
102
+ "river": 32,
103
+ "roundabout": 33,
104
+ "runway": 34,
105
+ "sea ice": 35,
106
+ "ship": 36,
107
+ "snowberg": 37,
108
+ "sparse residential": 38,
109
+ "stadium": 39,
110
+ "storage tank": 40,
111
+ "tennis court": 41,
112
+ "terrace": 42,
113
+ "thermal power station": 43,
114
+ "wetland": 44
115
+ },
116
+ "layer_type": "basic",
117
+ "model_type": "resnet",
118
+ "num_channels": 3,
119
+ "out_features": [
120
+ "stage4"
121
+ ],
122
+ "out_indices": [
123
+ 4
124
+ ],
125
+ "stage_names": [
126
+ "stem",
127
+ "stage1",
128
+ "stage2",
129
+ "stage3",
130
+ "stage4"
131
+ ],
132
+ "transformers_version": "4.56.1"
133
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2cc555a4afbb6885a6b0f058bb2e029217cd7d80b6155c52cfb133a32cdfe2f5
3
+ size 44852596
preprocessor_config.json ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "crop_pct": 0.875,
3
+ "do_normalize": true,
4
+ "do_rescale": true,
5
+ "do_resize": true,
6
+ "image_mean": [
7
+ 0.485,
8
+ 0.456,
9
+ 0.406
10
+ ],
11
+ "image_processor_type": "ConvNextImageProcessor",
12
+ "image_std": [
13
+ 0.229,
14
+ 0.224,
15
+ 0.225
16
+ ],
17
+ "resample": 3,
18
+ "rescale_factor": 0.00392156862745098,
19
+ "size": {
20
+ "shortest_edge": 224
21
+ }
22
+ }