@@ -8,16 +8,16 @@ const CircularArraySLARTTraces = Traces{
8
8
<: MultiplexTraces{AA′,<:Trace{<:CircularArrayBuffer}} ,
9
9
<: Trace{<:CircularArrayBuffer} ,
10
10
<: Trace{<:CircularArrayBuffer} ,
11
- }
11
+ },
12
12
}
13
13
14
14
function CircularArraySLARTTraces (;
15
15
capacity:: Int ,
16
- state= Int => (),
17
- legal_actions_mask= Bool => (),
18
- action= Int => (),
19
- reward= Float32 => (),
20
- terminal= Bool => ()
16
+ state = Int => (),
17
+ legal_actions_mask = Bool => (),
18
+ action = Int => (),
19
+ reward = Float32 => (),
20
+ terminal = Bool => (),
21
21
)
22
22
state_eltype, state_size = state
23
23
action_eltype, action_size = action
@@ -26,12 +26,18 @@ function CircularArraySLARTTraces(;
26
26
terminal_eltype, terminal_size = terminal
27
27
28
28
MultiplexTraces {SS′} (CircularArrayBuffer {state_eltype} (state_size... , capacity + 1 )) +
29
- MultiplexTraces {LL′} (CircularArrayBuffer {legal_actions_mask_eltype} (legal_actions_mask_size... , capacity + 1 )) +
29
+ MultiplexTraces {LL′} (
30
+ CircularArrayBuffer {legal_actions_mask_eltype} (
31
+ legal_actions_mask_size... ,
32
+ capacity + 1 ,
33
+ ),
34
+ ) +
30
35
MultiplexTraces {AA′} (CircularArrayBuffer {action_eltype} (action_size... , capacity + 1 )) +
31
36
Traces (
32
- reward= CircularArrayBuffer {reward_eltype} (reward_size... , capacity),
33
- terminal= CircularArrayBuffer {terminal_eltype} (terminal_size... , capacity),
37
+ reward = CircularArrayBuffer {reward_eltype} (reward_size... , capacity),
38
+ terminal = CircularArrayBuffer {terminal_eltype} (terminal_size... , capacity),
34
39
)
35
40
end
36
41
37
- CircularArrayBuffers. capacity (t:: CircularArraySLARTTraces ) = minimum (map (capacity,t. traces))
42
+ CircularArrayBuffers. capacity (t:: CircularArraySLARTTraces ) =
43
+ minimum (map (capacity, t. traces))
0 commit comments