Miaoran000
commited on
Commit
•
487d19f
1
Parent(s):
2c44150
fix typo
Browse files
README.md
CHANGED
@@ -94,7 +94,7 @@ classifier = pipeline(
|
|
94 |
full_scores = classifier(input_pairs, top_k=None) # List[List[Dict[str, float]]]
|
95 |
|
96 |
# Optional: Extract the scores for the 'consistent' label
|
97 |
-
simple_scores = [score_dict['score'] for
|
98 |
|
99 |
print(simple_scores)
|
100 |
# Expected output: [0.011061512865126133, 0.6473632454872131, 0.1290171593427658, 0.8969419002532959, 0.18462494015693665, 0.005031010136008263, 0.05432349815964699]
|
|
|
94 |
full_scores = classifier(input_pairs, top_k=None) # List[List[Dict[str, float]]]
|
95 |
|
96 |
# Optional: Extract the scores for the 'consistent' label
|
97 |
+
simple_scores = [score_dict['score'] for score_for_both_labels in full_scores for score_dict in score_for_both_labels if score_dict['label'] == 'consistent']
|
98 |
|
99 |
print(simple_scores)
|
100 |
# Expected output: [0.011061512865126133, 0.6473632454872131, 0.1290171593427658, 0.8969419002532959, 0.18462494015693665, 0.005031010136008263, 0.05432349815964699]
|