Skip to content

feat(core): autograd engine (reverse-mode autodiff) #7

@Celz-Pch

Description

@Celz-Pch

Goal

Enable gradient computation through a dynamic computation graph.

Tasks

  • Variable / Node wrapping Tensor with gradient tracking
  • Record operations into a DAG
  • backward() that traverses the graph and accumulates .grad
  • Backward implementations for add, mul, matmul, sum

Acceptance criteria

  • Gradients match numerical differentiation on toy functions
  • Inspired by micrograd / tinygrad design

References

  • Andrej Karpathy's micrograd
  • PyTorch autograd internals

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: coreTensor / autograd / core enginepriority: highImportant to land soontype: featureNew feature or capability

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions