desihub / specsim

Quick simulations of spectrograph response
2 stars 9 forks source link

RuntimeWarning: overflow encountered in double_scalars #119

Closed moustakas closed 2 years ago

moustakas commented 2 years ago

The desisim/test/test_quickspectra.py unit test yields the following non-catastrophic warning based on the nominal desi configuration file, which I've tracked down to when the specsim.observation.Observation._update_model() method is called. Would be nice to fix this.

/Users/ioannis/opt/anaconda3/envs/desi/lib/python3.8/site-packages/astropy/time/utils.py:179: RuntimeWarning: overflow encountered in double_scalars
  c = 134217729. * a  # 2**27+1.
/Users/ioannis/opt/anaconda3/envs/desi/lib/python3.8/site-packages/astropy/time/utils.py:181: RuntimeWarning: invalid value encountered in double_scalars
  ah = c - abig