class_docstr: RLRMC dataset implementation. Creates sparse data structures for RLRMC algorithm.
docstr: Initialize parameters.
  
  Args:
      train (pandas.DataFrame: training data with at least columns (col_user, col_item, col_rating)
      validation (pandas.DataFrame): validation data with at least columns (col_user, col_item, col_rating). validation can be None, if so, we only process the training data
      mean_center (bool): flag to mean center the ratings in train (and validation) data
      col_user (str): user column name
      col_item (str): item column name
      col_rating (str): rating column name
      col_timestamp (str): timestamp column name
docstr_tok: ["Initialize","parameters",".","Args",":","train","(","pandas.DataFrame",":","training","data","with","at","least","columns","(","col_user",",","col_item",",","col_rating",")","validation","(","pandas.DataFrame",")",":","validation","data","with","at","least","columns","(","col_user",",","col_item",",","col_rating",")",".","validation","can","be","None",",","if","so",",","we","only","process","the","training","data","mean_center","(","bool",")",":","flag","to","mean","center","the","ratings","in","train","(","and","validation",")","data","col_user","(","str",")",":","user","column","name","col_item","(","str",")",":","item","column","name","col_rating","(","str",")",":","rating","column","name","col_timestamp","(","str",")",":","timestamp","column","name"]
code: def __init__(
      self,
      train,
      validation=None,
      test=None,
      mean_center=True,
      col_user=DEFAULT_USER_COL,
      col_item=DEFAULT_ITEM_COL,
      col_rating=DEFAULT_RATING_COL,
      col_timestamp=DEFAULT_TIMESTAMP_COL,
      # seed=42,
  ):
      """Initialize parameters.
  
      Args:
          train (pandas.DataFrame: training data with at least columns (col_user, col_item, col_rating)
          validation (pandas.DataFrame): validation data with at least columns (col_user, col_item, col_rating). validation can be None, if so, we only process the training data
          mean_center (bool): flag to mean center the ratings in train (and validation) data
          col_user (str): user column name
          col_item (str): item column name
          col_rating (str): rating column name
          col_timestamp (str): timestamp column name
      """
      # initialize user and item index
      self.user_idx = None
      self.item_idx = None
  
      # get col name of user, item and rating
      self.col_user = col_user
      self.col_item = col_item
      self.col_rating = col_rating
      self.col_timestamp = col_timestamp
      # set random seed
      # random.seed(seed)
  
      # data preprocessing for training and validation data
      self._data_processing(train, validation, test, mean_center)
  
file_path: recommenders/recommenders/models/rlrmc/RLRMCdataset.py
imports: import numpy
  import pandas
  from scipy.sparse import csr_matrix
  from recommenders.utils.constants import DEFAULT_ITEM_COL, DEFAULT_USER_COL, DEFAULT_RATING_COL, DEFAULT_TIMESTAMP_COL
label_desc: Use image node_id 1 to create a new RLRMCdataset object from inherited base classes: object with example: obj = RLRMCdataset(train, validation, test, mean_center, col_user, col_item, col_rating, col_timestamp)