Skip to content
This repository was archived by the owner on May 6, 2021. It is now read-only.

Commit d53a017

Browse files
authored
Use clamp instead of min max, update lower limit (#170)
1 parent 2f28cbc commit d53a017

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/experiments/rl_envs/JuliaRL_SAC_Pendulum.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ function RLCore.Experiment(
3030
Chain(Dense(ns, 30, relu), Dense(30, 30, relu)),
3131
Chain(Dense(30, 1, initW = init)),
3232
Chain(
33-
Dense(30, 1, x -> min(max(x, typeof(x)(-20)), typeof(x)(2)), initW = init),
33+
Dense(30, 1, x -> clamp(x, typeof(x)(-2), typeof(x)(2)), initW = init),
3434
),
3535
),
3636
optimizer = ADAM(0.003),

0 commit comments

Comments
 (0)