-
Notifications
You must be signed in to change notification settings - Fork 6
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
Pass optional arguments #121
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Think I might have inadvertently left comments pending but not submitted...
The main one is that I think we should use LinkedHashMap
instead of HashMap
, since insertion order could matter (even if only through a bug/regression) and I don't see any benefit in allowing HashMap
to mess with this.
Also, defensive copies are cheap relative to the trouble failing to make them might cause us one day.
for (var es : optionalArgs.entrySet()) { | ||
var val = es.getValue(); | ||
NDArray array = null; | ||
switch (val) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, so that's how you do it... wanted to use a switch originally, but didn't know the syntax :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can thank IntelliJ's linting, I just alt-enter stuff and keep it if I think it's better
Add the ability to pass optional arguments to InstanSeg models.
Example:
or equivalently