rwesson / ALFA

Automated Line Fitting Algorithm
http://www.nebulousresearch.org/codes/alfa/
GNU General Public License v3.0
12 stars 6 forks source link

Fitting stops soon after 99999 spectra #11

Closed weiaip closed 7 years ago

weiaip commented 7 years ago

I am currently trying to fit a 2D dataset with 243891 rows and discovered that ALFA stops soon after reaching 100000 spectra, with this message:

            (thread 35) : skipped row  *****
            (thread 35) : skipped row  *****
            (thread 35) : skipped row  *****
            (thread 35) : skipped row  *****
            (thread 35) : skipped row  *****
At line 225 of file spectralfit.f90 (unit = 103, file = '')
Fortran runtime error: File already opened in another unit
            (thread 35) : skipped row  *****
            (thread 35) : skipped row  *****

This is with version v1.0-9-g2fc12c1. This fix should simply be to write filenames with morethan 5 digits if the dataset is larger than 99999 spectra.

rwesson commented 7 years ago

I had not anticipated people fitting files that large! I have now fixed the code so that file names have enough digits to properly write out all the fitted spectra.

eb6bafca0fa2aa58c68ac9773d6259db19135a9f