code: def vif_from_pearson_matrix(pearson_matrix, threshold=1e-8):
      logger.info(f"local vif calc: start")
      assert not torch.isnan(
          pearson_matrix
      ).any(), f"should not contains nan: {pearson_matrix}"
      N = pearson_matrix.shape[0]
      vif = []
      logger.info(f"local vif calc: calc matrix eigvals")
      eig, _ = torch.sort(
          torch.abs(torch.linalg.eigvalsh(pearson_matrix))
      )
      num_drop = torch.sum(eig < threshold).item()
      det_non_zero = torch.prod(eig[num_drop:])
      logger.info(f"local vif calc: calc submatrix eigvals")
      for i in range(N):
          indexes = [j for j in range(N) if j != i]
          cofactor_matrix = pearson_matrix[indexes][:, indexes]
          cofactor_eig, _ = torch.sort(
              torch.abs(torch.linalg.eigvalsh(cofactor_matrix))
          )
          vif.append(torch.prod(cofactor_eig[num_drop:]) / det_non_zero)
          logger.info(
              f"local vif calc: submatrix {i + 1}/{N} eig is {vif[-1]}"
          )
      logger.info(f"local vif calc done")
      return vif
  
file_path: FATE/python/fate/ml/statistics/pearson_correlation.py
imports: import logging
  import pandas
  import torch
  from fate.arch import Context
  from fate.arch.dataframe import DataFrame
  from ..abc.module import Module
label_desc: Use image node_id 3 for calling the PearsonCorrelation obj's underlying member method code with example usage: obj.vif_from_pearson_matrix(pearson_matrix, threshold) and returns: vif