def process_id_map(mapping_f, disable_primer_check=False, has_barcodes=True, char_replace='_', variable_len_barcodes=False, added_demultiplex_field=None, strip_quotes=True, suppress_stripping=False):
 errors = []
 warnings = []
 (mapping_data, header, comments) = parse_mapping_file(mapping_f, strip_quotes, suppress_stripping)
 sample_id_ix = 0
 desc_ix = (len(header) - 1)
 bc_ix = 1
 linker_primer_ix = 2
 (errors, warnings) = check_header(header, errors, warnings, sample_id_ix, desc_ix, bc_ix, linker_primer_ix, added_demultiplex_field)
 (errors, warnings) = check_data_fields(header, mapping_data, errors, warnings, disable_primer_check, has_barcodes, char_replace, variable_len_barcodes, added_demultiplex_field)
 return (header, mapping_data, comments, errors, warnings)

def process_id_map ( mapping_f , disable_primer_check = False , has_barcodes = True , char_replace = '_' , variable_len_barcodes = False , added_demultiplex_field = None , strip_quotes = True , suppress_stripping = False ) : errors = [ ] warnings = [ ] ( mapping_data , header , comments ) = parse_mapping_file ( mapping_f , strip_quotes , suppress_stripping ) sample_id_ix = 0 desc_ix = ( len ( header ) - 1 ) bc_ix = 1 linker_primer_ix = 2 ( errors , warnings ) = check_header ( header , errors , warnings , sample_id_ix , desc_ix , bc_ix , linker_primer_ix , added_demultiplex_field ) ( errors , warnings ) = check_data_fields ( header , mapping_data , errors , warnings , disable_primer_check , has_barcodes , char_replace , variable_len_barcodes , added_demultiplex_field ) return ( header , mapping_data , comments , errors , warnings )
reads mapping file .