econml/selective_regularization.py
def predict(self, X):
        """Apply the model to a set of features to predict the outcomes."""
        # TODO: any better way to deal with sparsity?
        if sp.issparse(X):
            X = X.toarray()
        return self.session.run(self.Y_pred, feed_dict={
            self.X_reg: X[:, self._subset],
            self.X_ureg: X[:, self._subset_c]
        })
Apply the model to a set of features to predict the outcomes.
Apply the model to a set of features to predict the outcomes.
Apply the model to a set of features to predict the outcomes .
def predict(self, X):
        if sp.issparse(X):
            X = X.toarray()
        return self.session.run(self.Y_pred, feed_dict={
            self.X_reg: X[:, self._subset],
            self.X_ureg: X[:, self._subset_c]
        })
def predict ( self , X ) : if sp . issparse ( X ) : X = X . toarray ( ) return self . session . run ( self . Y_pred , feed_dict = { self . X_reg : X [ : , self . _subset ] , self . X_ureg : X [ : , self . _subset_c ] } )
Apply the model to a set of features to predict the outcomes.
Apply the model to a set of features to predict the outcomes .
"""Apply the model to a set of features to predict the outcomes.""" # TODO: any better way to deal with sparsity?
self
X