Closed aphalo closed 6 months ago
The bottleneck was caused by the use of an unnecessarily wide moving window for the computation. Reducing it to about 20 nm from 150 nm, decreased the processing time from 26 ms to about 8 ms per spectrum. Further reduction of the window size may be tolerable, but could make it necessary to recompute the calibration coefficients.
To my surprise, after other improvements in performance, the performance bottleneck in function
s_irrad_corrected()
is in the call to the C++-coded function for the tail correction of the slit function. Improving this has low priority as the processing time is around 26 ms per spectrum.