Replies: 2 comments 5 replies
-
I agree we should change the name of the type annotation. To make the semantics more clear, I guess the main problem here is to properly encode the following in Python (we only consider scalar ndarrays here to simplify discussion): template<typename dtype, int dim>
struct any_arr {
dtype* base_ptr;
int shape[dim];
}; |
Beta Was this translation helpful? Give feedback.
5 replies
-
What's the progress on this? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Right now NDArrays's definition and type annotation have two different names:
IIRC,
ti.any_arr()
was named so in the beginning because we wanted to pass in normal numpy arrays (i.e., Taichi's original external array). Still, this naming inconsistency could be a barrier for promoting the usage of NDArray. I feel like it's OK to just use the termti.ndarray()
, because this is a widely adopted concept. WDYT?Beta Was this translation helpful? Give feedback.
All reactions