dm_control icon indicating copy to clipboard operation
dm_control copied to clipboard

Making Tasks Infinite Horizon

Open nileshop22 opened this issue 4 years ago • 2 comments

Hi, from the White Paper I found that these tasks terminate after 1000 steps. I'm working with Infinite Horizon Problems for which I need continuing/ infinite-horizon/ never ending tasks. Is there any way by which I can remove the 1000 steps constraint.

Also, I want to train a DQN agent for which I need discrete actions. Is there any way of discretezing the continuous action space for this suite?

Any help would be really appreciated. Thanks.

nileshop22 avatar Nov 04 '21 10:11 nileshop22

Regarding the first question, I believe that you there is an option to specify a time limit, see for example https://github.com/deepmind/dm_control/blob/4f1a9944bf74066b1ffe982632f20e6c687d45f1/dm_control/suite/cartpole.py#L62

To use this, I think something like

from dm_control import suite

suite.load(
  "pendulum", 
  "swingup", 
  task_kwargs={"time_limit", float("inf"))},
)

would work.

ethanluoyc avatar Nov 11 '21 23:11 ethanluoyc

Indeed, you can take a look at the LQR task, which has a terminal state condition rather than a time limit.

On Thu, 11 Nov 2021 at 23:13, Yicheng Luo @.***> wrote:

Regarding the first question, I believe that you there is an option to specify a time limit, see for example

https://github.com/deepmind/dm_control/blob/4f1a9944bf74066b1ffe982632f20e6c687d45f1/dm_control/suite/cartpole.py#L62

To use this, I think something like

from dm_control import suite suite.load( "pendulum", "swingup", task_kwargs={"time_limit", float("inf"))}, )

would work.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/deepmind/dm_control/issues/213#issuecomment-966690993, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABQXORUCFLMYBTH4UMAYFVDULRE3FANCNFSM5HLDIQEQ .

--

Dr. Yuval Tassa | Research Scientist | Google DeepMind | @.***

yuvaltassa avatar Nov 12 '21 08:11 yuvaltassa