MCPcopy Create free account
hub / github.com/PaddlePaddle/Research / false_func

Method false_func

NLP/UNIMO-2/src/model/unimo_grounded.py:1064–1069  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1062 res = paddle.is_empty(x=valid_img2txt_ind)
1063
1064 def false_func():
1065 valid_matching_softmax = paddle.gather(x=matching_softmax, index=valid_img2txt_ind)
1066 valid_labels = paddle.gather(x=labels, index=valid_img2txt_ind)
1067 valid_labels = paddle.reshape(x=valid_labels, shape=[-1, 1])
1068 matching_acc = paddle.metric.accuracy(input=valid_matching_softmax, label=valid_labels)
1069 return matching_acc
1070
1071 def true_func():
1072 return paddle.zeros(shape=[1], dtype='float32')

Callers

nothing calls this directly

Calls 1

accuracyMethod · 0.80

Tested by

no test coverage detected