VAR icon indicating copy to clipboard operation
VAR copied to clipboard

is it possible to get embedding of last layer of network and add softmax to get a Classifier

Open roodkcab opened this issue 1 year ago • 2 comments

roodkcab avatar Apr 14 '24 02:04 roodkcab

hi @roodkcab, maybe you can add a classifier linear layer in VAR byself.head2 = nn.Linear(self.C, classification_classes) and replace self.head(self.head_nm(h.float(), cond_BD).float()).float() with self.head2(self.head_nm(h.float(), cond_BD).float().mean(dim=1)).float() in models/var.py to get your classification logits.

keyu-tian avatar Apr 15 '24 22:04 keyu-tian

great! I'll have a look. really impressive work! thanks again.

roodkcab avatar Apr 16 '24 09:04 roodkcab