Skip to content

Commit

Permalink
fix: CI fail
Browse files Browse the repository at this point in the history
  • Loading branch information
bbayukari committed Jun 19, 2024
1 parent 8cbe1e7 commit 0cf2dcc
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 13 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": null,
"id": "1ac67c32",
"metadata": {},
"outputs": [],
"source": [
"%matplotlib inline"
]
},
{
"cell_type": "markdown",
"id": "7f5e5d54",
Expand Down Expand Up @@ -516,4 +526,4 @@
},
"nbformat": 4,
"nbformat_minor": 5
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"id": "f540b29b",
"metadata": {},
"source": [
"# Poisson Regression with Identity link"
"# multiple response non-negativity identity link Poisson model"
]
},
{
Expand Down Expand Up @@ -414,7 +414,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.14"
"version": "3.10.13"
}
},
"nbformat": 4,
Expand Down
2 changes: 1 addition & 1 deletion pybind11
Submodule pybind11 updated 139 files
10 changes: 2 additions & 8 deletions pytest/test_args.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@
def test_numeric_solver(model, solver_creator):
from skscope.numeric_solver import convex_solver_BFGS

solver = solver_creator(
model["n_features"], model["n_informative"], numeric_solver=convex_solver_BFGS
)
solver = solver_creator(model["n_features"], model["n_informative"], numeric_solver=convex_solver_BFGS)
solver.solve(model["loss"], jit=True)

assert set(model["support_set"]) == set(solver.get_support())
Expand Down Expand Up @@ -169,9 +167,7 @@ def test_scope_hessian():


def test_scope_dynamic_max_exchange_num():
solver = ScopeSolver(
linear["n_features"], linear["n_informative"], is_dynamic_max_exchange_num=False
)
solver = ScopeSolver(linear["n_features"], linear["n_informative"], is_dynamic_max_exchange_num=False)
solver.solve(linear["loss"], jit=True)

assert set(linear["support_set"]) == set(solver.support_set)
Expand All @@ -188,7 +184,6 @@ def test_scope_args():
path_type="gs",
important_search=1,
preselect=[linear["support_set"][0]],
console_log_level="error",
)
solver.solve(linear["loss"], jit=True)

Expand All @@ -200,6 +195,5 @@ def test_scope_args():
sample_size=linear["n_samples"],
cv=2,
split_method=lambda data, indeices: (data[0][indeices], data[1][indeices]),
file_log_level="error",
)
solver.solve(linear["loss_data"], data=linear["data"])
3 changes: 2 additions & 1 deletion skscope/solver.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,8 @@ def _set_log_level(console_log_level, file_log_level, log_file_name):
if not isinstance(log_file_name, str):
raise ValueError("log_file_name must be a string")

_scope.init_spdlog(console_log_level, file_log_level, log_file_name)
if console_log_level < 6 or file_log_level < 6:
_scope.init_spdlog(console_log_level, file_log_level, log_file_name)

def solve(
self,
Expand Down

0 comments on commit 0cf2dcc

Please sign in to comment.