Skip to content

No predictions by the model #26

Description

@anushkasw

I am trying to apply this model to some other datasets. I found that at times the model gives no predictions.
I found that it might be happening due to setting the relation logit output shape to num_classes+1
self.decoder2class = nn.Linear(config.hidden_size, num_classes + 1)

and then not creating triples when relation predicted was equal to num_classes
def generate_strategy(pred_rel, pred_head, pred_tail, num_classes, _Pred_Triple):
if pred_rel.pred_rel != num_classes:

Can somebody help me understand why this is done this way?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions