code: def discount_cumsum(self, x, gamma):
      discount_cumsum = np.zeros_like(x)
      discount_cumsum[-1] = x[-1]
      for t in reversed(range(x.shape[0] - 1)):
          discount_cumsum[t] = x[t] + gamma * discount_cumsum[t + 1]
      return discount_cumsum
  
file_path: PARL/benchmark/torch/DT/data_loader.py
imports: import numpy
  import pickle
  import random
  import torch
  from parl.utils import logger
label_desc: Use image node_id 3 for calling the DataLoader obj's underlying member method code with example usage: obj.discount_cumsum(x, gamma) and returns: discount_cumsum