code: def get_leaderboard_pareto_frontier(
      leaderboard: DataFrame,
      score_col="score_val",
      inference_time_col="pred_time_val_full",
  ) -> DataFrame:
      """
      Given a set of models, returns in ranked order from best score to worst score models which satisfy the criteria:
      1. No other model in the set has both a lower inference time and a better or equal score.
  
      :param leaderboard: Leaderboard DataFrame of model info containing score_col and inference_time_col
      :param score_col: Column name in leaderboard of model score values
      :param inference_time_col: Column name in leaderboard of model inference times
      :return: Subset of the original leaderboard DataFrame containing only models that are a valid optimal choice at different valuations of score and inference time.
      """
      leaderboard = leaderboard.sort_values(
          by=[score_col, inference_time_col], ascending=[False, True]
      ).reset_index(drop=True)
      leaderboard_unique = leaderboard.drop_duplicates(
          subset=[score_col]
      )
  
      pareto_frontier = []
      inference_time_min = None
      for index, row in leaderboard_unique.iterrows():
          if row[inference_time_col] is None or row[score_col] is None:
              pass
          elif (inference_time_min is None) or (
              row[inference_time_col] < inference_time_min
          ):
              inference_time_min = row[inference_time_col]
              pareto_frontier.append(index)
      leaderboard_pareto_frontier = leaderboard_unique.loc[
          pareto_frontier
      ].reset_index(drop=True)
      return leaderboard_pareto_frontier
  
imports: import logging
  import math
  import pickle
  import random
  import sys
  import time
  from typing import Callable, List, Tuple, Union
  import numpy
  import pandas
  import scipy.stats
  from numpy.typing import ArrayLike
  from pandas import DataFrame, Series
  from sklearn.model_selection import LeaveOneGroupOut, RepeatedKFold, RepeatedStratifiedKFold, train_test_split
  from autogluon.common.utils.resource_utils import ResourceManager
  from ..constants import BINARY, LARGE_DATA_THRESHOLD, MULTICLASS, MULTICLASS_UPPER_LIMIT, QUANTILE, REGRESS_THRESHOLD_LARGE_DATA, REGRESS_THRESHOLD_SMALL_DATA, REGRESSION, SOFTCLASS
  from ..metrics import Scorer, accuracy, pinball_loss, root_mean_squared_error
  from .miscs import warning_filter
label_desc: Use image node_id 3 for calling a global function with example usage: get_leaderboard_pareto_frontier(leaderboard, score_col, inference_time_col) and returns: leaderboard_pareto_frontier