Skip to content

Add an option to use print rather than tqdm for dynesty

Colm Talbot requested to merge dynesty-print into master

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 as tqdm 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 to sys.stdout. This uses the print built-in. I'm open to using the logger as long as we make sure it gets piped to sys.stdout. The TIME is specified in seconds so interval-10` will print an update once every 10 seconds.
  • anything else will print to stdout using the print 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

Merge request reports