docstr: Fit model to current data batch + previous data batch
          
docstr_tok: ["Fit","model","to","current","data","batch","+","previous","data","batch"]
code: def value_learn(self, obs, value):
      """Fit model to current data batch + previous data batch"""
      data_size = obs.shape[0]
  
      if self.value_learn_buffer is None:
          obs_train, value_train = obs, value
      else:
          obs_train = np.concatenate([obs, self.value_learn_buffer[0]])
          value_train = np.concatenate(
              [value, self.value_learn_buffer[1]]
          )
      self.value_learn_buffer = (obs, value)
  
      all_loss = []
      for _ in range(self.value_learn_times):
          random_ids = np.arange(obs_train.shape[0])
          np.random.shuffle(random_ids)
          shuffle_obs_train = obs_train[random_ids]
          shuffle_value_train = value_train[random_ids]
          start = 0
          while start < data_size:
              end = start + self.value_batch_size
              value_loss = self._batch_value_learn(
                  shuffle_obs_train[start:end, :],
                  shuffle_value_train[start:end],
              )
              all_loss.append(value_loss)
              start += self.value_batch_size
      return np.mean(all_loss)
  
file_path: PARL/benchmark/fluid/PPO/mujoco_agent.py
imports: import numpy
  import parl
  from parl import layers
  from paddle import fluid
  from parl.utils import logger
label_desc: Use image node_id 9 for calling the MujocoAgent obj's underlying member method code with example usage: obj.value_learn(obs, value) and returns: np