# parameters for the MDP
env:
  # general
  num_envs: 1024
  env_spacing: 5
  episode_length: 1000

  # step parameters
  control_frequency_inv: 2 # 60 Hz
  # actions parameters
  power_scale: 0.5
  # observations parameters
  angular_velocity_scale: 1.0
  dof_velocity_scale: 0.2
  contact_force_scale: 0.1

  # reward parameters
  heading_weight: 0.5
  up_weight: 0.1
  alive_weight: 0.5
  # cost parameters
  actions_cost: 0.005
  energy_cost: 0.05
  joints_at_limit_cost: 0.1
  # termination parameters
  death_cost: -2.0
  termination_height: 0.31

# parameters for setting up the scene
scene:

  ant:
    # articulation
    solver_position_iteration_count: 4
    solver_velocity_iteration_count: 0
    sleep_threshold: 0.005
    stabilization_threshold: 0.001
    enable_self_collisions: True
    # per-body
    enable_gyroscopic_forces: True
    max_depenetration_velocity: 10.0
    # per-shape
    contact_offset: 0.02
    rest_offset: 0.0

# parameters for physics engine
sim:
  dt: 0.0083 # 1/120 s
  substeps: 1
  gravity: [0.0, 0.0, -9.81]

  enable_scene_query_support: False
  use_gpu_pipeline: True
  use_flatcache: True
  device: "cuda:0"

  physx:
    solver_type: 1
    use_gpu: True # set to False to run on CPU
    bounce_threshold_velocity: 0.2
    friction_offset_threshold: 0.04
    friction_correlation_distance: 0.025
    enable_stabilization: True

    # GPU buffers
    gpu_max_rigid_contact_count: 524288
    gpu_max_rigid_patch_count: 81920
    gpu_found_lost_pairs_capacity: 1024
    gpu_found_lost_aggregate_pairs_capacity: 262144
    gpu_total_aggregate_pairs_capacity: 2048
    gpu_max_soft_body_contacts: 1048576
    gpu_max_particle_contacts: 1048576
    gpu_heap_capacity: 67108864
    gpu_temp_buffer_capacity: 16777216
    gpu_max_num_partitions: 8
