bitsim
Model, simulate, estimate and control robots in C++
Loading...
Searching...
No Matches
rl_example_11::PPOConfig Struct Reference

The PPOConfig struct. Configuration for PPOSolver class. More...

#include <ppo_config.h>

Public Member Functions

std::ostream & print (std::ostream &out) const
 print
void load_from_json (const std::string &filename)
 Load the configuration from the given json file.

Public Attributes

real_t gamma {0.99}
 Discount factor.
real_t epsilon {0.01}
 The epsilon factor to use.
bool clip_policy_grad {false}
 Flag indicating whether to clip the policy grad.
bool clip_critic_grad {false}
 Flag indicating whether to clip the critic grad.
real_t max_grad_norm_policy {1.0}
 The value to clip the gradient for the policy.
real_t max_grad_norm_critic {1.0}
 The value to clip the gradient for the actor.
uint_t n_episodes {100}
 Number of training episodes.
uint_t max_itrs_per_episode {100}
 Number of iterations per episode.
uint_t buffer_size {100}
 How large the experince buffer should be.
uint_t max_passes_over_batch {4}
real_t clip_epsilon {0.5}
bool normalize_advantages {true}
DeviceType device_type {DeviceType::CPU}
std::string save_model_path {""}

Detailed Description

The PPOConfig struct. Configuration for PPOSolver class.

Member Function Documentation

◆ load_from_json()

void bitrl::rl::algos::pg::PPOConfig::load_from_json ( const std::string & filename)

Load the configuration from the given json file.

◆ print()

std::ostream & bitrl::rl::algos::pg::PPOConfig::print ( std::ostream & out) const

print

Parameters
out
Returns

Member Data Documentation

◆ buffer_size

How large the experince buffer should be.

◆ clip_critic_grad

Flag indicating whether to clip the critic grad.

◆ clip_epsilon

◆ clip_policy_grad

Flag indicating whether to clip the policy grad.

◆ device_type

◆ epsilon

The epsilon factor to use.

◆ gamma

◆ max_grad_norm_critic

The value to clip the gradient for the actor.

◆ max_grad_norm_policy

The value to clip the gradient for the policy.

◆ max_itrs_per_episode

Number of iterations per episode.

◆ max_passes_over_batch

◆ n_episodes

Number of training episodes.

◆ normalize_advantages

◆ save_model_path


The documentation for this struct was generated from the following file: