def split_fasta_on_sample_ids_to_dict(seqs):
 result = {}
 for (sample_id, seq_id, seq) in split_fasta_on_sample_ids(seqs):
  try:
   result[sample_id].append((seq_id, seq))
  except KeyError:
   result[sample_id] = [(seq_id, seq)]
 return result

def split_fasta_on_sample_ids_to_dict ( seqs ) : result = { } for ( sample_id , seq_id , seq ) in split_fasta_on_sample_ids ( seqs ) : try : result [ sample_id ] . append ( ( seq_id , seq ) ) except KeyError : result [ sample_id ] = [ ( seq_id , seq ) ] return result
return split_fasta_on_sample_ids as {sample_id: [ .