or download this
# 2d array data, initialised to these rows (edit: updated to specify c
+tx too)
my $a_data = mx->nd->array([[1,2],[3,4]], ctx => $ctx);
my $b_data = mx->nd->array([[5,6],[7,8]], ctx => $ctx);
my $c_data = mx->nd->array([[9,10],[11,12]], ctx => $ctx);
my $d_data = mx->nd->array([[13,14],[15,16]], ctx => $ctx);