Computing weighted Szeged and PI indices from quotient graphs