In the present paper, in view of the variational approach, we consider the existence of positive weak solutions for a class of the double phase problem $ \left\{ \begin{array}{ll} -{\rm div}(|\nabla u|^{p-2}\nabla u+a(x)|\nabla u|^{q-2}\nabla u)=\lambda V_1(x)|u|^{\alpha-2}u -\mu V_2(x)|u|^{\beta-2}u,&\hbox{in}\;\Omega , \\ u=0, &\hbox{on}\;\partial \Omega, \end{array} \right. $ where $N\geq 2$ and $1<p<q<N$, $\alpha,\beta,\lambda,\mu$ are positive real numbers, $V_1$ and $V_2$ are weight functions in generalized Lebesgue spaces $L^{s_1}(\Omega)$ and $L^{s_2}(\Omega)$ respectively such that $V_1$ may change sign in $\Omega$ and $V_2\geq 0$ on $\Omega$.