log_error#
- pymc_marketing.mlflow.log_error(func, file_name)[source]#
Log arbitrary caught error and traceback to MLflow.
Note
The error will still be raised with the program. It is just logged to MLflow
- Parameters:
- func
Callable
Arbitrary function
- file_name
str
The name of the MLflow artifact
- func
Examples
import mlflow from pymc_marketing.mlflow import log_error def raising_function(): raise NotImplementedError("Sorry. Not implemented") func = log_error(raising_function, file_name="raising-function") with mlflow.start_run(): func()