my @scalar; my $size = $piddle->getdim(0); for (my $i=0; $i<$size; $i++) { push @scalar,$piddle->at($i) }