-
Notifications
You must be signed in to change notification settings - Fork 2
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
Update forest.py #15
base: master
Are you sure you want to change the base?
Update forest.py #15
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please check out the comments. This PR does not implement a DP RandomForrestRegressor. Hopefully the comments clarify why but if you get really stuck let me know and I can help guide you! 👍
diffprivlib/models/forest.py
Outdated
self.bounds = bounds | ||
self.random_state = random_state | ||
|
||
def _dp_mean(self, array): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This appears to never be called....
diffprivlib/models/forest.py
Outdated
return private_mean | ||
|
||
def fit(self, X, y): | ||
super().fit(X, y) # Fit the RandomForestRegressor |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here you are fitting with the parent RandomForrestRegressor which means no differential privacy will be applied during the training (ie the main point). Please go back an look at how they created the RandomForrestClassifier via custom trees. Their trees randomly partition the domain (not using the gini or entropy coefficient like in the vanilla RandomForrestRegressor). Then once the random trees are created you can use your _dp_mean method on the leaves.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please check now
@jkfitzsimons please check now |
No description provided.