I was able to train a DeepSurv model following the tutorial, but I was wondering if I can save the trained model. I tried to pickle it, but it generates the following error:
AttributeError: Can't pickle local object '_ActionOnBestMetric.on_fit_start.<locals>.<lambda>'
I also attempted to use state_dict, but CoxPH doesn't have such an attribute.
In the end, I would like to create a checkpoint so that I can save and load models. Could you please let me know if there's a method? Thank you.
Hi,
I was able to train a DeepSurv model following the tutorial, but I was wondering if I can save the trained model. I tried to pickle it, but it generates the following error:
AttributeError: Can't pickle local object '_ActionOnBestMetric.on_fit_start.<locals>.<lambda>'
I also attempted to use
state_dict
, but CoxPH doesn't have such an attribute.In the end, I would like to create a checkpoint so that I can save and load models. Could you please let me know if there's a method? Thank you.