@@ -1328,7 +1328,7 @@ def convert_db(db, filepath=None):
1328
1328
return cls (dashboards , ** update_kwargs (config , ** update_params ))
1329
1329
1330
1330
def to_yaml (self , filepath :Path = None , dump_explainers = True ,
1331
- return_dict = False , integrate_dashboard_yamls = False ):
1331
+ return_dict = False , integrate_dashboard_yamls = False , pickle_type = "joblib" ):
1332
1332
"""Store ExplainerHub to configuration .yaml, store the users to users.json
1333
1333
and dump the underlying dashboard .yamls and explainers.
1334
1334
@@ -1347,6 +1347,8 @@ def to_yaml(self, filepath:Path=None, dump_explainers=True,
1347
1347
separate_dashboard_yamls=True. Defaults to False.
1348
1348
integrate_dashboard_yamls(bool, optional): Do not generate an individual
1349
1349
.yaml file for each dashboard, but integrate them in hub.yaml.
1350
+ pickle_type ({'joblib', 'dill', 'pkl'}, optional). Format to dump explainers in.
1351
+ Defaults to "joblib". Alternatives are "dill" and "pkl".
1350
1352
1351
1353
Returns:
1352
1354
{dict, yaml, None}
@@ -1368,7 +1370,7 @@ def to_yaml(self, filepath:Path=None, dump_explainers=True,
1368
1370
for dashboard in self .dashboards :
1369
1371
print (f"Storing { dashboard .name } _dashboard.yaml..." )
1370
1372
dashboard .to_yaml (filepath .parent / (dashboard .name + "_dashboard.yaml" ),
1371
- explainerfile = filepath .parent / (dashboard .name + "_explainer.joblib " ),
1373
+ explainerfile = filepath .parent / (dashboard .name + f "_explainer.{ pickle_type } " ),
1372
1374
dump_explainer = dump_explainers )
1373
1375
hub_config = dict (
1374
1376
explainerhub = dict (
0 commit comments