Created
April 8, 2020 21:52
-
-
Save smazzanti/2322c43cf9a656326a60c13506269a8d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# define a sklearn compatible wrapper for our data generating function | |
class UnbeatableRegressor(): | |
def __init__(self): | |
pass | |
def fit(self, X, y): | |
pass | |
def predict(self, X): | |
return np.array(X2y(X, with_error = False)) | |
def score(self, X, y): | |
return mean_absolute_error(y, self.predict(X)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment