def predict(self, x):
        ''' Get probability estimation on x

            INPUT:
                x: features

            OUTPUT:
                probability of p(y = 1 | x; w)
        '''

        # model
        w = self.w

        # wTx is the inner product of w and x
        wTx = 0.
        for i in self._indices(x):
            wTx += w[i]

        # bounded sigmoid function, this is the probability estimation
        return (1. + exp(-max(min(wTx, 35.), -35.))) / 1.
dataset/ETHPy150Open infinitezxc/kaggle-avazu/script/ftrl_2.py/ftrl_proximal.predict/swapped operands of `/`