Bayes Nets - Understanding Inference I was wondering if anyone could explain the following to me (from https://lips.cs.princeton.edu/complexity-of-inference-in-bayes-nets/):
"Briefly, recall that a Bayesian network consists of a directed acyclic graph with a random variable X_i at each vertex. Let $\pi_i$ be the parents of $X_i$. Then the Bayes net defines a distribution over $X = (X_1,\dots,X_n)$ of the form
\begin{equation*} \Pr[X] = \prod_{i=1}^n \Pr[X_i | \pi_i]\end{equation*}
Inference in a Bayes net corresponds to calculating the conditional probability $\Pr[Y | Z = z]$, where $Y,Z \subset \{ X_1,\dots,X_n \}$ are sets of latent and observed variables, respectively."
I understand the $\Pr[X]$ sectopm well enough, but am confused about the inference section; my guess is that $\Pr[Y]$ is the probability of the outcome variable/node but I'm not sure what $Z = z$ means and how this would be represented as a graph.
Thank you! :)

One of the standard inference tasks in Bayesian networks (BNs) is to compute the conditional probability distribution function (cpdf) of some nodes ($Y$) in the BN, given the value of some other nodes ($Z$). In this case, one observes (i.e. "fixes") the values $z$ of a set of nodes $Z$ and infers the probability $P(Y|Z=z)$ of other nodes $Y$. Because the values of $Y$ are not observed, they are called "latent".
E.g., you could have a BN of binary ($\{0, 1\}$) nodes $(X_1, X_2, X_3,X_4)$:

and you are interested in the  probabilities of both values of $Y = X_2$ under the condition that $Z=X_4=0$, i.e. you are interested in the cpdf $P(X_2|X_4=0)$, which consists of the two values $P(X_2=0|X_4=0)$ and $P(X_2=1|X_4 = 0)$.
