leavoigt commited on
Commit
b8ab5ea
1 Parent(s): 1134a2a

Add SetFit model

Browse files
Files changed (5) hide show
  1. README.md +62 -26
  2. config.json +1 -1
  3. config_setfit.json +2 -2
  4. model.safetensors +1 -1
  5. model_head.pkl +1 -1
README.md CHANGED
@@ -15,27 +15,33 @@ widget:
15
  attempt to increase tax revenues. A number of the most popular car models’ prices
16
  were about to increase – mostly large family, luxury and sport cars – but for
17
  many models, the retail price was actually reduced.
18
- - text: Facilitate transition of workers from the informal to the formal economy.
19
- This will target the promotion and facilitation of access to SP programs such
20
- as employment and entrepreneurship opportunities, social security schemes, social
21
- services, and insurance systems.
22
- - text: environmental and climate awareness, public participation of youth organizations
23
- and different local actors, teacher training in environmental education for climate
24
- change, training and technical assistance for projects that allow communities
25
- and citizens to access and acquire knowledge of environmental issues and of climate
26
- change. The process of institutionalization of environmental education and culture
27
- as public policy will promote the consolidation of comprehensive regulatory frameworks,
28
- the incorporation of the environmental and climate dimension into educational
29
- and cultural policies, the training of technical management teams and policy design.
30
- - text: SocialSecurityandCommunityDevelopment Financially sound National Insurance
31
- Services (NIS). Extensive public assistance programmes for indigent and economically
32
- disadvantaged persons. Rich cultural heritage.
33
- - text: Incorporate a mechanism for monitoring and reviewing marine protected areas
34
- management plans involving local populations;. Adopt a law to regulate marine
35
- spatial planning by 2022 and/or revision and adaptation of the current basic law
36
- of territorial planning and urban planning to include maritime spatial planning
37
- (a tool that allows the zoning of activities to be developed at sea; law defining
38
- the use of maritime space and maritime spatial planning);.
 
 
 
 
 
 
39
  pipeline_tag: text-classification
40
  inference: false
41
  base_model: sentence-transformers/all-mpnet-base-v2
@@ -86,7 +92,7 @@ from setfit import SetFitModel
86
  # Download from the 🤗 Hub
87
  model = SetFitModel.from_pretrained("leavoigt/vulnerability_multilabel_updated")
88
  # Run inference
89
- preds = model("SocialSecurityandCommunityDevelopment Financially sound National Insurance Services (NIS). Extensive public assistance programmes for indigent and economically disadvantaged persons. Rich cultural heritage.")
90
  ```
91
 
92
  <!--
@@ -118,7 +124,7 @@ preds = model("SocialSecurityandCommunityDevelopment • Financially sound Natio
118
  ### Training Set Metrics
119
  | Training set | Min | Median | Max |
120
  |:-------------|:----|:--------|:----|
121
- | Word count | 21 | 72.7143 | 238 |
122
 
123
  ### Training Hyperparameters
124
  - batch_size: (16, 2)
@@ -140,14 +146,44 @@ preds = model("SocialSecurityandCommunityDevelopment • Financially sound Natio
140
  ### Training Results
141
  | Epoch | Step | Training Loss | Validation Loss |
142
  |:------:|:----:|:-------------:|:---------------:|
143
- | 0.0006 | 1 | 0.3244 | - |
144
- | 0.6309 | 1000 | 0.0331 | 0.1204 |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
145
 
146
  ### Framework Versions
147
  - Python: 3.10.12
148
  - SetFit: 1.0.3
149
  - Sentence Transformers: 2.3.1
150
- - Transformers: 4.37.2
151
  - PyTorch: 2.1.0+cu121
152
  - Datasets: 2.3.0
153
  - Tokenizers: 0.15.2
 
15
  attempt to increase tax revenues. A number of the most popular car models’ prices
16
  were about to increase – mostly large family, luxury and sport cars – but for
17
  many models, the retail price was actually reduced.
18
+ - text: Workers in the formal sector. Formal sector workers also face economic risks.
19
+ A number of them experience income instability due to contractualization, retrenchment,
20
+ and firm closures. In 2014, contractual workers accounted for 22 percent of the
21
+ total 4.5 million workers employed in establishments with 20 or more employees.
22
+ - text: Building additional dams and power stations to further develop energy generation
23
+ potential from the same river flow as well as develop new dam sites on parallel
24
+ rivers in order to maintain the baseline hydropower electricity generation capacity
25
+ to levels attainable under a ‘no-climate change’ scenario. Developing and implementing
26
+ climate change compatible building/construction codes for buildings, roads, airports,
27
+ airfields, dry ports, railways, bridges, dams and irrigation canals that are safe
28
+ for human life and minimize economic damage that is likely to result from increasing
29
+ extremes in flooding.
30
+ - text: Another factor that increases farmer vulnerability is the remoteness of farm
31
+ villages and lack of adequate road infrastructure. Across the three regions, roads
32
+ are in a poor state and unevenly distributed, with many villages lacking roads
33
+ that connect them to other villages. Even the main roads are often accessible
34
+ only during the dry season. The livelihood implications of this isolation are
35
+ significant, as farmers have difficulties getting their products to markets as
36
+ well as obtaining agricultural inputs; in addition, farmers generally have to
37
+ pay higher prices for agricultural inputs in remote areas, reducing their profit
38
+ margins
39
+ - text: This project aims to construct a desalination plant in the capital city in
40
+ order to respond directly to drinking water supply needs. This new plant, which
41
+ will have a capacity of 22,500 m3 daily, easily expandable to 45,000 m3, will
42
+ be fuelled by renewable energy, which is expected to be provided by a wind farm
43
+ planned for the second phase of the project. Funding: European Union. Rural Community
44
+ Development and Water Mobilization Project (PRODERMO).
45
  pipeline_tag: text-classification
46
  inference: false
47
  base_model: sentence-transformers/all-mpnet-base-v2
 
92
  # Download from the 🤗 Hub
93
  model = SetFitModel.from_pretrained("leavoigt/vulnerability_multilabel_updated")
94
  # Run inference
95
+ preds = model("Workers in the formal sector. Formal sector workers also face economic risks. A number of them experience income instability due to contractualization, retrenchment, and firm closures. In 2014, contractual workers accounted for 22 percent of the total 4.5 million workers employed in establishments with 20 or more employees.")
96
  ```
