pycox icon indicating copy to clipboard operation
pycox copied to clipboard

Softmax layer and residual connections in DeepHitSingle model

Open Anivader opened this issue 2 years ago • 1 comments

Hi,

I am following this DeepHit tutorial for a single event - https://github.com/havakv/pycox/blob/master/examples/deephit.ipynb

In the model architecture, the "MLPVanilla" class inserts 2 hidden, linear layers. It seems like you don't have a "Softmax" layer at the end to obtain the survival probability distribution. Is this because it is already included in the loss function or do we not need to use it at all ?

net = tt.practical.MLPVanilla(in_features, num_nodes, out_features, batch_norm, dropout) model = DeepHitSingle(net, tt.optim.Adam, alpha=0.2, sigma=0.1, duration_index=labtrans.cuts)

Also, it seems like you are not implementing "residual connections " as mentioned in the DeepHit paper. Could you please explain the reason for this ?

Thanks Ani

Anivader avatar Aug 16 '23 17:08 Anivader

You can use whatever pytorch network you want and use that for your net variable

shahidhaider-altis avatar Dec 04 '23 18:12 shahidhaider-altis