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

Getting warnings when running the example and errors when running various tests #5

Closed
AlexWink opened this issue Jan 16, 2021 · 1 comment
Assignees

Comments

@AlexWink
Copy link

Hello,
When I run the example in the README.md, I get the warning
"FoolsGold/ML/code/model_aggregator.py:116: RuntimeWarning: divide by zero encountered in log
wv = (np.log(wv / (1 - wv)) + 0.5)" numerous times.
I also tried to run other examples but it turned out the xrange() function is sometimes called and it exists only in python2 which cant run the project because of the used libraries.

@clementfung clementfung self-assigned this Jan 16, 2021
@clementfung
Copy link
Collaborator

Hi Alex,

Thanks for your issue! I just pushed a fix that adds a small epsilon value to the required lines in the FoolsGold algorithm, which should stop the warnings from occurring.

Regarding the Python2 vs Python3 issue, this is something I've been putting off for a bit too long. Since this is a separate change that is a bit bigger, I've opened a separate issue to track Python 3 at #6

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

No branches or pull requests

2 participants