fix for loss_type problem in outside reset base
some cleanup