Adedoyinjames commited on
Commit
9fee073
Β·
verified Β·
1 Parent(s): 96566f6

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +233 -14
README.md CHANGED
@@ -1,23 +1,242 @@
1
  # Classical ML β€” Lithology Sequence Models
2
 
3
- Trained on [NoraResearchLab/Lithology-Training-Dataset](https://huggingface.co/datasets/NoraResearchLab/Lithology-Training-Dataset) (400 wells).
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
 
5
  ## Models
6
- - `models/random_forest.joblib`
7
- - `models/xgboost.joblib`
8
- - `models/lightgbm.joblib`
9
 
10
- ## Test metrics
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11
  ```
12
- n_wells depth_accuracy depth_macro_f1 depth_macro_f1_confident sequence_similarity model cv_macro_f1
13
- 66 0.791402 0.627933 0.590043 0.592659 RandomForest 0.759859
14
- 66 0.727141 0.575679 0.529313 0.517252 XGBoost 0.757091
15
- 66 0.693573 0.532102 0.483444 0.481821 LightGBM 0.726568
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
16
  ```
17
 
18
- ## Features
19
- GR, RHOB, NPHI, PEF, DT, log10(RT), CALI + missingness indicators.
20
- Pointwise classification β†’ min-thickness segmentation β†’ sequence metrics.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
21
 
22
- ## Hyperparameters
23
- See `models/*_params.json`.
 
 
 
 
1
  # Classical ML β€” Lithology Sequence Models
2
 
3
+ Classical machine-learning baselines for automated lithological sequence identification from well-log data.
4
+
5
+ The models are trained on the **NoraResearchLab/Lithology-Training-Dataset** containing 400 wells and evaluated on the independent **NoraResearchLab/lithology-sequence-benchmark**.
6
+
7
+ The workflow performs pointwise lithology classification followed by minimum-thickness segmentation to produce geological sequences. Evaluation therefore considers both individual depth-point predictions and the resulting lithological sequences.
8
+
9
+ ## Research Organization
10
+
11
+ Developed by **NORA Research Lab** β€” building intelligence for the real world.
12
+
13
+ [![GitHub](https://img.shields.io/badge/GitHub-Nora--Research--Lab-181717?logo=github)](https://github.com/Nora-Research-Lab)
14
+ [![Hugging Face](https://img.shields.io/badge/HuggingFace-NoraResearchLab-FFD21E?logo=huggingface\&logoColor=black)](https://huggingface.co/NoraResearchLab)
15
+ [![LinkedIn](https://img.shields.io/badge/LinkedIn-NORA%20Research%20Lab-0A66C2?logo=linkedin)](https://www.linkedin.com/company/nora-research-lab)
16
+ [![X](https://img.shields.io/badge/X-@noraresearchlab-000000?logo=x)](https://x.com/noraresearchlab)
17
+ [![Website](https://img.shields.io/badge/Website-noraresearchlab.site-2ea44f)](https://noraresearchlab.site)
18
+
19
+ ---
20
+
21
+ ## Datasets
22
+
23
+ ### Training Dataset
24
+
25
+ The models were trained using:
26
+
27
+ **[NoraResearchLab/Lithology-Training-Dataset](https://huggingface.co/datasets/NoraResearchLab/Lithology-Training-Dataset)**
28
+
29
+ * 400 wells
30
+ * Well-log based lithology data
31
+ * Used exclusively for model development and training
32
+
33
+ ### Independent Benchmark
34
+
35
+ The trained models were subsequently evaluated on:
36
+
37
+ **[NoraResearchLab/lithology-sequence-benchmark](https://huggingface.co/datasets/NoraResearchLab/lithology-sequence-benchmark)**
38
+
39
+ This benchmark provides an independent evaluation of lithology-sequence generalization to wells that were not used during model training.
40
+
41
+ This separation between the training dataset and benchmark is important because performance on previously unseen wells provides a more realistic indication of model generalization.
42
+
43
+ ---
44
 
45
  ## Models
 
 
 
46
 
47
+ Three classical machine-learning models were trained:
48
+
49
+ * `models/random_forest.joblib`
50
+ * `models/xgboost.joblib`
51
+ * `models/lightgbm.joblib`
52
+
53
+ Corresponding hyperparameters are available in:
54
+
55
+ * `models/random_forest_params.json`
56
+ * `models/xgboost_params.json`
57
+ * `models/lightgbm_params.json`
58
+
59
+ ---
60
+
61
+ ## Input Features
62
+
63
+ The models use the following well-log features:
64
+
65
+ * Gamma Ray (`GR`)
66
+ * Bulk Density (`RHOB`)
67
+ * Neutron Porosity (`NPHI`)
68
+ * Photoelectric Factor (`PEF`)
69
+ * Compressional Sonic (`DT`)
70
+ * Log-transformed Resistivity (`log10(RT)`)
71
+ * Caliper (`CALI`)
72
+ * Missingness indicators
73
+
74
+ The workflow uses these measurements to perform pointwise lithology classification along the well depth axis.
75
+
76
+ ---
77
+
78
+ ## Evaluation Pipeline
79
+
80
+ The evaluation consists of two main stages:
81
+
82
+ ```text
83
+ Well Logs
84
+ ↓
85
+ Feature Preparation
86
+ ↓
87
+ Pointwise Lithology Classification
88
+ ↓
89
+ Minimum-Thickness Segmentation
90
+ ↓
91
+ Lithological Sequences
92
+ ↓
93
+ Depth-Level + Sequence-Level Evaluation
94
  ```
95
+
96
+ The minimum-thickness segmentation step converts individual depth predictions into continuous geological intervals, allowing the models to be evaluated not only on individual samples but also on the resulting lithological sequence.
97
+
98
+ ---
99
+
100
+ # Benchmark Results
101
+
102
+ The models were evaluated on **66 independent wells** from the lithology sequence benchmark.
103
+
104
+ | Model | Depth Accuracy | Depth Macro F1 | Confident Macro F1 | Sequence Similarity | CV Macro F1 |
105
+ | ----------------- | -------------: | -------------: | -----------------: | ------------------: | ----------: |
106
+ | **Random Forest** | **0.7914** | **0.6279** | **0.5900** | **0.5927** | **0.7599** |
107
+ | **XGBoost** | 0.7271 | 0.5757 | 0.5293 | 0.5173 | 0.7571 |
108
+ | **LightGBM** | 0.6936 | 0.5321 | 0.4834 | 0.4818 | 0.7266 |
109
+
110
+ ### Interpretation
111
+
112
+ On the independent 66-well benchmark, Random Forest achieved the highest depth-level accuracy, macro F1, confident macro F1, and sequence similarity among the three evaluated models.
113
+
114
+ The results show that strong cross-validation performance does not necessarily translate directly into equivalent performance on independent wells. This is particularly relevant for subsurface machine learning, where geological setting, depositional environment, logging conditions, and formation properties can vary substantially between wells.
115
+
116
+ ---
117
+
118
+ # Blind-Well Generalization Test
119
+
120
+ In addition to the 66-well benchmark, the models were evaluated on a completely unseen blind well (`16_2-7.csv`).
121
+
122
+ | Model | Original Training Benchmark | Blind Test Well Accuracy | Approx. Performance Gap |
123
+ | ----------------- | --------------------------: | -----------------------: | -----------------------: |
124
+ | **Random Forest** | ~85–90% | **60.17%** | ~25–30 percentage points |
125
+ | **XGBoost** | ~88–91% | **44.95%** | ~43–46 percentage points |
126
+ | **LightGBM** | ~89–92% | **40.65%** | ~48–51 percentage points |
127
+
128
+ These values represent a separate blind-well experiment and should not be directly substituted for the 66-well benchmark metrics above.
129
+
130
+ The blind-well experiment demonstrates the importance of testing lithology models on genuinely unseen geological conditions rather than relying exclusively on conventional validation splits.
131
+
132
+ ---
133
+
134
+ # Key Research Findings
135
+
136
+ ### 1. Generalization is substantially harder than within-dataset validation
137
+
138
+ The difference between validation performance and performance on independent wells indicates that the models learn relationships that do not necessarily transfer perfectly across geological settings.
139
+
140
+ For lithology prediction, this can arise from differences in formation properties, depositional environments, logging tools, acquisition conditions, depth distributions, and the statistical distribution of log responses between wells.
141
+
142
+ ### 2. Random Forest showed stronger independent-well performance
143
+
144
+ Random Forest produced the strongest results across the principal metrics in the 66-well benchmark:
145
+
146
+ * **79.14% depth accuracy**
147
+ * **0.628 depth macro F1**
148
+ * **0.590 confident macro F1**
149
+ * **0.593 sequence similarity**
150
+
151
+ It also achieved the highest accuracy in the separate blind-well experiment at **60.17%**.
152
+
153
+ This does not establish that Random Forest will universally outperform boosting methods, but it indicates that it was the most robust of the three models under these particular evaluation conditions.
154
+
155
+ ### 3. Boosting models showed larger degradation on the blind well
156
+
157
+ XGBoost and LightGBM achieved strong cross-validation results but experienced substantial degradation on the independent blind well.
158
+
159
+ This suggests that the relationships learned from the training wells may not transfer consistently to the feature distributions encountered in the blind well.
160
+
161
+ ### 4. Sandstone remains a significant classification challenge
162
+
163
+ The blind-well analysis showed particularly weak sandstone recall across the evaluated models despite substantially stronger performance during training/validation.
164
+
165
+ This suggests that the petrophysical signature of sandstone in the blind well differs from the patterns represented in the training wells.
166
+
167
+ Potential contributing factors include differences in:
168
+
169
+ * Gamma Ray response
170
+ * Density
171
+ * Neutron porosity
172
+ * Resistivity
173
+ * Compaction
174
+ * Depositional environment
175
+ * Formation composition
176
+ * Logging/acquisition conditions
177
+
178
+ This makes sandstone generalization an important area for further investigation.
179
+
180
+ ---
181
+
182
+ # Research Implications
183
+
184
+ These experiments highlight an important issue in automated lithology prediction:
185
+
186
+ > **High validation performance does not necessarily imply strong geological generalization.**
187
+
188
+ A model can perform well when evaluated on data statistically similar to its training wells while experiencing substantial performance degradation when exposed to a genuinely independent well.
189
+
190
+ For this reason, future versions of the benchmark should emphasize:
191
+
192
+ * Well-level separation between training and evaluation data
193
+ * Geographic and geological diversity
194
+ * Cross-basin evaluation
195
+ * Completely held-out wells
196
+ * Class-specific performance
197
+ * Sequence-level similarity
198
+ * Robustness to missing logs
199
+ * Distribution-shift analysis
200
+ * Calibration and uncertainty estimation
201
+
202
+ The benchmark is therefore intended not simply to measure classification accuracy, but to investigate how well lithology models transfer across independent subsurface environments.
203
+
204
+ ---
205
+
206
+ # Reproducibility
207
+
208
+ The trained model artifacts are provided in the `models/` directory.
209
+
210
+ ```text
211
+ models/
212
+ β”œβ”€β”€ random_forest.joblib
213
+ β”œβ”€β”€ random_forest_params.json
214
+ β”œβ”€β”€ xgboost.joblib
215
+ β”œβ”€β”€ xgboost_params.json
216
+ β”œβ”€β”€ lightgbm.joblib
217
+ └── lightgbm_params.json
218
  ```
219
 
220
+ The training data and independent benchmark are publicly available through the NORA Research Lab Hugging Face organization.
221
+
222
+ **Training dataset:**
223
+ https://huggingface.co/datasets/NoraResearchLab/Lithology-Training-Dataset
224
+
225
+ **Evaluation benchmark:**
226
+ https://huggingface.co/datasets/NoraResearchLab/lithology-sequence-benchmark
227
+
228
+ ---
229
+
230
+ # Citation
231
+
232
+ If you use these models, datasets, or benchmark results in research, please cite the corresponding NORA Research Lab resources.
233
+
234
+ ## NORA Research Lab
235
+
236
+ **Building intelligence for the real world.**
237
 
238
+ GitHub: https://github.com/Nora-Research-Lab
239
+ Hugging Face: https://huggingface.co/NoraResearchLab
240
+ LinkedIn: https://www.linkedin.com/company/nora-research-lab
241
+ X: https://x.com/noraresearchlab
242
+ Website: https://noraresearchlab.site