Consider a finite and flat morphism $f\colon X \rightarrow Y$ of schemes of degree $d$. If $Y$ is locally noetherian, then the sheaf $f_*\mathcal O_X$ is a finite locally free $\mathcal O_Y$-module of rank $d$.
Under which hypotheses is the sheaf $f_*\mathcal O_X$ the sum of $d$ invertible sheaves?
The specific situation I have in mind is a finite morphism of curves $f\colon C \rightarrow E$, where $C$ is a curve of genus $5$ and $E$ is a curve of genus $1$ which is the quotient of $C$ by an automorphism $\sigma$ of order $4$. The ramification indexes are all $\leq 2$, so $f$ is branched over $4$ points on $E$.
Cyclic covers pose no problem, at least if characteristic and order of the group are relatively prime. If $G$ is a cyclic group acting on $X$ and $f:X\to Y$ is the quotient, so that the map is flat (for example, $X,Y$ are smooth curves), then $G$ acts on $f_*\mathcal{O}_X$ and the eigenspaces are line bundles over $Y$ and it gives a splitting of $f_*\mathcal{O}_X$.