code: def _get_grouped_data_and_base_points(sensitive_feature_value):
      data = pd.DataFrame(
          {
              SENSITIVE_FEATURE_KEY: sensitive_features_ex1.squeeze(),
              SCORE_KEY: scores_ex.squeeze(),
              LABEL_KEY: labels_ex.squeeze(),
          }
      )
      grouped_data = (
          data.groupby(SENSITIVE_FEATURE_KEY)
          .get_group(sensitive_feature_value)
          .sort_values(by=SCORE_KEY, ascending=False)
      )
      x_grid = np.linspace(0, 1, 100)
  
      if sensitive_feature_value == "A":
          expected_roc_points = pd.DataFrame(
              {
                  "x": [0, 0.25, 0.5, 0.5, 1],
                  "y": [0, 1 / 3, 2 / 3, 1, 1],
                  "operation": [
                      ThresholdOperation(">", np.inf),
                      ThresholdOperation("<", 0.5),
                      ThresholdOperation("<", 1.5),
                      ThresholdOperation("<", 2.5),
                      ThresholdOperation(">", -np.inf),
                  ],
              }
          )
          ignore_for_base_points = [1, 2]
  
      if sensitive_feature_value == "B":
          expected_roc_points = pd.DataFrame(
              {
                  "x": [0, 1 / 3, 1],
                  "y": [0, 3 / 4, 1],
                  "operation": [
                      ThresholdOperation(">", np.inf),
                      ThresholdOperation("<", 0.5),
                      ThresholdOperation(">", -np.inf),
                  ],
              }
          )
          ignore_for_base_points = []
  
      if sensitive_feature_value == "C":
          expected_roc_points = pd.DataFrame(
              {
                  "x": [0, 0, 2 / 3, 1],
                  "y": [0, 1 / 3, 1, 1],
                  "operation": [
                      ThresholdOperation(">", np.inf),
                      ThresholdOperation("<", 0.5),
                      ThresholdOperation("<", 1.5),
                      ThresholdOperation(">", -np.inf),
                  ],
              }
          )
          ignore_for_base_points = [0]
  
      return (
          grouped_data,
          expected_roc_points,
          ignore_for_base_points,
          x_grid,
      )
  
imports: from collections import defaultdict, namedtuple
  from test.unit.input_convertors import _map_into_single_column, ensure_dataframe, ensure_list_1d, ensure_ndarray, ensure_ndarray_2d, ensure_series
  import numpy
  import pandas
  import pytest
  from sklearn.base import BaseEstimator, ClassifierMixin
  from fairlearn.postprocessing._constants import LABEL_KEY, SCORE_KEY, SENSITIVE_FEATURE_KEY
  from fairlearn.postprocessing._threshold_operation import ThresholdOperation
label_desc: Use image node_id 6 for calling a global function with example usage: _get_grouped_data_and_base_points(sensitive_feature_value) and returns: grouped_data,  expected_roc_points,  ignore_for_base_points,  x_grid