When are flag manifolds compact? This is a question from Lee's book on Smooth Manifolds, question 21-16:

Let $F_K(V)$ be the set of flags of type $K$ in a finite-dimensional (real) vector space $V$. Show that $GL(V)$ acts transitively on $F_K(V)$, and that the isotropy group of a particular flag is a closed subgroup of $GL(V)$, and conclude that $F_K(V)$ has a unique smooth manifold structure such that the action is smooth. What is the dimension of $F_K(V)$? For which $K$ is $F_K(V)$ compact?

I am not sure how to do compactness.
 A: I read from Lee - Introduction to Smooth Manifolds, example 7.23, by flag of type $K$ of a finite dimensional real vector space $\mathbb{V}$ of dimension $n\in\mathbb{N}$ one means
\begin{gather}
0<k_1<k_2<\dots<k_m\leq n,\,K=(k_1,\dots,k_m),\\
F\equiv\{\underline0\}<\mathbb{V}_1<\mathbb{V}_2<\dots<\mathbb{V}_m\leq\mathbb{V},\,\forall i\in\{1,\dots,m\},\,\dim\mathbb{V}_i=k_i,\,dim\mathbb{V}_{i\displaystyle/\mathbb{V}_{i-1}}=d_i,
\end{gather}
and the set of all flags of $\mathbb{V}$ of type $K$ is denoted by $F_K(\mathbb{V})$.
Let $\{e_1\dots,e_n\}$ be a basis of $\mathbb{V}$, defined:
$$
\forall i\in\{1,\dots,m\},\,\mathbb{V}_i=\langle e_1,\dots,e_{k_i}\rangle;
$$
one has $\forall M\in\mathrm{GL}(n,\,\mathbb{R}),i\in\{1,\dots,m\},\,M\cdot\mathbb{V}_i=\langle M\cdot e_1,\dots,M\cdot e_{k_i}\rangle$ are well defined subspaces of $\mathbb{V}$; in particular, the flag
$$
F_K(\mathbb{V})\ni M\cdot F\equiv\mathbb{V}_0< M\cdot\mathbb{V}_1<\dots<M\cdot\mathbb{V}_m\leq\mathbb{V}
$$
is well defined.
Defined the action
$$
\alpha:(M,F)\in\mathrm{GL}(n,\mathbb{R})\times F_K(\mathbb{V})\to M\cdot F\in F_K(\mathbb{V});
$$
one proves (easily) that $\alpha$ is a transitive action and $F_K(\mathbb{V})$ is in bijection with
$$
\mathrm{GL}(n,\mathbb{R})_{\displaystyle/P(d_1,\dots,d_m)},
$$
where $P(d_1,\dots,d_m)$ is the (closed) subgroup of $\mathrm{GL}(n,\mathbb{R})$ generated by the matrices of the following type
$$
\forall i\leq j\in\{1,\dots,m\},\,A_i^j\in\mathbb{R}_{d_i}^{d_j},\,\begin{pmatrix}
A_1^1 & A_1^2 & \dots & A_1^r\\
\underline{0}_{d_2}^{d_1} & A_2^2 & \dots & A_2^m\\
\vdots & \ddots & \ddots & \vdots\\
\underline{0}_{d_m}^{d^1} & \underline{0}_{d_m}^{d_2} & \dots & A_m^m
\end{pmatrix}.
$$
In particular, one can restrict the focus on the isometries of $\mathbb{V}$, that is one considers the action
$$
\widetilde{\alpha}:(M,F)\in\mathrm{O}(n,\mathbb{R})\times F_K(\mathbb{V})\to M\cdot F\in F_K(\mathbb{V})
$$
and as for $\alpha$, one proves that $\widetilde{\alpha}$ is a transitive action and therefore $F_K(\mathbb{V})$ is in bijection with
$
\mathrm{O}(n,\mathbb{R})_{\displaystyle/\mathrm{O}(d_1,\mathbb{R})\times\dots\mathrm{O}(d_m,\mathbb{R})}$; since $\mathrm{O}(n,\mathbb{R})$ is a compact manifold, and a quotient space of a compact space is compact: $F_K(\mathbb{V})$ is a compact manifold.
