$$
I=\frac{1}{\pi}\int_0^\pi e^{2\cos\theta}\,d\theta=\frac{1}{\pi}\sum_{k=0}^\infty\frac{2^k}{k!}A_k,
$$
with
$$
A_k=\int_0^\pi\cos^k\theta\,d\theta \quad \forall k \ge 0.
$$
We have
$$
A_0=\int_0^\pi\,d\theta=\pi.
$$
For every $k \ge 1$, if we set $\varphi=\pi-\theta$, then
$$
\int_{\pi/2}^\pi\cos^k\theta\,d\theta=\int_0^{\pi/2}\cos^k(\pi-\varphi)\,d\varphi=(-1)^k\int_0^{\pi/2}\cos^k\varphi\,d\varphi.
$$
Theorefore, for every $k \ge 1$ we have
$$
A_k=\int_0^{\pi/2}\cos^k\theta\,d\theta+\int_{\pi/2}^\pi\cos^k\theta\,d\theta=[1+(-1)^k]\int_0^{\pi/2}\cos^k\theta\,d\theta.
$$
We deduce that $A_{2k+1}=0$ for all $k \ge 0$.
For every $k\ge 1$ we have
\begin{eqnarray}
B_k&:=&A_{2k}=2\int_0^{\pi/2}\cos^{2k}\theta\,d\theta=2\int_0^{\pi/2}(\sin\theta)'\cos^{2k-1}\theta\,d\theta\\
&=&2(2k-1)\int_0^{\pi/2}\sin^2\theta\cos^{2k-2}\theta\,d\theta=2(2k-1)\int_0^{\pi/2}(1-\cos^2\theta)\cos^{2k-2}\theta\,d\theta\\
&=&(2k-1)(B_{k-1}-B_k),
\end{eqnarray}
i.e.
$$
B_k=\frac{2k-1}{2k}B_{k-1} \quad \forall k \ge 1.
$$
Thus
$$
B_k=\frac{(2k-1)\cdot(2k-3)\ldots3\cdot1}{(2k)\cdot(2k-2)\ldots4\cdot2}B_0=\frac{(2k)!}{[(2k)(2k-2)\ldots4\cdot2]^2}B_0=\frac{(2k)!}{2^{2k}(k!)^2}\pi.
$$
The given integral is then
$$
I=\frac{1}{\pi}\sum_{k=0}^\infty\frac{2^{2k}}{(2k)!}A_{2k}=\frac{1}{\pi}\sum_{k=0}^\infty\frac{2^{2k}}{(2k)!}\cdot\frac{(2k)!}{2^{2k}(k!)^2}\pi=\sum_{k=0}^\infty\frac{1}{(k!)^2}.
$$