Skip to content

Commit

Permalink
remove type annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
glemaitre committed Dec 8, 2024
1 parent 879aea6 commit 4e4ca84
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions python-package/lightgbm/_sklearn_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
import platform
import sys
from dataclasses import dataclass, field
from typing import Callable, Literal

import sklearn
from sklearn.utils._param_validation import validate_parameter_constraints
Expand Down Expand Up @@ -586,11 +585,11 @@ def check_estimator(
estimator=None,
generate_only=False,
*,
legacy: bool = True,
expected_failed_checks: dict[str, str] | None = None,
on_skip: Literal["warn"] | None = "warn",
on_fail: Literal["raise", "warn"] | None = "raise",
callback: Callable | None = None,
legacy=True,
expected_failed_checks=None,
on_skip="warn",
on_fail="raise",
callback=None,
):
# legacy, on_skip, on_fail, and callback are not supported and ignored
from sklearn.utils.estimator_checks import check_estimator
Expand All @@ -603,8 +602,8 @@ def check_estimator(
def parametrize_with_checks(
estimators,
*,
legacy: bool = True,
expected_failed_checks: Callable | None = None,
legacy=True,
expected_failed_checks=None,
):
# legacy is not supported and ignored
from sklearn.utils.estimator_checks import parametrize_with_checks
Expand Down

0 comments on commit 4e4ca84

Please sign in to comment.