8f91b274aa5de0bfb6faf906024eeb24f1ff9a4c,tests/trial_tests/test_trial.py,,test_suggest_discrete_uniform_range,#,330
Before Change
mock = Mock()
mock.side_effect = lambda study, trial, param_name, distribution: distribution.low
with patch.object(sampler, "sample_independent", mock) as mock_object:
study = create_study(storage_init_func(), sampler=sampler)
trial = Trial(study, study._storage.create_new_trial(study._study_id))
with pytest.warns(UserWarning):
x = trial.suggest_discrete_uniform(
After Change
// Check upper endpoints.
mock = Mock()
mock.side_effect = lambda study, trial, param_name, distribution: distribution.high
with patch.object(sampler, "sample_independent", mock) as mock_object, StorageSupplier(
storage_mode
) as storage:
study = create_study(storage=storage, sampler=sampler)
trial = Trial(study, study._storage.create_new_trial(study._study_id))
with pytest.warns(UserWarning):
x = trial.suggest_discrete_uniform(
In pattern: SUPERPATTERN
Frequency: 5
Non-data size: 7
Instances
Project Name: pfnet/optuna
Commit Name: 8f91b274aa5de0bfb6faf906024eeb24f1ff9a4c
Time: 2021-02-27
Author: k_nzw@klis.tsukuba.ac.jp
File Name: tests/trial_tests/test_trial.py
Class Name:
Method Name: test_suggest_discrete_uniform_range
Project Name: pfnet/optuna
Commit Name: 8f91b274aa5de0bfb6faf906024eeb24f1ff9a4c
Time: 2021-02-27
Author: k_nzw@klis.tsukuba.ac.jp
File Name: tests/trial_tests/test_trial.py
Class Name:
Method Name: test_suggest_low_equals_high
Project Name: pfnet/optuna
Commit Name: 8f91b274aa5de0bfb6faf906024eeb24f1ff9a4c
Time: 2021-02-27
Author: k_nzw@klis.tsukuba.ac.jp
File Name: tests/trial_tests/test_trial.py
Class Name:
Method Name: test_suggest_int_log
Project Name: pfnet/optuna
Commit Name: 8f91b274aa5de0bfb6faf906024eeb24f1ff9a4c
Time: 2021-02-27
Author: k_nzw@klis.tsukuba.ac.jp
File Name: tests/trial_tests/test_trial.py
Class Name:
Method Name: test_suggest_int_range
Project Name: pfnet/optuna
Commit Name: 8f91b274aa5de0bfb6faf906024eeb24f1ff9a4c
Time: 2021-02-27
Author: k_nzw@klis.tsukuba.ac.jp
File Name: tests/trial_tests/test_trial.py
Class Name:
Method Name: test_relative_parameters