Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document AutoChainRules #26

Merged
merged 2 commits into from
Mar 11, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ Just run the following code in a Julia REPL to find out:
julia> using ADTypes

julia> names(ADTypes)
15-element Vector{Symbol}:
16-element Vector{Symbol}:
:ADTypes
:AutoChainRules
:AutoEnzyme
:AutoFiniteDiff
:AutoFiniteDifferences
Expand Down
9 changes: 9 additions & 0 deletions src/ADTypes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ abstract type AbstractSparseReverseMode <: AbstractReverseMode end
abstract type AbstractSparseForwardMode <: AbstractForwardMode end
abstract type AbstractSparseFiniteDifferences <: AbstractFiniteDifferencesMode end

"""
AutoChainRules{RC}

Chooses any AD library based on [ChainRulesCore.jl](https://github.com/JuliaDiff/ChainRulesCore.jl), given an appropriate [`RuleConfig`](https://juliadiff.org/ChainRulesCore.jl/stable/rule_author/superpowers/ruleconfig.html) object.

# Fields

- `ruleconfig::RC`
"""
Base.@kwdef struct AutoChainRules{RC} <: AbstractADType
ruleconfig::RC
Vaibhavdixit02 marked this conversation as resolved.
Show resolved Hide resolved
end
Expand Down
Loading