You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fundamentally, in python, you can use any callable object (usually a function) as a decorator.
A function decorator is a decorator which returns a function object.
So your
Conceptually via nimpy, you can therefore treat any imported decorator such as ti.func as a callable that accepts a python function object, and returns you a new python function object. which is itself callable as you desire.
I want to use the Taichi python package: https://www.taichi-lang.org/
To generate GPU kernels, I need to annotate python functions like this:
Which generate a nice fractal animation seen here: https://docs.taichi-lang.org/docs/hello_world
My question is, how to use
@decorators
in Nim?Thank you in advance
The text was updated successfully, but these errors were encountered: