I am trying out multiple linking in the model i have changed the "el_labels" shape to (2, self.max_seq_length) in order to give 2 links for each boxes, and i have changed the linking output by changing the parameter n_relations = 2
## in bros_dataset.py
### Line 410
el_labels = np.ones((2, self.max_seq_length), dtype=int) * self.max_seq_length
## in bros_spade_rel.py
### Line 51
self.relation_net = RelationExtractor(
n_relations=2,
backbone_hidden_size=self.backbone_hidden_size,
head_hidden_size=self.head_hidden_size,
head_p_dropout=self.head_p_dropout,
)
Anyone tell me how to change the loss function for the multi linking.
I am trying out multiple linking in the model i have changed the "el_labels" shape to (2, self.max_seq_length) in order to give 2 links for each boxes, and i have changed the linking output by changing the parameter n_relations = 2
Anyone tell me how to change the loss function for the multi linking.