'Use axis view limits to control which ticks are labeled.
The ``locs`` parameter is ignored in the present algorithm.'

def set_locs(self, locs=None):

    if np.isinf(self.minor_thresholds[0]):
        self._sublabels = None
        return
    linthresh = self._linthresh
    if (linthresh is None):
        try:
            linthresh = self.axis.get_transform().linthresh
        except AttributeError:
            pass
    (vmin, vmax) = self.axis.get_view_interval()
    if (vmin > vmax):
        (vmin, vmax) = (vmax, vmin)
    if ((linthresh is None) and (vmin <= 0)):
        self._sublabels = set((1,))
        return
    b = self._base
    if (linthresh is not None):
        numdec = 0
        if (vmin < (- linthresh)):
            rhs = min(vmax, (- linthresh))
            numdec += (math.log((vmin / rhs)) / math.log(b))
        if (vmax > linthresh):
            lhs = max(vmin, linthresh)
            numdec += (math.log((vmax / lhs)) / math.log(b))
    else:
        vmin = (math.log(vmin) / math.log(b))
        vmax = (math.log(vmax) / math.log(b))
        numdec = abs((vmax - vmin))
    if (numdec > self.minor_thresholds[0]):
        self._sublabels = {1}
    elif (numdec > self.minor_thresholds[1]):
        c = np.logspace(0, 1, ((int(b) // 2) + 1), base=b)
        self._sublabels = set(np.round(c))
    else:
        self._sublabels = set(np.arange(1, (b + 1)))
