def read_denoiser_mapping(mapping_fh):
 denoiser_mapping = {}
 for (i, line) in enumerate(mapping_fh):
  if (line == ''):
   continue
  (centroid, members) = line.split(':')
  denoiser_mapping[centroid] = members.split()
 return denoiser_mapping

def read_denoiser_mapping ( mapping_fh ) : denoiser_mapping = { } for ( i , line ) in enumerate ( mapping_fh ) : if ( line == '' ) : continue ( centroid , members ) = line . split ( ':' ) denoiser_mapping [ centroid ] = members . split ( ) return denoiser_mapping
read the cluster mapping file handle mapping_fh: an open file handle to a cluster file .