Three Factors to Improve Out-of-Distribution Detection