Improve initialization of dictionaries

Following @r-gaia-cs's recomendation.