-
Notifications
You must be signed in to change notification settings - Fork 283
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
Using binary secret sharing for comparison? #494
Comments
There is no way to do comparison using arithmetic secret sharing from my understanding. It must be already being converted to binary, if it works with arithmetic secret sharing. |
Hello In paper crypten crypten, that say:
I observe functions Thank you! |
If you use a comparison operator for arithmetic secret sharing (e.g., a < b?), it internally subtracts the value and compare it with zero (a - b < 0?), which involves arithmetic operation (a-b), and then comparison. It first does the arithmetic operation and then convert to binary secret sharing, and perform comparison with zero, and convert the result back to arithmetic secret sharing. So, to answer your question:
|
I got it. Thank you! |
Hello,
From what I understood, binary secret sharing should be used for logical operations, such as comparisons, as this would be faster.
Given the code below, which simply compares two numbers
x
andy
using both binary secret sharing, I receive an error:The error is:
AttributeError: 'BinarySharedTensor' object has no attribute 'sub'
How should binary secret sharing be used for comparisons? It seems that only arithmetic secret sharing is working. What am I missing?
The text was updated successfully, but these errors were encountered: