File tree Expand file tree Collapse file tree 3 files changed +5
-2
lines changed Expand file tree Collapse file tree 3 files changed +5
-2
lines changed Original file line number Diff line number Diff line change 1
1
name = " ADTypes"
2
2
uuid = " 47edcb42-4c32-4615-8424-f2b9edc5f35b"
3
3
authors = [
" Vaibhav Dixit <[email protected] >, Guillaume Dalle and contributors" ]
4
- version = " 1.13 .0"
4
+ version = " 1.14 .0"
5
5
6
6
[deps ]
7
7
ChainRulesCore = " d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"
Original file line number Diff line number Diff line change @@ -225,14 +225,16 @@ end
225
225
226
226
"""
227
227
dense_ad(ad::AutoSparse)::AbstractADType
228
+ dense_ad(ad::AbstractADType)::AbstractADType
228
229
229
- Return the underlying AD package for a sparse AD choice.
230
+ Return the underlying AD package for a sparse AD choice, act as the identity on a dense AD choice .
230
231
231
232
# See also
232
233
233
234
- [`AutoSparse`](@ref)
234
235
"""
235
236
dense_ad (ad:: AutoSparse ) = ad. dense_ad
237
+ dense_ad (ad:: AbstractADType ) = ad
236
238
237
239
mode (sparse_ad:: AutoSparse ) = mode (dense_ad (sparse_ad))
238
240
Original file line number Diff line number Diff line change 11
11
elseif mode (ad) isa SymbolicMode
12
12
@test mode (sparse_ad) isa SymbolicMode
13
13
end
14
+ @test dense_ad (ad) == ad
14
15
@test dense_ad (sparse_ad) == ad
15
16
@test sparsity_detector (sparse_ad) == NoSparsityDetector ()
16
17
@test coloring_algorithm (sparse_ad) == NoColoringAlgorithm ()
You can’t perform that action at this time.
0 commit comments