def build_job_name(opt):
    """Returns a job title for the results directory."""
    if opt.hp_lambda > 0:
        job_name = f'orojar_{opt.dataset}_nz-{opt.nz}_w-{opt.hp_lambda}'
    elif opt.infogan_lambda > 0:
        job_name = f'infogan_{opt.dataset}_nz-{opt.nz}_inz-{opt.infogan_nz}'
    else:
        job_name = f'progan_{opt.dataset}_nz-{opt.nz}'
    return job_name