jasonfrowe / neossat

Source Code related to CSA's NEOSSat Mission to extract Photometry.
GNU General Public License v3.0
3 stars 1 forks source link

dark scaling #27

Open jasonfrowe opened 2 years ago

jasonfrowe commented 2 years ago

Errors with darkscaling should not interrupt bulk processing. Should instead spit a warning and skip problem file.


RemoteTraceback Traceback (most recent call last) RemoteTraceback: """ Traceback (most recent call last): File "/usr/lib64/python3.7/multiprocessing/pool.py", line 121, in worker result = (True, func(*args, **kwds)) File "/home/rowe/Documents/python/NEOSSat_devel/neossat/improcess.py", line 912, in lightprocess_save scidata_cord = clean_sciimage(filename, darkavg, xsc, ysc, xov, yov, snrcut, fmax, xoff, yoff, T, info, bpix, darkmode) File "/home/rowe/Documents/python/NEOSSat_devel/neossat/improcess.py", line 853, in cleansciimage newdark, , _ = scale_image_range(darkavg, scidata_cor) File "/home/rowe/Documents/python/NEOSSat_devel/neossat/improcess.py", line 232, in scale_image_range raise ValueError(msg) ValueError: Too few good pixels to scale image, at least 50.0% of pixels are needed. """

The above exception was the direct cause of the following exception:

ValueError Traceback (most recent call last)

in 5 snrcut,fmax,xoff,yoff,T,bpix,darkmode,),callback=barupdate)\ 6 for i in range(len(lightlist))] ----> 7 saveall = [p.get() for p in results] 8 pool.close() 9 pool.join() in (.0) 5 snrcut,fmax,xoff,yoff,T,bpix,darkmode,),callback=barupdate)\ 6 for i in range(len(lightlist))] ----> 7 saveall = [p.get() for p in results] 8 pool.close() 9 pool.join() /usr/lib64/python3.7/multiprocessing/pool.py in get(self, timeout) 655 return self._value 656 else: --> 657 raise self._value 658 659 def _set(self, i, obj): ValueError: Too few good pixels to scale image, at least 50.0% of pixels are needed.
jasonfrowe commented 2 years ago

This happens with using darkmode='range'.