class_docstr: Transform data by scaling features to given feature range.
  Note that if `strict_range` is set, transformed values will always be within given range,
  regardless whether transform data exceeds training data value range (as in 1.x ver)
  
  The transformation is given by::
      X_scaled = (X - X.min()) / (X.max() - X.min()) * feature_range + feature_range_min
               = (X - X.min()) * (feature_range / (X.max() - X.min()) + feature_range_min
class_docstr_tok: ["Transform","data","by","scaling","features","to","given","feature","range",".","Note","that","if","`","strict_range","`","is","set",",","transformed","values","will","always","be","within","given","range",",","regardless","whether","transform","data","exceeds","training","data","value","range","(","as","in","1.x","ver",")","The","transformation","is","given","by",":",":","X_scaled","=","(","X","-","X.min","(",")",")","\/","(","X.max","(",")","-","X.min","(",")",")","*","feature_range","+","feature_range_min","=","(","X","-","X.min","(",")",")","*","(","feature_range","\/","(","X.max","(",")","-","X.min","(",")",")","+","feature_range_min"]
code: def fit(self, ctx: Context, train_data, validate_data=None) -> None:
      if self.select_col is None:
          self.select_col = train_data.schema.columns.to_list()
      train_data_select = train_data[self.select_col]
      data_max = train_data_select.max()
      data_min = train_data_select.min()
  
      # select_col has same keys as feature_range
      self._range_min = pd.Series(
          {col: self.feature_range[col][0] for col in self.select_col}
      )
      self._range_max = pd.Series(
          {col: self.feature_range[col][1] for col in self.select_col}
      )
  
      data_range = data_max - data_min
      # for safe division
      data_range[data_range < 1e-6] = 1.0
      self._scale = (self._range_max - self._range_min) / data_range
      self._scale_min = data_min * self._scale
  
imports: import logging
  import pandas
  from fate.arch import Context
  from ..abc.module import Module
label_desc: Use image node_id 2 for calling the MinMaxScaler obj's underlying member method code with example usage: obj.fit(ctx, train_data, validate_data) without return types