optuna.distributions.check_distribution_compatibility
- optuna.distributions.check_distribution_compatibility(dist_old, dist_new)[源代码]
A function to check compatibility of two distributions.
Note that this method is not supposed to be called by library users.
- 参数
dist_old (optuna.distributions.BaseDistribution) – A distribution previously recorded in storage.
dist_new (optuna.distributions.BaseDistribution) – A distribution newly added to storage.
- 返回
True denotes given distributions are compatible. Otherwise, they are not.
- 引发
ValueError – If different distribution kinds are set to
dist_old
anddist_new
, ordist_old.choices
doesn’t matchdist_new.choices
forCategoricalDistribution
.- 返回类型
None