<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def prep_hla(work_dir, sample, calls, hlas, normal_bam, tumor_bam):
 """Convert HLAs into ABSOLUTE format for use with LOHHLA. LOHHLA hard codes names to hla_a, hla_b, hla_c so need to move """

    work_dir = utils.safe_makedir(os.path.join(work_dir, sample, "inputs"))
    hla_file = os.path.join(work_dir, "%s-hlas.txt" % sample)
    with open(calls) as in_handle:
        with open(hla_file, "w") as out_handle:
            next(in_handle)  # header
            for line in in_handle:
                _, _, a, _, _ = line.strip().split(",")
                a1, a2 = a.split(";")
                out_handle.write(get_hla_choice(name_to_absolute(a1), hlas, normal_bam, tumor_bam) + "\n")
                out_handle.write(get_hla_choice(name_to_absolute(a2), hlas, normal_bam, tumor_bam) + "\n")
    return hla_file