Closed teuben closed 6 years ago
correction: the last example I gave overwrites and keeps the streaks in the directory...
Streak(ff,output_path=ff[:ff.rfind('.')])
is the desired default.
That is actually a desired result since the original comment for the output_path of Streak class is: ''' output_path: str, optional Path to save figures and output files. If None, the base filename is used as the folder name. '''
Nevertheless, I agree that your suggestion makes more sense than the original code. I'll implement this in the next release.
good idea. Imagine is somebody was using x1 also for the directory name, i.e. x1/x1.fits, x1/x2.fits.... that might get confusing.
if I use Streak('abc/x1.fits') it will dump the products in a local directory named 'x1', instead of the desired 'abc/x1', which I believe is an unexpected result. Alternatively one can do Streak('abc/x1.fits',output_path='abc') but I'm arguing the default behavior of output_path=None is unexpected.