Objective to Train HMM Maximize Likelihood An Hidden Markov Model can be utilized to model a seq of face gestures(e.g., left eye-brow up, lip pull down, right eye closed) defining a facial gesture. 
I want to determine an objective to train a Hidden Markov Model such that it maximizes the likelihood of a set of sequences of facial gestures. Specifically, how do I formulate an optimization problem from this such that it could be utilized to learn the parameters of the Hidden Markov Model given that hidden states are never observed. 
 A: The objective for training HMMs is typically the likelihood with latent variables integrated out. Specifically, say you have a chain of length $N$. Denote by $Z=\{z_n\}_{n=1}^N$ the latent states and $X=\{x_n\}_{n=1}^N$ the observed states (e.g. facial gestures). Further, let $\pi$ be the marginal distribution of $z_1$, $A$ the latent transition matrix with $A_{j,k}=\mathbb{P}(z_n=k|z_{n-1}=j)$ and $f(x; \theta_k) = \mathbb{P}(x_n=x|z_n=k)$ the emission distribution parameterised by $\theta_k$ (different for each latent class). 
Then the joint likelihood is given by
$$ \mathbb{P}(X,Z; \pi, A,\theta) = \pi(z_1) \left( \prod_{n=2}^N A_{z_{n-1},z_n} \right) \left( \prod_{n=1}^N f(x_n;\theta_{z_n}) \right).
$$
As you say, the above quantity cannot be optimised directly, since $Z$ is not observed, so one typically integrates out the latents and maximises the resulting marginal likelihood instead:
$$ \max_{\pi, A, \theta} \sum_{Z} \pi(z_1) \left( \prod_{n=2}^N A_{z_{n-1},z_n} \right) \left( \prod_{n=1}^N f(x_n;\theta_{z_n}) \right).
$$
The integration step introduces a lot of computational complications (you cannot conveniently take logs anymore) but there is no easy way around it.  Optimisation is still possible, via the expectation-maximisation (EM) algorithm for example, but involves quite some technical sophistication. You can find a nice treatment of the topic in Christopher Bishop's book (Chapter 13).
