Skip to content

Tests are slow: use vjvp ? #204

Open
@mzgubic

Description

@mzgubic

Compare Zygote's gradtest

julia> @btime gradtest(x -> sum(abs2, x), randn(4, 3, 2))
  17.977 μs (236 allocations: 5.86 KiB)

and CRTUs test_rrule

@btime test_rrule(Zygote.ZygoteRuleConfig(), x -> sum(abs2, x), randn(4, 3, 2); rrule_f=rrule_via_ad)
  1.490 ms (6884 allocations: 480.10 KiB)

it's nearly 100x slower. Do we understand why? I didn't have time to look into it so just making an issue.

ChainRules tests take a pretty long time to run so this might be worth improving.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions