def get_boundaries(self, maxvalue, scale):
        edges = []
        colors = []
        
        for i in range(self.levels+1):
            z = 1. * i / self.levels
            if scale == 'lin':
                edges.append(maxvalue * z)
            elif scale == 'log':
                # log(v)/log(maxvalue) = z
                # log(v) = log(maxvalue)*z
                # v = e^(log(maxvalue)*z)
                edges.append(math.exp(math.log(maxvalue)*z))
            elif scale == 'sqrt':
                # sqrt(v)/sqrt(maxvalue) = z
                # v/maxvalue = z^2
                # v = maxvalue * z^2
                edges.append(maxvalue * z**2)
            else:
                raise Exception('scale must be "lin", "log", or "sqrt"') 

        for e in edges[:-1]:
            colors.append(self.to_color(e, maxvalue, scale))

        return edges, colors
dataset/ETHPy150Open andrea-cuttone/geoplotlib/geoplotlib/colors.py/ColorMap.get_boundaries/original