@@ -14,8 +14,8 @@ For `(y, ladj) = with_logabsdet_jacobian(f, x)`, the following must hold true:
14
14
`with_logabsdet_jacobian` comes with support for broadcasted/mapped functions
15
15
(via `Base.Fix1`) and (Julia >=v1.6 only) `ComposedFunction`.
16
16
17
- If no volume element is defined/applicable, `with_logabsdet_jacobian(f, x)` returns
18
- [`NoLogAbsDetJacobian(f)`](@ref).
17
+ If no volume element is defined/applicable, `with_logabsdet_jacobian(f::F , x::T)`
18
+ returns [`NoLogAbsDetJacobian{F,T} (f)`](@ref).
19
19
20
20
# Examples
21
21
@@ -83,15 +83,6 @@ struct NoLogAbsDetJacobian{F,T}
83
83
end
84
84
export NoLogAbsDetJacobian
85
85
86
- function _no_ladj_errmsg (@nospecialize noladj:: NoLogAbsDetJacobian{F,T} ) where {F,T}
87
- (" with_logabsdet_jacobian(" , noladj. f, " , ::" , T, " is not defined " )
88
- end
89
-
90
- Base. getindex (@nospecialize (noladj:: NoLogAbsDetJacobian ), args... ) = error (_no_ladj_errmsg (noladj)... )
91
- Base. iterate (@nospecialize (noladj:: NoLogAbsDetJacobian )) = error (_no_ladj_errmsg (noladj)... )
92
- Base. firstindex (@nospecialize (noladj:: NoLogAbsDetJacobian )) = error (_no_ladj_errmsg (noladj)... )
93
- Base. lastindex (@nospecialize (noladj:: NoLogAbsDetJacobian )) = error (_no_ladj_errmsg (noladj)... )
94
-
95
86
with_logabsdet_jacobian (f:: F , :: T ) where {F,T} = NoLogAbsDetJacobian {F,T} (f, )
96
87
97
88
0 commit comments