brown-bnc / xnat-tools

BNC Tools for accessing and processing data from XNAT
6 stars 2 forks source link

Set up logger for Heudiconv related functions #36

Open mirestrepo opened 4 years ago

mirestrepo commented 4 years ago

Should we be using the logger for this stuff? Why are we printing instead?

Originally posted by @broarr in https://github.com/brown-bnc/xnat-tools/diffs

broarr commented 4 years ago

I want this one! I'm gonna take a crack at it this afternoon

broarr commented 4 years ago

38 is my first attempt. The heudiconv functions look a little ugly, but it does work

broarr commented 4 years ago

It's double printing things from heudiconv. Not sure why. I'll take a peek at a later point

mirestrepo commented 4 years ago

Also, I was running with Fae today and saw that logs are not printed until the processing has finished. I don't recall that behavior when I run the tests, but we should get them streaming... I wonder if there is anything different in the stdout in Oscar...

broarr commented 4 years ago

This is likely a buffering behavior from the terminal. Different OSs will do different things when it comes to buffering output. You can try export PYTHONUNBUFFERED=1

https://docs.python.org/3/using/cmdline.html#envvar-PYTHONUNBUFFERED

On Thu, Jul 16, 2020 at 5:43 PM Maria Isabel Restrepo < notifications@github.com> wrote:

Also, I was running with Fae today and saw that logs are not printed until the processing has finished. I don't recall that behavior when I run the tests, but we should get them streaming... I wonder if there is anything different in the stdout in Oscar...

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/brown-bnc/xnat-tools/issues/36#issuecomment-659690918, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALZRKTSCZU5LM4P47LRICNLR35YBJANCNFSM4OPARRRQ .

-- http://ccv.brown.edu/ Bradford N. Roarr https://github.com/broarr https://directory.brown.edu/uuid/0adf6ab4-8d56-410a-8ac6-4b4ca136a534

Senior Research Software Engineer Data & Visualization Center for Computation and Visualization Brown University | CIS