File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 9494@adjoint function VectorOfArray (u)
9595 VectorOfArray (u),
9696 y -> begin
97- (VectorOfArray ([y[]. u[ntuple (x -> Colon (), ndims (y[]. u) - 1 )... , i]
98- for i in 1 : size (y[]. u)[end ]]),)
97+ y isa Ref && (y = VectorOfArray (y[]. u))
98+ (VectorOfArray ([y[ntuple (x -> Colon (), ndims (y. u) - 1 )... , i]
99+ for i in 1 : size (y. u)[end ]]),)
99100 end
100101end
101102
102103@adjoint function DiffEqArray (u, t)
103104 DiffEqArray (u, t),
104- y -> (DiffEqArray ([y[]. u[ntuple (x -> Colon (), ndims (y[]. u) - 1 )... , i]
105- for i in 1 : size (y[]. u)[end ]],
105+ y -> begin
106+ y isa Ref && (y = VectorOfArray (y[]. u))
107+ (DiffEqArray ([y[ntuple (x -> Colon (), ndims (y. u) - 1 )... , i]
108+ for i in 1 : size (y. u)[end ]],
106109 t), nothing )
110+ end
107111end
108112
109113@adjoint function literal_getproperty (A:: ArrayPartition , :: Val{:x} )
You can’t perform that action at this time.
0 commit comments