Filter warnings with more selective np.errstate context