class_docstr: This evaluator can be used with the CrossEncoder class. Given sentence pairs and binary labels (0 and 1),
  it compute the average precision and the best possible f1 score
code: def from_input_examples(cls, examples: List[InputExample], **kwargs):
      sentence_pairs = []
      labels = []
  
      for example in examples:
          sentence_pairs.append(example.texts)
          labels.append(example.label)
      return cls(sentence_pairs, labels, **kwargs)
  
file_path: sentence-transformers/sentence_transformers/cross_encoder/evaluation/CEBinaryClassificationEvaluator.py
imports: import logging
  from sklearn.metrics import average_precision_score
  from typing import List
  import numpy
  import os
  import csv
  from ...None import InputExample
  from ...evaluation import BinaryClassificationEvaluator
label_desc: Use image node_id 2 for calling the CEBinaryClassificationEvaluator obj's underlying member method code with example usage: obj.from_input_examples(cls, examples) and returns: cls