Influence of the reagents’ ratio on photoelectric and optical properties of perovskite films for photovoltaics