JuliaDiff / JuliaDiff/ReverseDiff.jl

ReverseDiff defines a huge number of methods.

Open
#226 3 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Julia
Stars
393
Forks
60
Avg merge
18h 24m
Merged PRs (30d)
8

Description

Loading ReverseDiff and recording what methods are inserted we can see that this package defines a very large number of methods (number of definitions to the right inside parenthesis):

image

For example, there are almost a thousand definitions for materialize (which is not even something that should be extended according to the interface manual: https://docs.julialang.org/en/v1/manual/interfaces/#man-interfaces-broadcasting).

There are also many many for hcat, vcat.

Structuring the package like this heavily pessimize its load time and it would be good to be less "brute force" than this way where you just write a heavily nested loop and define methods in it.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by loading ReverseDiff and recording the methods inserted, then locate the nested loop that generates methods such as materialize, hcat, and vcat. Done means reducing unnecessary method definitions and load-time cost without breaking the package's behavior; the issue names no specific test.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
performance
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.