Shortcuts

get_trainer_hpo_config

pybind11_ke.config.get_trainer_hpo_config() dict[str, dict[str, Any]][源代码]

返回 Trainer 的默认超参数优化配置。

默认配置为:

parameters_dict = {
        'trainer': {
                'value': 'Trainer'
        },
        'epochs': {
                'value': 10000
        },
        'lr': {
                'distribution': 'uniform',
                'min': 1e-5,
                'max': 1.0
        },
        'opt_method': {
                'values': ['adam', 'adagrad', 'sgd']
        },
        'valid_interval': {
                'value': 100
        },
        'log_interval': {
                'value': 100
        },
        'save_path': {
                'value': './model.pth'
        },
        'use_early_stopping': {
                'value': True
        },
        'metric': {
                'value': 'hits@10'
        },
        'patience': {
                'value': 2
        },
        'delta': {
                'value': 0.0001
        },
}
返回:

Trainer 的默认超参数优化配置

返回类型:

dict[str, dict[str, Any]]

Docs

Access comprehensive developer documentation for Pybind11-OpenKE

View Docs