code: def feature_correlation(
      ctx: Context,
      role: Role,
      input_data: cpn.dataframe_input(roles=[GUEST, HOST]),
      local_only: cpn.parameter(
          type=bool,
          default=False,
          desc="whether only compute feature correlation locally, default False",
      ),
      calc_local_vif: cpn.parameter(
          type=bool,
          default=True,
          desc="whether compute local vif, default True",
      ),
      skip_col: cpn.parameter(
          type=List[str],
          default=None,
          optional=True,
          desc="columns to be skipped, default None; if None, feature_correlation will be computed over all columns",
      ),
      use_anonymous: cpn.parameter(
          type=bool,
          default=False,
          desc="bool, whether interpret `skip_col` as anonymous column names",
      ),
      output_model: cpn.json_model_output(roles=[GUEST, HOST]),
  ):
      from fate.ml.statistics import PearsonCorrelation
  
      sub_ctx = ctx.sub_ctx("train")
      input_data = input_data.read()
      select_cols = get_to_compute_cols(
          input_data.schema.columns,
          input_data.schema.anonymous_columns,
          skip_col,
          use_anonymous,
      )
  
      corr_computer = PearsonCorrelation(
          local_only=local_only,
          calc_local_vif=calc_local_vif,
          select_cols=select_cols,
      )
      input_data = input_data[select_cols]
      corr_computer.fit(sub_ctx, input_data)
  
      model = corr_computer.get_model()
      output_model.write(model, metadata={})
  
imports: from typing import List
  from fate.arch import Context
  from fate.components.core import GUEST, HOST, Role, cpn
label_desc: Use image node_id 1 for calling a global function with example usage: feature_correlation(ctx, role, input_data, local_only, calc_local_vif, skip_col, use_anonymous, output_model) without return types