nv-legate / cunumeric

An Aspiring Drop-In Replacement for NumPy at Scale
https://docs.nvidia.com/cunumeric/24.06/
Apache License 2.0
613 stars 69 forks source link

Support numpy.gradient with inplace option #1105

Open CharlelieLrt opened 9 months ago

CharlelieLrt commented 9 months ago

This is low priority, but would it be possible to support numpy.gradient (and to a lesser degree numpy.diff ). Those are easy to write in terms of simple arithmetic operations and slicing, but for performance it would be beneficial to have a single kernel for these operators. In addition, numpy does not include an out argument for these operators, but it would be beneficial to have one.