In [10]: hl.nd.array([hl.array([[[0,1],[2,3]],[[4,5],[6,7]]]), hl.array([[[0,1],[2,3]],[[4,5],[6,7]]])])
Out[10]: <NDArrayExpression of type ndarray<array<array<array<int32>>>, 1>>
This does what I expected:
In [11]: hl.nd.array(hl.array([hl.array([[[0,1],[2,3]],[[4,5],[6,7]]]), hl.array([[[0,1],[2,3]],[[4,5],[6,7]]])]))
Out[11]: <NDArrayNumericExpression of type ndarray<int32, 4>>
In particular, it seems that hl.nd.array flattens recursive lists, or recursive hl.array but it does not flatten a list of hl.array.
What happened?
This does not do I expected:
This does what I expected:
In particular, it seems that
hl.nd.array
flattens recursivelist
s, or recursivehl.array
but it does not flatten alist
ofhl.array
.Version
0.2.124
Relevant log output
No response