code: def test_logistic_regression_transform(spark):
      covdf = pd.read_csv(f"{data_root}/cov.csv").set_index("sample_id")
      covdf.index = covdf.index.astype(str, copy=False)
      lvl1df = spark.read.parquet(
          f"{data_root}/bt_reduceded_1part.snappy.parquet"
      )
      sample_blocks_df = (
          spark.read.parquet(f"{data_root}/groupedIDs.snappy.parquet")
          .withColumn(
              "sample_block", f.col("sample_block").cast("string")
          )
          .withColumn(
              "sample_ids",
              f.expr("transform(sample_ids, v -> cast(v as string))"),
          )
      )
      sample_blocks = {
          r.sample_block: r.sample_ids
          for r in sample_blocks_df.collect()
      }
      with open(
          f"{data_root}/test_logistic_regression_transform.json"
      ) as json_file:
          test_values = json.load(json_file)
  
      logreg = LogisticRidgeRegression(
          lvl1df, labeldf, sample_blocks, covdf, alphas=alpha_values
      )
      logreg.fit()
      wgr_cov_df = logreg.transform()
      wgr_cov_glow = wgr_cov_df[test_label].to_numpy()
  
      assert np.allclose(np.array(test_values["wgr_cov"]), wgr_cov_glow)
  
file_path: glow/python/glow/wgr/tests/test_logistic_ridge_regression.py
imports: from pyspark.sql.functions import PandasUDFType
  from glow.wgr.logistic_udfs import *
  from glow.wgr.logistic_ridge_regression import *
  from pyspark.sql import functions
  import json
  import pandas
  import numpy
label_desc: Use image node_id 6 for calling a global function with example usage: test_logistic_regression_transform(spark) without return types