Convert levels form structure of arrays to array of strucures.