fixed empty weight file bug