Move `flatten` method into the distributor.
At the moment flatten
is performed by the distributed_data_object itself. Thereby it assumes, that flattening the local arrays produces the right result. In general with arbitrary distribution strategies this is wrong.