<commit_before>from federatedml.protobuf.model_migrate.converter.converter_base import ProtoConverterBase
from federatedml.protobuf.model_migrate.converter.tree_model_converter import HeteroSBTConverter
import os


def get_module_list():
    file_list = os.listdir('../../conf/setting_conf')
    module_list = [s.replace('.json', '') for s in file_list]
    return module_list


def converter_factory(module_name: str) -> ProtoConverterBase:

    module_list = get_module_list()
    if module_name not in module_list:
        raise ValueError('module name "{}" is illegal'.format(module_name))

    if module_name == 'HeteroSecureBoost':
        return HeteroSBTConverter()
    else:
        raise ValueError('this module has no converter')
<commit_msg>remove module list check<commit_after>from federatedml.protobuf.model_migrate.converter.converter_base import ProtoConverterBase
from federatedml.protobuf.model_migrate.converter.tree_model_converter import HeteroSBTConverter
import os


def converter_factory(module_name: str) -> ProtoConverterBase:

    if module_name == 'HeteroSecureBoost':
        return HeteroSBTConverter()
    else:
        raise ValueError('this module has no converter')

{'fraction_non_alphanumeric': 0.08409658617818484, 'fraction_numerical': 0.0, 'mean_word_length': 4.921182266009852, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2010196', 'n_tokens_mistral': 361, 'n_tokens_neox': 348, 'n_words': 79}