Add an option to use print rather than tqdm for dynesty
Closes #543 (closed)
This is an initial attempt at making the output style a user-specifiable thing.
I implemented three options for print_method
:
-
tqdm
: the default and retains the current behaviour. This is particularly nice when using notebooks astqdm
is able to use widgets to make a nicer progress bar. -
interval-TIME
: this allows the user to specify how often to print the output tosys.stdout
. This uses theprint
built-in. I'm open to using the logger as long as we make sure it gets piped tosys.stdout
. TheTIME
is specified in seconds so interval-10` will print an update once every 10 seconds. - anything else will print to
stdout
using theprint
built-in every iteration.
We could use either the second or third in bilby_pipe
/parallel_bilby
as the expectation there is that stdout
is a file, not a terminal.
I'm open to opinions.
Edited by Colm Talbot