Answers.Body: <p>Yes you can map the output onto [0,1] as you indicate. You should treat this as a modification to the environment. I.e. imagine that the environment takes actions in [-1, 1] instead of [0,1]. No you don't need to change any equations.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-06-16T05:34:11.117Z
Answers.LastActivityDate: 2021-06-16T05:34:11.117Z
Answers.UserDisplayName: Taw
Body: <p>In the paper <a href="https://arxiv.org/pdf/1812.05905.pdf" rel="nofollow noreferrer">&quot;Soft Actor-Critic Algorithms and Applications&quot;</a>, appendix C shows enforcing action bounds using the tanh squashing function which is in (-1, 1). I have action bounds in (0, 1), so can I just modify the tanh output by applying the following transformation:
  output = 0.5 * (tanh_output + 1). If so, do I need to change logprob formula too?</p>
  <p>I have not seen any SAC implementation with different action bounds other than the paper's (-1, 1).</p>
  
Tags: <reinforcement-learning><deep-rl><soft-actor-critic>
Title: How to enforce action bounds between 0 & 1 in soft actor-critic algorithm?
UserDisplayName: Mika
ThreadText: # How to enforce action bounds between 0 & 1 in soft actor-critic algorithm?
  
  (Asked by: username_0 on 2021-06-14)
  
  In the paper ["Soft Actor-Critic Algorithms and Applications"](https://arxiv.org/pdf/1812.05905.pdf), appendix C shows enforcing action bounds using the tanh squashing function which is in (-1, 1). I have action bounds in (0, 1), so can I just modify the tanh output by applying the following transformation:
  output = 0.5 \* (tanh\_output + 1). If so, do I need to change logprob formula too?
  
  I have not seen any SAC implementation with different action bounds other than the paper's (-1, 1).
  
  **Tags:** reinforcement-learning, deep-rl, soft-actor-critic
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2021-06-16. Score: 1
  
  Yes you can map the output onto [0,1] as you indicate. You should treat this as a modification to the environment. I.e. imagine that the environment takes actions in [-1, 1] instead of [0,1]. No you don't need to change any equations.
  
  
  ---
  
  