def METHOD_NAME(self, dump_file):
    with open(dump_file, 'w', encoding='utf8') as fout:
        for obj in self.lists:
            if hasattr(obj, 'get') and obj.get('tokens', None) is not None:
                assert 'key' in obj
                assert 'wav' in obj
                assert 'txt' in obj
                assert len(obj['tokens']) == len(obj['txt'])
                dump_line = obj['key'] + ':\n'
                dump_line += '\t' + obj['wav'] + '\n'
                dump_line += '\t'
                for token, idx in zip(obj['tokens'], obj['txt']):
                    dump_line += '%s(%d) ' % (token, idx)
                dump_line += '\n\n'
                fout.write(dump_line)
            else:
                infos = json.loads(obj)
                assert 'key' in infos
                assert 'wav' in infos
                assert 'txt' in infos
                dump_line = infos['key'] + ':\n'
                dump_line += '\t' + infos['wav'] + '\n'
                dump_line += '\t'
                dump_line += '%d' % infos['txt']
                dump_line += '\n\n'
                fout.write(dump_line)