@@ -293,11 +293,15 @@ def from_processor(cls, processor):
293
293
model .data = processor .data
294
294
if processor .fault_properties is not None :
295
295
for i in processor .fault_network .faults :
296
- model .create_and_add_fault (
297
- i ,
298
- ** processor .fault_properties .to_dict ("index" )[i ],
299
- faultfunction = "BaseFault" ,
300
- )
296
+ try :
297
+
298
+ model .create_and_add_fault (
299
+ i ,
300
+ ** processor .fault_properties .to_dict ("index" )[i ],
301
+ faultfunction = "BaseFault" ,
302
+ )
303
+ except Exception as e :
304
+ logger .error (f"Error adding fault { i } \n { e } " )
301
305
for (
302
306
edge ,
303
307
properties ,
@@ -340,9 +344,13 @@ def from_processor(cls, processor):
340
344
if processor .fault_stratigraphy is not None :
341
345
faults = processor .fault_stratigraphy [s ]
342
346
logger .info (f"Adding foliation { s } " )
343
- f = model .create_and_add_foliation (
344
- s , ** processor .foliation_properties [s ], faults = faults
345
- )
347
+ try :
348
+ f = model .create_and_add_foliation (
349
+ s , ** processor .foliation_properties [s ], faults = faults
350
+ )
351
+ except Exception as e :
352
+ logger .error (f"Error adding foliation { s } \n { e } " )
353
+ f = None
346
354
if not f :
347
355
logger .warning (f"Foliation { s } not added" )
348
356
# check feature was built, and is an interpolated feature.
@@ -1326,7 +1334,6 @@ def create_and_add_fault(
1326
1334
minor_axis = kwargs ["fault_influence" ]
1327
1335
if "fault_vectical_radius" in kwargs and intermediate_axis is None :
1328
1336
intermediate_axis = kwargs ["fault_vectical_radius" ]
1329
-
1330
1337
logger .info (f'Creating fault "{ fault_surface_data } "' )
1331
1338
logger .info (f"Displacement: { displacement } " )
1332
1339
logger .info (f"Tolerance: { tol } " )
@@ -1370,7 +1377,7 @@ def create_and_add_fault(
1370
1377
self ._add_faults (fault_frame_builder , features = faults )
1371
1378
# add data
1372
1379
fault_frame_data = self .data .loc [self .data ["feature_name" ] == fault_surface_data ].copy ()
1373
-
1380
+ print ( fault_surface_data , fault_center )
1374
1381
if fault_center is not None and ~ np .isnan (fault_center ).any ():
1375
1382
fault_center = self .scale (fault_center , inplace = False )
1376
1383
if minor_axis :
0 commit comments