Let $X$ be a compact metric space and $\mathcal{B}$ its Borel $\sigma$-algebra. Suppose that $(X,\mathcal{B},\mu,T)$ is an invertible ergodic system ($T$ is only a measurable isomorphism, not necessarily a homeomorphism) and suppose that $Y$ is a compact metric space and $f:X \to Y$ is measurable. Can we find a compact metric space $\tilde{X}$ with Borel $\sigma$-algebra $\tilde{B}$ such that there is an isomorphism of measure preserving system $$\phi:(\tilde{X},\tilde{B},\tilde{\mu},\tilde{T}) \to (X,\mathcal{B},\mu,T)$$ such that $\tilde{T}$ is a homeomorphism and $$f \circ \phi$$ is almost $\tilde{\mu}$ almost equal to some continuous function?
This is related to my previous question: Topologizing Borel space so that certain functions become continuous which essentially shows that one can not drop the ergodicity assumption (e.g: can take $T$ as the identity).