-
Notifications
You must be signed in to change notification settings - Fork 7
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
ffnet throwing TypeError #3
Comments
Dnia poniedziałek, 22 stycznia 2018 06:54:34 CET Peter Isaac pisze:
I ran into a problem with FFNET today. The exception is below:
TypeError: object of type 'dictionary-keyiterator' has no len()
and is thrown at line 611 of ffnet.py:
n = len(self.graph.predecessors(trg))
The fix I used was to change line 611 of ffnet.py to:
n = len(list(self.graph.predecessors(trg)))
Tanks for reporting. This problem arises when networkx-2.x is installed. I'll
fix it soon...
|
Yeah, I caught the networkx >= 2 link but figured that a simple hack was
better than reverting to an earlier version.
Thanks,
Peter
…On 22 January 2018 at 20:15, Marek Wojciechowski ***@***.***> wrote:
Dnia poniedziałek, 22 stycznia 2018 06:54:34 CET Peter Isaac pisze:
> I ran into a problem with FFNET today. The exception is below:
> TypeError: object of type 'dictionary-keyiterator' has no len()
> and is thrown at line 611 of ffnet.py:
> n = len(self.graph.predecessors(trg))
> The fix I used was to change line 611 of ffnet.py to:
> n = len(list(self.graph.predecessors(trg)))
Tanks for reporting. This problem arises when networkx-2.x is installed.
I'll
fix it soon...
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#3 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AGckibNWyhe7QqpA66qxODks1S13OPxGks5tNFGjgaJpZM4RmMol>
.
--
Peter Isaac
Ph: +61 3 59685998
Mob: 0429053970
Skype: pisaac.ozflux
Email: pisaac.ozflux@gmail.com
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi mrkwjc,
Many thanks for all your work on FFNET over the years.
I ran into a problem with FFNET today. The exception is below:
TypeError: object of type 'dictionary-keyiterator' has no len()
and is thrown at line 611 of ffnet.py:
n = len(self.graph.predecessors(trg))
The fix I used was to change line 611 of ffnet.py to:
n = len(list(self.graph.predecessors(trg)))
Other details are:
OS: Ubuntu 14.04
Python: Anaconda 2.7 (I can supply a list of installed packages and version numbers if required)
Cheers,
Peter
The text was updated successfully, but these errors were encountered: