How to find the deterministic function representation of a random variable? For any random variable $X$ whose density is $\mathbb{P}(X=x)=p(x;\theta),$ where $\theta$ is a parameter, its deterministic function representation is $X=f(\theta, \omega)$ where $\omega$ is a random variable whose distribution is independent of $\theta$. 
Question: what is the condition on $p(x; \theta)$ so that its deterministic function representation exists?
For example, if $X\sim N(\mu,\sigma^2)$, then $X=\mu+\sigma \omega$ where $\omega$ is a standard normal random variable. 
If $X \sim \operatorname{Bernoulli}(q)$, then $X=1(\operatorname{logit}^{-1}(q)>\omega)$ where $\omega$ is a logistic random variable. 
I don't know if there is a deterministic function representation for a Poisson random variable.
 A: This can be accomplished using inverse transformation sampling; it does not require a restriction on the desired distribution function.  To do this, define $X \equiv f(\theta,\omega) \equiv \inf \{ r \in \mathbb{R} | F_\theta(r) \geqslant \omega \}$$^\dagger$ where $F_\theta$ is the desired distribution function conditional on the parameter $\theta$.  Since the distribution  $F_\theta$ is non-decreasing we have:
$$\inf \{ r \in \mathbb{R} | F_\theta(r) \geqslant \omega \} \leqslant x \quad \quad \iff \quad \quad F_\theta(x) \geqslant \omega .$$
Hence, taking $\omega \sim \text{U}(0,1)$ independent of the parameter  $\theta$ you then get:
$$\begin{equation} \begin{aligned}
\mathbb{P}(X \leqslant x | \theta) 
&= \mathbb{P} \Big( \inf \{ x \in \mathbb{R} | F_\theta(x) \geqslant  \omega \} \leqslant x \Big| \theta \Big) \\[6pt]
&= \mathbb{P} \Big( \omega \leqslant F_\theta(x) \Big| \theta \Big) \\[6pt]
&= F_\theta(x), \\[6pt]
\end{aligned} \end{equation}$$
which is the desired distribution for $X$ conditional on the parameter $\theta$.  As you can see, there is no requirement on $F_\theta$ for this technique to work, though it is notable that it is not necessarily the most computationally efficient technique to generate your desired random variable.  This technique can be extended to multivariate problems as shown in this related question.

$^\dagger$ This infimum function is the "generalised inverse" of $F_\theta$.  In the case where $F_\theta$ is continuous you get $\inf \{ r \in \mathbb{R} | F_\theta(r) \geqslant \omega \} = F_\theta^{-1}(\omega)$, which is the inverse in the regular functional sense.
