What\'s the inverse of f[x_]:=Flatten[x] where x is Array with dimensions dims?
You probably want Partition[] or one of its relatives.
Partition[]