Consider a collection $M_i$ of $n\times n$ matrices. For an invertible $n\times n$ matrix $S$ let $$ M_i' = S^{-1}M_iS\;.$$ Which choices of $S$ minimize $$ \|M'\|_F^2= \sum_i \operatorname{Tr}(M_i' (M_i')^\dagger)\;?$$ For only a single matrix $M$ I'd suspect that an answer is given by the eigenbasis of $M$, is that correct?
In general, is there a simple analytic description or an efficient numerical algorithm to find such $S$?