code: def to_distributed(spark, df):
      return spark.createDataFrame(df).repartition(2, "unique_id")
  
file_path: statsforecast/action_files/test_spark.py
imports: import sys
  import pytest
  from pyspark.sql import SparkSession
  from .utils import pipeline, pipeline_with_level, pipeline_fitted
label_desc: Use image node_id 2 for calling a global function with example usage: to_distributed(spark, df) and returns: spark