data61 / MP-SPDZ

Versatile framework for multi-party computation
Other
944 stars 280 forks source link

Added implementation of https://eprint.iacr.org/2024/1077 #1449

Open sandy9999 opened 4 months ago

sandy9999 commented 4 months ago

Added implementation of the Decision Tree protocol from "Securely Training Decision Trees Efficiently" by Divyanshu Bhardwaj, Sandhya Saravanan, Nishanth Chandran and Divya Gupta : eprint link.

This decision tree training protocol has communication complexity $O(mN \log N + hmN + hN \log N)$ which is an improvement of $\approx min(h, m, \log N)$ over Hamada et. al link.

-Sandhya Saravanan

mkskeller commented 4 months ago

Thank you for submitting this pull request. However, the code isn't suitable for inclusion due to the following reasons:

I would suggest the following apart from correcting the compilation errors:

mkskeller commented 3 months ago

Thank you for your additions. I'm afraid I still see two issues here:

  1. Running Scripts/compile-emulate.py breast_tree nearest degrades between the main branch and this. This might be related to the fact that the main branch outputs a leave NID of 32 but in this branch the NID's only go up to 16.
  2. I'm hesitant to merge this branch into the main branch because of the separate module. The reason is that, in the long term, I want to incorporate the changes into the main functionality in the decision_tree module. After that, anyone who used the decision_tree_optimized module will need to change their code as I don't to add any hacks. If your functionality would be available within decision_tree module the adaption would be much more smooth. That said, I'm happy to incorporate your changes in a separate branch, and I indent to merge that in the future to give you credit. Please let me know your thoughts on this.
mkskeller commented 3 months ago

After having another look, the first issue might be related to not calling UpdateState after the last layer.

sandy9999 commented 3 months ago

Hi @mkskeller Thank you for your detailed comments. I understand your concerns, and will try to work with the decision_tree module.

sandy9999 commented 3 months ago

Hi @mkskeller I have updated the PR as discussed. Would this work?

mkskeller commented 1 month ago

I'm afraid there are still a few issues:

  1. decision_tree_optimized still exists, did you mean to delete this?
  2. The changes to decision_tree break all applications thereof, adult, easy_adult, bench-dt, and breast_tree (if changed to decision_tree).