code: def _actor_learn(self, obs_n, act_n):
      i = self.agent_index
  
      sample_this_action = self.sample(obs_n[i])
      action_input_n = act_n + []
      action_input_n[i] = sample_this_action
      eval_q = self.Q(obs_n, action_input_n)
      act_cost = torch.mean(-1.0 * eval_q)
  
      this_policy = self.model.policy(obs_n[i])
      # when continuous, 'this_policy' will be a tuple with two element: (mean, std)
      if self.continuous_actions:
          this_policy = torch.cat(this_policy, dim=-1)
      act_reg = torch.mean(torch.square(this_policy))
  
      cost = act_cost + act_reg * 1e-3
  
      self.actor_optimizer.zero_grad()
      cost.backward()
      torch.nn.utils.clip_grad_norm_(self.model.get_actor_params(), 0.5)
      self.actor_optimizer.step()
      return cost
  
file_path: PARL/parl/algorithms/torch/maddpg.py
imports: import parl
  import torch
  import torch.nn
  import torch.nn.functional
  from parl.utils.utils import check_model_method
  from copy import deepcopy
label_desc: Use image node_id 6 for calling the MADDPG obj's underlying member method code with example usage: obj._actor_learn(obs_n, act_n) and returns: cost