Made --weights_file compatible with --outfile