Convert from map to nested vector representation.