Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hyperparameter tuning for CausalForestDML #390

Merged
merged 18 commits into from
Mar 9, 2021

Conversation

vsyrgkanis
Copy link
Collaborator

No description provided.

@vsyrgkanis vsyrgkanis marked this pull request as ready for review February 5, 2021 20:14
@vsyrgkanis vsyrgkanis changed the title Vasilis/grf and scorer docs Hyperparameter tuning for CausalForestDML Mar 1, 2021
Copy link
Collaborator

@kbattocchi kbattocchi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly looks good, but sample splitting may need some thought, and I added a few other comments.

econml/_ortho_learner.py Outdated Show resolved Hide resolved
econml/_ortho_learner.py Outdated Show resolved Hide resolved
econml/_ortho_learner.py Outdated Show resolved Hide resolved
econml/dml/causal_forest.py Outdated Show resolved Hide resolved
econml/dml/causal_forest.py Outdated Show resolved Hide resolved
econml/dml/causal_forest.py Outdated Show resolved Hide resolved
econml/dml/causal_forest.py Outdated Show resolved Hide resolved
Comment on lines 510 to 511
out of sample R-score. After the function is called, then all parameters of `self` have been
set to the optimal hyperparameters found.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe explicitly mention that although the parameters will have been updated, this estimator will not have been fit with this data.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

now only final stage params are tunable

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still think it's worth mentioning that this estimator has not been fit with this data, so that the user knows that the they still have to call fit afterward.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or alternatively, in your notebooks I think you always use:

est.tune(...)
est.fit(...)

Are there times a user would not want to do that, or should calling fit just be folded into tune so that it saves the user the trouble?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's what I'm doing in the notebooks I think.

I think it's good to have separate. Maybe someone wants to tune on a subset of the data or some small chunk. Also the tune does not need to take other keyword args like inference, cache_values etc.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added the extra docstring comment that the returned self is not yet fitted.

econml/grf/classes.py Outdated Show resolved Hide resolved
notebooks/ForestLearners Basic Example.ipynb Outdated Show resolved Hide resolved
Copy link
Collaborator

@kbattocchi kbattocchi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@vsyrgkanis vsyrgkanis merged commit ed84691 into master Mar 9, 2021
@vsyrgkanis vsyrgkanis deleted the vasilis/grf_and_scorer_docs branch March 9, 2021 15:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants