Adding EnzymeRules
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- julia
- Domain
- backend-api-design
Research direction
Start by reading the existing ChainRulesCore support and the EnzymeCore.EnzymeRules documentation, then check how Requires.jl handles conditional loading across Julia versions. Confirm the intended Forward and Reverse rules for StridedArray inputs and verify that sparse or structured arrays are excluded; done means compatible Enzyme support with tests covering the supported versions and input type.
Written by the indexing model from the issue text.
Description
Similar to the ChainRulesCore support, we could use EnzymeCore.EnzymeRules to define Forward and Reverse mode rules for Enzyme in an extension.
EnzymeCore requires at least Julia v1.6. Making it a dependency for Julia versions older than v1.6 (as is done with ChainRulesCore) would then only be possible if AbstractFFTs add a Julia v1.6 version bound. But since EnzymeCore's sole dependency (Adapt) depends on Requires, it may make more sense to conditionally load on pre-v1.9 using Requires.jl: https://pkgdocs.julialang.org/dev/creating-packages/#Requires.jl
Unlike ChainRulesCore support, it probably only makes sense to only define rules for StridedArray inputs to avoid doing the wrong thing for sparse or structured arrays.
- Dominant language
- Julia
- Stars
- 135
- Forks
- 40
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from JuliaMath/AbstractFFTs.jl
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
JuliaMath/AbstractFFTs.jl#159 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
JuliaMath/AbstractFFTs.jl#147 ·
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
JuliaMath/AbstractFFTs.jl#135 ·
-
Difficulty 5/5 Over a week Newbie friendliness 28/100
JuliaMath/AbstractFFTs.jl#125 · 2 reactions ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
JuliaMath/AbstractFFTs.jl#122 · 3 comments ·
All issues in JuliaMath/AbstractFFTs.jl
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
JuliaGPU/GPUArrays.jl#837 ·
Maintainers usually reply within 2 days
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
bmad-sim/BeamTracking.jl#382 ·
Maintainers usually reply within 1 day