Skip to content

Commit

Permalink
Black formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
AnotherSamWilson committed Jul 26, 2024
1 parent 444f88b commit 62f36c0
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions tests/test_ImputationKernel.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,37 +222,37 @@ def make_and_test_kernel(**kwargs):
# Test tuning parameters
kernel.tune_parameters(
optimization_steps=2,
use_gbdt = True,
use_gbdt=True,
random_state=1,
variable_parameters = {
variable_parameters={
mv[0]: {
"min_data_in_leaf": (1, 10),
"min_data_in_leaf": (1, 10),
"cat_l2": 0.5,
}
},
extra_trees=[True, False],
)
op = kernel.optimal_parameters[mv[0]]
assert 'extra_trees' in list(op)
assert op['cat_l2'] == 0.5
assert 1 <= op['min_data_in_leaf'] <= 10
assert "extra_trees" in list(op)
assert op["cat_l2"] == 0.5
assert 1 <= op["min_data_in_leaf"] <= 10

kernel.tune_parameters(
optimization_steps=2,
use_gbdt = False,
use_gbdt=False,
random_state=1,
variable_parameters = {
variable_parameters={
mv[0]: {
"min_data_in_leaf": (1, 10),
"min_data_in_leaf": (1, 10),
"cat_l2": 0.5,
}
},
extra_trees=[True, False],
)
op = kernel.optimal_parameters[mv[0]]
assert 'extra_trees' in list(op)
assert op['cat_l2'] == 0.5
assert 1 <= op['min_data_in_leaf'] <= 10
assert "extra_trees" in list(op)
assert op["cat_l2"] == 0.5
assert 1 <= op["min_data_in_leaf"] <= 10

return kernel

Expand Down

0 comments on commit 62f36c0

Please sign in to comment.