-
Notifications
You must be signed in to change notification settings - Fork 10
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
Misleading method name from_list
#47
Comments
I agree that this is slightly misleading. |
Nicely spotted! That's my bad. I really like avoiding the two How about adding a check so we can work with both lists and varargs? That's also what PyTorch is doing, I believe. |
I would also prefer renaming it to Pytorch (at least my possibly outdated version) raises an error when passing a list:
I also don't mind supporting both, though. |
I'm really sorry but I must be missing something. Could you please specify how #50 addresses this issue? Neither the name nor the call signature of the |
You're entirely correct that the PR doesn't change the name of the method. But it allows the Line 44 in 464de9f
from_list doesn't even take lists.
I'm sympathetic if you wish to rename the method if you think there's a better name. I believe you suggested |
Yeah, sorry for the late reply. I think this is fine. |
The name of the method
NIRGraph.from_list
suggests that a list is expected as input:In reality however it expects the nodes to be passed as individual arguments:
I suggest the method to be either renamed to something like "Compose" or "Sequential", or to change it such that it accepts a list.
The text was updated successfully, but these errors were encountered: