code: def getIndexForValue(self, value):
          
          return math.trunc(self.slope * float(value) + self.intercept)
docs: Return the ramp index for the given value
          :param value: Lookup value
          :rtype: int