code: def testPredictionDiff():
      spark = test_helpers.getOrCreateSparkSession(
          test_helpers.getCurrentMethodName()
      )
      import catboost_spark
  
      dataDir = os.path.join(config.CATBOOST_TEST_DATA_DIR, "higgs")
  
      trainPool = catboost_spark.Pool.load(
          spark,
          dataPathWithScheme=os.path.join(dataDir, "train_small"),
          columnDescription=os.path.join(dataDir, "train.cd"),
      )
      dataForPredictionDiff = catboost_spark.Pool(
          trainPool.data.limit(2)
      )
  
      regressor = (
          catboost_spark.CatBoostRegressor()
          .setIterations(20)
          .setTrainDir(
              tempfile.mkdtemp(
                  prefix=test_helpers.getCurrentMethodName()
              )
          )
      )
      model = regressor.fit(trainPool)
  
      featureImportances = model.getFeatureImportance(
          fstrType=catboost_spark.EFstrType.PredictionDiff,
          data=dataForPredictionDiff,
      )
      print("featureImportancesPredictionDiff=")
      print(featureImportances)
  
      featureImportancesPrettified = (
          model.getFeatureImportancePrettified(
              fstrType=catboost_spark.EFstrType.PredictionDiff,
              data=dataForPredictionDiff,
          )
      )
  
      print("featureImportancesPredictionDiffPrettified=")
      for e in featureImportancesPrettified:
          print(
              "featureName={},importance={}".format(
                  e.featureName(), e.importance()
              )
          )
  
file_path: catboost/catboost/spark/catboost4j-spark/core/src/test/python/feature_importance_test.py
imports: import os
  import tempfile
  import config
  import test_helpers
label_desc: Use image node_id 8 for calling a global function with example usage: testPredictionDiff() without return types