code: def construct_data_store_params(json: dict):
      ds_params_instance = None
      ds_params = DataStoreParameters(
          json["store_type"],
          json["orchestrator_type"],
          json["orchestrator_params"],
      )
      if json["store_type"] == "nfs":
          ds_params_instance = NFSDataStoreParameters(
              ds_params, checkpoint_dir=json["checkpoint_dir"]
          )
      elif json["store_type"] == "s3":
          ds_params_instance = S3DataStoreParameters(
              ds_params=ds_params,
              end_point=json["end_point"],
              bucket_name=json["bucket_name"],
              checkpoint_dir=json["checkpoint_dir"],
              expt_dir=json["expt_dir"],
          )
      elif json["store_type"] == "redis":
          ds_params_instance = RedisDataStoreParameters(
              ds_params,
              redis_address=json["redis_address"],
              redis_port=json["redis_port"],
              redis_channel=json["redis_channel"],
          )
      else:
          raise ValueError(
              "store_type {} was found, expected 'nfs', 'redis' or 's3'."
          )
  
      return ds_params_instance
  
imports: from rl_coach.data_stores.nfs_data_store import NFSDataStore, NFSDataStoreParameters
  from rl_coach.data_stores.s3_data_store import S3DataStore, S3DataStoreParameters
  from rl_coach.data_stores.redis_data_store import RedisDataStore, RedisDataStoreParameters
  from rl_coach.data_stores.data_store import DataStoreParameters
label_desc: Use image node_id 2 for calling a global function with example usage: construct_data_store_params(json) and returns: ds_params_instance