When is the Lie algebra of automorphisms of a geometrical structure finite-dimensional? Let $M$ be an $n$-dimensional smooth manifold and $\Theta$ some tensor field on $M$, so a smooth section of $TM^{\otimes r} \otimes T^*M^{\otimes s}$ for some $(r,s)$.  Let $\mathfrak{g}_\Theta$ denote the Lie subalgebra of vector fields which leave $\Theta$ invariant:
$$ \mathfrak{g}_\Theta = \{ X \in \mathcal{X}(M) \mid \mathcal{L}_X \Theta = 0 \}
$$
If $\Theta = g$, a pseudo-riemannian metric, then it is well-known that $\mathfrak{g}_\Theta$ is finite-dimensional, with dimension bounded above by $n(n+1)/2$.  On the other hand if $\Theta = \omega$, a symplectic structure, then it is again well known that $\mathfrak{g}_\Theta$ is infinite-dimensional, since it contains the hamiltonian vector fields.
I expect it is not easy, given $\Theta$, to determine whether $\mathfrak{g}_\Theta$ is finite- or infinite-dimensional, but I thought I'd ask here.
I'm actually interested in knowing what the generic case is.
I know from examples that if we allow a metric to become degenerate, then the "isometry" Lie algebra becomes infinite-dimensional.  But on the other hand, a random metric need not have any isometries at all.  Hence I am not sure which way to bet.
Any comments would be appreciated.
 A: The general procedure for deciding the 'local' version of this question, at least in the real-analytic connected case, was certainly known to Élie Cartan and, probably known to Lie in some form.  The basic idea is this:  The condition that a vector field $X$ preserve $\Theta$ is a system $\Sigma_\Theta$ of linear partial differential equations on $X$.  $\Sigma_\Theta$ may not be involutive, in which case, one prolongs the system to a system $\Sigma'_\Theta$ that is involutive and then one computes the Cartan characters.  If the last nonzero character is $s_p$ where $p>0$, then the sheaf of local vector fields that satisfy $\Sigma_\Theta$ has infinite dimensional stalks and hence the local infinitesimal symmetries of $\Theta$ are an infinite dimensional Lie algebra.  If the last nonzero character is $s_0$, then the sheaf of local vector fields that satisfy $\Sigma_\Theta$ is a finite dimensional Lie algebra of dimension $s_0$.
The assumption of real-analyticity is not always needed.  The global question (i.e., how many global solutions $X$ there are) is more subtle, and the answer often depends on details in the particular case, as usual.
There is often a way to show that the end result is going to be finite dimensional before you actually have to compute the involutive prolongation $\Sigma'_\Theta$, and such 'practical' criteria are more often used than the full result.
A: If an analytic geometric structure is rigid in the sense of Gromov (see Gromov and d'Ambra), its symmetry vector fields form a finite dimensional Lie algebra. This is not very helpful, since we don't know too many different ways to prove rigidity, but there are lots of examples in:
D'Ambra, G.(F-IHES); Gromov, M.(I-CAGL)
Lectures on transformation groups: geometry and dynamics. Surveys in differential geometry (Cambridge, MA, 1990), 19–111, Lehigh Univ., Bethlehem, PA, 1991. 
For example, if a structure (for example, a pseudo-Riemannian metric) induces an affine connection (for example, the Levi--Civita connection), then it is rigid, and its Lie algebra of symmetry vector fields is finite dimensional.
Similarly for a projective connection, or (in dimension 3 or more) for a conformal connection. 
You could also look at:
M. Gromov, Rigid transformations groups, in Géométrie Différentielle (Paris, 1986), Hermann, 1988.
A. M. Amores, Vector fields of a finite type G-structure, J. Diff.
Geom., 1979.
R. Quiroga-Barranco; A. Candel, Rigid and finite type geometric structures. Geom. Dedicata 106 (2004), 123–143. 
R. Zimmer, Ergodic theory and the automorphism group of a $G$-structure, in Group representations, ergodic theory, operator algebras,
and mathematical physics (Berkeley, Calif., 1984), 1987.
The paper of Quiroga-Barranco and Candel explains how to prove rigidity of many types of geometric structures, including Cartan geometries modelled on effective homogeneous spaces, so including pseudo-Riemannian geometries, affine connections, conformal connections in dimension 3 or more, and projective connections in dimensions 2 or more.
A: This article gives many examples of manifolds endowed with a structure whose group of automorphisms is finite dimensional.
https://www.ams.org/journals/tran/1964-113-01/S0002-9947-1964-0164299-4/S0002-9947-1964-0164299-4.pdf
In this article, it is shown that the group of automorphisms of an elliptic $G$-structure defined on a compact manifold is finite dimensional.
https://projecteuclid.org/download/pdf_1/euclid.jmsj/1260541200
