-
Notifications
You must be signed in to change notification settings - Fork 31
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
What does epsilon do in code?It seems to have caused an overflow #2
Comments
Labs-Federated-Learning-clustered_sampling\py_func\clustering.py:165: RuntimeWarning: It did overflow |
Hi yao9261, Thank you for you interest in this work. Overflow issue. epsilon. You are here discussing the implementation of Algorithm 2. In our work, we consider that the input is {n_i} while in |
To begin with, thank you for your reply! That means a lot to me. More details: But it’s okay, now I understand how it works here. And I think my error may caused by my running environment, Win10 and Pycharm. I am trying to study how to improve FL with Non-IID data through clustering. Your article really inspired me a lot. Thank you very much for your reply again! |
I ran FL.py with the parameters you gave and the training went through. We have not been able to isolate your problem yet but epsilon should not be related to it. Thank you for your positive feedback on this work. Feel free to contact me by e-mail (included in the paper) if you want to discuss the theoretical aspect of this work. |
Overflow will not cause an error. It is just a warning. Warning messege: Training can still be done after the overflow occurs, but the sorting and selection of clusters will be meaningless. At this time, cluster sampling cannot accelerate convergence. When epsilon = 10^10, overflow occurs from the first round. There shouldn't be an overflow problem with int in python 3, and I am also very surprised why it overflows. |
Hi, I am a graduate student and I am very interested in your thesis. I have some difficulties when trying to run the code.
clustering.py line 162-165:
for i in range(n_clusters):
pop_clusters[i, 0] = i + 1
for client in np.where(clusters == i + 1)[0]:
pop_clusters[i, 1] += int(weights[client] * epsilon * n_sampled)
In the process of debugging, I found that some pop_clusters[i, 1] became a negative number after calculate, and I suspected that it might be overflow.
And I don’t understand what is the role of “epsilon” here. Could you help me understand it?
The text was updated successfully, but these errors were encountered: