IVB-2005 commited on
Commit
be92098
·
verified ·
1 Parent(s): dc58e5d

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +94 -0
README.md ADDED
@@ -0,0 +1,94 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ tags:
4
+ - disaster-prediction
5
+ - risk-assessment
6
+ - tabular-regression
7
+ datasets:
8
+ - emirhanakku/disaster-events-2025
9
+ ---
10
+
11
+ # Disaster Risk Prediction Model
12
+
13
+ This model predicts disaster risk scores (0-1) based on location and disaster type.
14
+
15
+ ## Model Details
16
+
17
+ - **Model Type:** Random Forest Regressor
18
+ - **Framework:** scikit-learn
19
+ - **Dataset:** Disaster Events 2025 (Kaggle)
20
+ - **Features:** Location (encoded), Disaster Type (encoded)
21
+ - **Target:** Risk Score (0.0 to 1.0)
22
+
23
+ ## Usage
24
+
25
+ ```python
26
+ import joblib
27
+ from huggingface_hub import hf_hub_download
28
+
29
+ # Download model
30
+ model_path = hf_hub_download(
31
+ repo_id="IVB-2005/disaster-model",
32
+ filename="disaster_risk_model.pkl"
33
+ )
34
+ model = joblib.load(model_path)
35
+
36
+ # Download encoders
37
+ disaster_enc_path = hf_hub_download(
38
+ repo_id="IVB-2005/disaster-model",
39
+ filename="disaster_encoder.pkl"
40
+ )
41
+ disaster_encoder = joblib.load(disaster_enc_path)
42
+
43
+ location_enc_path = hf_hub_download(
44
+ repo_id="IVB-2005/disaster-model",
45
+ filename="location_encoder.pkl"
46
+ )
47
+ location_encoder = joblib.load(location_enc_path)
48
+
49
+ # Make prediction
50
+ location_encoded = location_encoder.transform(['India'])[0]
51
+ disaster_encoded = disaster_encoder.transform(['Earthquake'])[0]
52
+
53
+ features = [[location_encoded, disaster_encoded]]
54
+ risk_score = model.predict(features)[0]
55
+
56
+ print(f"Risk Score: {risk_score:.3f}")
57
+ ```
58
+
59
+ ## Risk Levels
60
+
61
+ - **0.0 - 0.3:** LOW risk
62
+ - **0.3 - 0.7:** MEDIUM risk
63
+ - **0.7 - 1.0:** HIGH risk
64
+
65
+ ## Training Data
66
+
67
+ Trained on real disaster events from 2025 including:
68
+ - Earthquakes
69
+ - Hurricanes
70
+ - Volcanic Eruptions
71
+ - Landslides
72
+ - Wildfires
73
+ - Droughts
74
+
75
+ ## Performance
76
+
77
+ - Mean Absolute Error (MAE): ~0.05
78
+ - R² Score: ~0.85
79
+
80
+ ## License
81
+
82
+ MIT License - Free for educational and commercial use.
83
+
84
+ ## Citation
85
+
86
+ ```bibtex
87
+ @misc{disaster-risk-model,
88
+ author = {Your Name},
89
+ title = {Disaster Risk Prediction Model},
90
+ year = {2025},
91
+ publisher = {Hugging Face},
92
+ url = {https://huggingface.co/IVB-2005/disaster-model}
93
+ }
94
+ ```