(self)
Reset progress.
Reset progress.
Reset progress .
def reset(self):
    ''' Reset progress. '''
    if self.select_by_spk:
      logging.info('Shuffling spk keys ...')
      self.spk_keys = []
      for index in range(self.num_repeats):
        temp_keys = list(self.meta.spks.keys())
        random.shuffle(temp_keys)
        self.spk_keys.extend(temp_keys)
    else:
      logging.info('Shuffling utt keys ...')
      self.utt_keys = []
      for index in range(self.num_repeats):
        temp_keys = list(self.meta.utts.keys())
        random.shuffle(temp_keys)
        self.utt_keys.extend(temp_keys)
def reset ( self ) : if self . select_by_spk : logging . info ( 'Shuffling spk keys ...' ) self . spk_keys = [ ] for index in range ( self . num_repeats ) : temp_keys = list ( self . meta . spks . keys ( ) ) random . shuffle ( temp_keys ) self . spk_keys . extend ( temp_keys ) else : logging . info ( 'Shuffling utt keys ...' ) self . utt_keys = [ ] for index in range ( self . num_repeats ) : temp_keys = list ( self . meta . utts . keys ( ) ) random . shuffle ( temp_keys ) self . utt_keys . extend ( temp_keys )