micrograd icon indicating copy to clipboard operation
micrograd copied to clipboard

Fix __rsub and __rtruediv

Open adubovkin opened this issue 2 years ago • 1 comments

self should always be the first parameter in all reversed operations, otherwise it'll end up with an infinite recursion :)

adubovkin avatar Nov 22 '23 22:11 adubovkin

This won't cause an infinite recursion, just unnecessary radd and rmul calls. Also, it is a duplicate of https://github.com/karpathy/micrograd/pull/39.

conscell avatar Oct 11 '24 02:10 conscell