97
 
98
  <!--
 
124
  ### Training Set Metrics
125
  | Training set | Min | Median | Max |
126
  |:-------------|:----|:--------|:----|
127
+ | Word count | 21 | 72.6472 | 238 |
128
 
129
  ### Training Hyperparameters
130
  - batch_size: (16, 2)
 
146
  ### Training Results
147
  | Epoch | Step | Training Loss | Validation Loss |
148
  |:------:|:----:|:-------------:|:---------------:|
149
+ | 0.0006 | 1 | 0.1906 | - |
150
+ | 0.0316 | 50 | 0.1275 | 0.1394 |
151
+ | 0.0631 | 100 | 0.0851 | 0.1247 |
152
+ | 0.0947 | 150 | 0.0959 | 0.1269 |
153
+ | 0.1263 | 200 | 0.1109 | 0.1179 |
154
+ | 0.1578 | 250 | 0.0923 | 0.1354 |
155
+ | 0.1894 | 300 | 0.063 | 0.1292 |
156
+ | 0.2210 | 350 | 0.0555 | 0.1326 |
157
+ | 0.2525 | 400 | 0.0362 | 0.1127 |
158
+ | 0.2841 | 450 | 0.0582 | 0.132 |
159
+ | 0.3157 | 500 | 0.0952 | 0.1339 |
160
+ | 0.3472 | 550 | 0.0793 | 0.1171 |
161
+ | 0.3788 | 600 | 0.059 | 0.1187 |
162
+ | 0.4104 | 650 | 0.0373 | 0.1131 |
163
+ | 0.4419 | 700 | 0.0593 | 0.1144 |
164
+ | 0.4735 | 750 | 0.0405 | 0.1174 |
165
+ | 0.5051 | 800 | 0.0284 | 0.1196 |
166
+ | 0.5366 | 850 | 0.0329 | 0.1116 |
167
+ | 0.5682 | 900 | 0.0895 | 0.1193 |
168
+ | 0.5997 | 950 | 0.0576 | 0.1159 |
169
+ | 0.6313 | 1000 | 0.0385 | 0.1203 |
170
+ | 0.6629 | 1050 | 0.0842 | 0.1195 |
171
+ | 0.6944 | 1100 | 0.0274 | 0.113 |
172
+ | 0.7260 | 1150 | 0.0226 | 0.1137 |
173
+ | 0.7576 | 1200 | 0.0276 | 0.1204 |
174
+ | 0.7891 | 1250 | 0.0355 | 0.1163 |
175
+ | 0.8207 | 1300 | 0.077 | 0.1161 |
176
+ | 0.8523 | 1350 | 0.0735 | 0.1135 |
177
+ | 0.8838 | 1400 | 0.0357 | 0.1175 |
178
+ | 0.9154 | 1450 | 0.0313 | 0.1207 |
179
+ | 0.9470 | 1500 | 0.0241 | 0.1159 |
180
+ | 0.9785 | 1550 | 0.0339 | 0.1161 |
181
 
182
  ### Framework Versions
183
  - Python: 3.10.12
184
  - SetFit: 1.0.3
185
  - Sentence Transformers: 2.3.1
186
+ - Transformers: 4.38.1
187
  - PyTorch: 2.1.0+cu121
188
  - Datasets: 2.3.0
189
  - Tokenizers: 0.15.2
config.json CHANGED
@@ -19,6 +19,6 @@
19
  "pad_token_id": 1,
20
  "relative_attention_num_buckets": 32,
21
  "torch_dtype": "float32",
22
- "transformers_version": "4.37.2",
23
  "vocab_size": 30527
24
  }
 
19
  "pad_token_id": 1,
20
  "relative_attention_num_buckets": 32,
21
  "torch_dtype": "float32",
22
+ "transformers_version": "4.38.1",
23
  "vocab_size": 30527
24
  }
config_setfit.json CHANGED
@@ -1,5 +1,4 @@
1
  {
2
- "normalize_embeddings": true,
3
  "labels": [
4
  "Agricultural communities",
5
  "Children",
@@ -19,5 +18,6 @@
19
  "Sexual minorities (LGBTQI+)",
20
  "Urban populations",
21
  "Women and other genders"
22
- ]
 
23
  }
 
1
  {
 
2
  "labels": [
3
  "Agricultural communities",
4
  "Children",
 
18
  "Sexual minorities (LGBTQI+)",
19
  "Urban populations",
20
  "Women and other genders"
21
+ ],
22
+ "normalize_embeddings": true
23
  }
model.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:824e8b534bf389debd8cd0a0bef7da9c396b04b8d1cbe229378fefed88a9520e
3
  size 437967672
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fc5541650d65cf79ee8d7500f2e924fbcb0063e43ae6a2cfa1e79acb5b89d5c5
3
  size 437967672
model_head.pkl CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:ba03ddb59157f208d69bc660203f8d171c4e816318b83777bbdf2e10e08bd2e4
3
  size 56918
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f3e1a9898cb62e49b33f8ab4771658997a423da599e0f1466da251f91e5d6d58
3
  size 56918