======================  ===  ===========================================================================================================================================================================================================================================================================
Key                     Bit  Description                                                                                                                                                                                                                                                                
======================  ===  ===========================================================================================================================================================================================================================================================================
DIDNOTUSE               0    Pixel was ignored because it was flagged as DONOTUSE or FORESTAR by the DRP, or as LOW_SPECCOV, LOW_SNR, or NONE_IN_STACK in the binning step.                                                                                                                             
FORESTAR                1    Pixel was ignored because it was flagged as FORESTAR by the DRP.                                                                                                                                                                                                           
LOW_SNR                 2    Pixel was ignored because the S/N estimate of the spectrum was below the set threshold; see header keyword ELFMINSN.                                                                                                                                                       
ARTIFACT                3    Pixel was ignored during the emission-line model fit because it was designated as containing an artifact.                                                                                                                                                                  
OUTSIDE_RANGE           4    Pixel was ignored during the emission-line model fit because it was outside of any emission-line fitting window.                                                                                                                                                           
NOCONTINUUM             5    Pixel did not have any model of the stellar-continuum subtracted.                                                                                                                                                                                                          
INSUFFICIENT_DATA       6    There were insufficient data over the relevant wavelength range to fit the line profile(s).                                                                                                                                                                                
FIT_FAILED              7    Emission-line fit failed according to status returned by scipy.optimize.least_squares.                                                                                                                                                                                     
NEAR_BOUND              8    Emission-line parameter(s) are within at or near the imposed boundaries in parameter space to within the error of the parameter.                                                                                                                                           
UNDEFINED_COVAR         9    Emission-line fit resulted in a covariance matrix with negative values along the diagonal, meaning that the formal error is undefined.  (Need to test, but this should mean that the fit is bad.)                                                                          
EXCLUDED_FROM_MODEL     10   Emission-line fit excluded from the emission-line flux model because the input emission-line database requested it be one of the lines in the fitting window be excluded or one of the following bits were set: INSUFFICIENT_DATA, FIT_FAILED, NEAR_BOUND, UNDEFINED_COVAR.
UNDEFINED_SIGMA         11   Emission-line velocity dispersion is undefined because it was found to be smaller than the instrumental dispersion.                                                                                                                                                        
NON_POSITIVE_CONTINUUM  12   Equivalent width measurements were not computed because the continuum in either the blue or red sidebands was not positive.                                                                                                                                                
NO_FIT                  13   Emission-line or spectrum was not fit.                                                                                                                                                                                                                                     
TPL_PIXELS              14   These pixels were removed to ensure that the number of template spectral pixels was >= the number of fitted object pixels during the stellar-continuum fit.                                                                                                                
TRUNCATED               15   This region was truncated to avoid convolution errors at the edges of the spectral range during the stellar-continuum fit.                                                                                                                                                 
PPXF_REJECT             16   Pixel was rejected during the pPXF fit via the clean parameter.                                                                                                                                                                                                            
MIN_SIGMA               17   The fitted velocity dispersion is at the minimum allowed by pPXF (1/100th of a pixel)                                                                                                                                                                                      
BAD_SIGMA               18   Corrected velocity dispersion is below 0 km/s or above 400 km/s                                                                                                                                                                                                            
MAXITER                 19   The fit optimizer reached the maximum number of iterations during the fit, which may imply failure to converge.                                                                                                                                                            
INVALID_ERROR           20   Pixel ignored because the flux error was invalid.                                                                                                                                                                                                                          
EML_REGION              21   Pixel was ignored during the stellar-continuum fit because it contains an emission-line.                                                                                                                                                                                   
======================  ===  ===========================================================================================================================================================================================================================================================================

