Move Flatten layer to keep alphabetic ordering