def SIunits(x):
    prefixes_n = ('', 'm', 'u', 'n', 'p', 'f', 'a', 'z', 'y')
    prefixes_p = ('', 'k', 'M', 'G', 'T', 'P', 'E', 'Z', 'Y')
    scalar_input = np.isscalar(x)
    if scalar_input:
        x = [x]
    factor = np.ones(len(x))
    prefix = ['']*len(x)
    for i in range(len(x)):
        if x[i] != 0:
            p = int(np.floor(np.log10(abs(x[i]))/3 + eps))
            if p >= 0:
                p = min(p, len(prefixes_p))
                prefix[i] = prefixes_p[p]
                factor[i] = 10**(3*p)
            elif p < 0:
                p = min(-p, len(prefixes_n)-1)
                prefix[i] = prefixes_n[p]
                factor[i] = 10**(-3*p)
        else:
            factor[i], prefix[i] = 0, ''
    if scalar_input:
        factor, prefix = factor[0], prefix[0]
    return factor, prefix
Calculates the factor for representing ``x`` in engineering 
dataset/ETHPy150Open ggventurini/python-deltasigma/deltasigma/_SIunits.py/SIunits