(self, sample_lists)
Run iteration of PI-based guided policy search.

        Args:
            sample_lists: List of SampleList objects for each condition.
Run iteration of PI-based guided policy search.
Run iteration of PI - based guided policy search .
def iteration(self, sample_lists):
        """
        Run iteration of PI-based guided policy search.

        Args:
            sample_lists: List of SampleList objects for each condition.
        """
        # Store the samples and evaluate the costs.
        for m in range(self.M):
            self.cur[m].sample_list = sample_lists[m]
            self._eval_cost(m)

        # On the first iteration, need to catch policy up to init_traj_distr.
        if self.iteration_count == 0:
            self.new_traj_distr = [
                self.cur[cond].traj_distr for cond in range(self.M)
            ]
            self._update_policy()

        # Update policy linearizations.
        for m in range(self.M):
            self._update_policy_fit(m)

        # C-step        
        self._update_trajectories()

        # S-step
        self._update_policy()

        # Prepare for next iteration
        self._advance_iteration_variables()
def iteration ( self , sample_lists ) : # Store the samples and evaluate the costs. for m in range ( self . M ) : self . cur [ m ] . sample_list = sample_lists [ m ] self . _eval_cost ( m ) # On the first iteration, need to catch policy up to init_traj_distr. if self . iteration_count == 0 : self . new_traj_distr = [ self . cur [ cond ] . traj_distr for cond in range ( self . M ) ] self . _update_policy ( ) # Update policy linearizations. for m in range ( self . M ) : self . _update_policy_fit ( m ) # C-step         self . _update_trajectories ( ) # S-step self . _update_policy ( ) # Prepare for next iteration self . _advance_iteration_variables ( )