Closed bblodfon closed 2 years ago
Heya thanks for raising the issue. To be very honest I've never had success in tuning {survivalsvm} successfully (even outside of this package). It's been buggy for ages and I'm unconvinced by the underlying implementation.
Just looking at your code above some quick comments: 1) I'd always recommend using hybrid
and never tune by type as all others are just a special case of hybrid
when gamma
or mu
are 0. 2) I've noticed choice of kernel can affect crashing.
Would you mind experimenting with {survivalsvm} directly and not via mlr3proba to see if the problem persists?
Hi Raphael,
Great to find another person who has found survival SVMs unstable. I wouldn't recommend this learner to anyone unless hyperparameters are hand-picked and no proper tuning is applied (which is, well, not nice).
I did some tests with hybrid
type while tuning the gamma.mu
and kernel
and it seems to be the case that the polynomial kernel is the one that causes the issue (but that may depend on the dataset or other things of course, I have no idea). An example hyperparameter configuration that fails is the following:
library(survivalsvm)
#> Loading required package: survival
fit = survivalsvm(Surv(time, status) ~ ., data = veteran, type = 'hybrid',
gamma.mu = c(0.76, 0.09), diff.meth = 'makediff3',
kernel = 'poly_kernel')
#> Error in tcrossprod(K, Dc): non-conformable arguments
Created on 2022-08-21 by the reprex package (v2.0.1)
Yup, buggy! I'm going to close the issue here. I don't think we should add a warning to the learner as in reality it will just perform badly and people will choose other learners. You might want to consider opening an issue in survivalsvm though?
Hi,
I made some effort to train and tune survival SVMs in a small dataset. Using a simple autotune example, I found out that the SVM survival learner can either fail (some fault with the optimization solvers I think) or get stuck (training never ends, CPU at 100%). I used a
lrn('surv.kaplan')
as afallback
learner and added alearner$timeout
to deal with these issues but I think that this instability is a bad sign for a learner. These issues mostly relate to the choice oftype
: whenever it's notregression
there is a high chance that you will face such issues (C-indexes are close to0.5
in the example below from using the kaplan estimator). I have seen the SVM learner fail also whentype=regression
(more sparsely).I post the following tuning example here so that others benefit from this investigation. Commenting the
learner$fallback
andlearner$timeout
lines will lead to the issues I mentioned.Created on 2022-08-15 by the reprex package (v2.0.1)