original_docstring: 
          input dict requires key "X" contain a pandas dataframe. returns dict
          with keys "segment_info" containing dict of metadata about each segment
          and "segment_data" with a dict formatted as {segment_name: pd.DataFrame}
          
docstring: input dict requires key "X" contain a pandas dataframe. returns dict
  with keys "segment_info" containing dict of metadata about each segment
  and "segment_data" with a dict formatted as {segment_name: pd.DataFrame}
docstring_tokens: input dict requires key " X " contain a pandas dataframe . returns dict with keys " segment_info " containing dict of metadata about each segment and " segment_data " with a dict formatted as { segment_name : pd . DataFrame }
code: def process(self, input_data: dict) -> dict:
          '''
          input dict requires key "X" contain a pandas dataframe. returns dict
          with keys "segment_info" containing dict of metadata about each segment
          and "segment_data" with a dict formatted as {segment_name: pd.DataFrame}
          '''
          X = input_data['X']
  
          segments = self.stats['segment_info'].keys()
  
          out_data = {}
          out_info = {}
          for name in segments:
              idx = self.get_segment_idx(X, name)
              if len(idx) == 0:
                  continue
  
              out_data[name] = X.loc[idx].copy()
              out_info[name] = self.group_info(name)
  
          return {'segment_info': out_info,
                  'segment_data': out_data}
code_tokens: def process ( self , input_data : dict ) -> dict : X = input_data [ 'X' ] segments = self . stats [ 'segment_info' ] . keys ( ) out_data = { } out_info = { } for name in segments : idx = self . get_segment_idx ( X , name ) if len ( idx ) == 0 : continue out_data [ name ] = X . loc [ idx ] . copy ( ) out_info [ name ] = self . group_info ( name ) return { 'segment_info' : out_info , 'segment_data' : out_data }
short_docstring: input dict requires key "X" contain a pandas dataframe.
short_docstring_tokens: input dict requires key " X " contain a pandas dataframe .
comment: '''
          input dict requires key "X" contain a pandas dataframe. returns dict
          with keys "segment_info" containing dict of metadata about each segment
          and "segment_data" with a dict formatted as {segment_name: pd.DataFrame}
          '''