'Helper for _sdm_to_vector.'

def _sdm_to_dics(self, s, n):

    from sympy.polys.distributedmodules import sdm_to_dict
    dic = sdm_to_dict(s)
    res = [{} for _ in range(n)]
    for (k, v) in dic.items():
        res[k[0]][k[1:]] = v
    return res
