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

_nsb.nsb() 2nd argument (nc) can't be converted to int #1

Closed
epiasini opened this issue Jun 22, 2018 · 2 comments
Closed

_nsb.nsb() 2nd argument (nc) can't be converted to int #1

epiasini opened this issue Jun 22, 2018 · 2 comments

Comments

@epiasini
Copy link

Hi,

I used to run this software on a different machine, but following a fresh install I seem to be incurring in the issue below, demonstrated using the simple code example from the project's README. I'm on Python v3.6.5, ndd v0.7 (installed via pip), Numpy v1.14.5, gfortran v7.3.0.

Python 3.6.5 (default, Apr  1 2018, 05:46:30) 
[GCC 7.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import ndd
>>> counts = [7, 3, 5, 8, 9, 1, 3, 3, 1, 0, 2, 5, 2, 11, 4, 23, 5, 0, 8, 0]
>>> entropy_estimate = ndd.entropy(counts)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.6/dist-packages/ndd/nsb.py", line 127, in entropy
    result = estimator(counts, *args)
TypeError: _nsb.nsb() 2nd argument (nc) can't be converted to int

Any idea what could be causing this? Thanks a lot in advance - let me know if there's any extra info I can provide.

@simomarsili
Copy link
Owner

The problem has been fixed in release v0.7.1 (that is already available via pip too).
Try again with the new version. Thank you!

@epiasini
Copy link
Author

Wow, that was fast! one pip install later, I confirm that the issue is solved. Thanks a lot for the speedy fix, and for writing the code in the first place! I'll make sure to cite you if the project I'm working on ends up going anywhere :)

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