-
-
Notifications
You must be signed in to change notification settings - Fork 93
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
Allow comma seperated list of names for inits, output files, etc. #1255
Comments
what if the comma separated list of file names doesn't match the number of chains? this makes more work for the user, since they'd need to pass in lists of file names for the output file and diagnostic file? |
Then we would throw an error
Yes that's why we originally didn't do it. But now upstream packages are just writing the bash command with code so it might be easier for them to just supply the actual filenames instead of having to deal with the shorthand logic |
you're suggesting that the code that generates the command supply full file names? this feels like pushing bumps around under a rug. it's the same amount of work for the interfaces. as for CmdStan, don't want to touch the argument parser, which can't really handle lists - it would have to do a buncha processing to grab the filenames. |
The parser wouldn't need to handle lists, just return the string which we can then I think it would be nice from a cmdstan standpoint to remove all the implicit filename stuff we currently do. This would definitely create more work for users on the command line, but lead to more obvious behavior once they do that work. The in-code interfaces need to generate the names anyway to read them, so it's 0 extra effort for those |
Summary:
Right now we have a very ad hoc approach to figure out the names for multiple chains. For a users id and the number of chains they have requested we just append
_1..{num_chains}
to the end of the file name for output. For inits we look if the user gave us a file ending with_id
. and if so we search fornum_chain
arguments ending in_1...{num_chains}
.We chose this scheme at the time because I was calling cmdstan myself from the terminal and it was a clever shorthand so I didn't have to write out a bunch of file names.
But with the number of upstream packages calling Stan it might be easier for them to programatically generate the names of the files they want and pass a comma separated list of file names.
Additional Information:
Provide any additional information here.
Current Version:
v2.34.1
The text was updated successfully, but these errors were encountered: