Specify src path for isort. (#8867)
This commit is contained in:
@@ -4,11 +4,11 @@ import numpy as np
|
||||
import pytest
|
||||
from hypothesis import given, settings, strategies
|
||||
from scipy.sparse import csr_matrix
|
||||
from xgboost.data import SingleBatchInternalIter as SingleBatch
|
||||
from xgboost.testing import IteratorForTest, make_batches, non_increasing
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.data import SingleBatchInternalIter as SingleBatch
|
||||
from xgboost.testing import IteratorForTest, make_batches, non_increasing
|
||||
|
||||
pytestmark = tm.timeout(30)
|
||||
|
||||
|
||||
@@ -6,10 +6,10 @@ import pytest
|
||||
import scipy.sparse
|
||||
from hypothesis import given, settings, strategies
|
||||
from scipy.sparse import csr_matrix, rand
|
||||
from xgboost.testing.data import np_dtypes
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.data import np_dtypes
|
||||
|
||||
rng = np.random.RandomState(1)
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import numpy as np
|
||||
import pytest
|
||||
from xgboost.testing.updater import get_basescore
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.updater import get_basescore
|
||||
|
||||
rng = np.random.RandomState(1994)
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import numpy as np
|
||||
import pytest
|
||||
from xgboost.testing.metrics import check_quantile_error
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.metrics import check_quantile_error
|
||||
|
||||
rng = np.random.RandomState(1337)
|
||||
|
||||
|
||||
@@ -5,11 +5,11 @@ import numpy as np
|
||||
import pandas as pd
|
||||
import pytest
|
||||
from scipy import sparse
|
||||
from xgboost.testing.data import np_dtypes, pd_dtypes
|
||||
from xgboost.testing.shared import validate_leaf_output
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.data import np_dtypes, pd_dtypes
|
||||
from xgboost.testing.shared import validate_leaf_output
|
||||
|
||||
|
||||
def run_threaded_predict(X, rows, predict_func):
|
||||
|
||||
@@ -4,6 +4,8 @@ import numpy as np
|
||||
import pytest
|
||||
from hypothesis import given, settings, strategies
|
||||
from scipy import sparse
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost.testing import (
|
||||
IteratorForTest,
|
||||
make_batches,
|
||||
@@ -15,8 +17,6 @@ from xgboost.testing import (
|
||||
)
|
||||
from xgboost.testing.data import np_dtypes
|
||||
|
||||
import xgboost as xgb
|
||||
|
||||
|
||||
class TestQuantileDMatrix:
|
||||
def test_basic(self) -> None:
|
||||
|
||||
@@ -5,6 +5,9 @@ from typing import Any, Dict, List
|
||||
import numpy as np
|
||||
import pytest
|
||||
from hypothesis import given, note, settings, strategies
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.params import (
|
||||
cat_parameter_strategy,
|
||||
exact_parameter_strategy,
|
||||
@@ -12,9 +15,6 @@ from xgboost.testing.params import (
|
||||
)
|
||||
from xgboost.testing.updater import check_init_estimation, check_quantile_loss
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
|
||||
|
||||
def train_result(param, dmat, num_rounds):
|
||||
result = {}
|
||||
|
||||
@@ -3,10 +3,10 @@ from typing import Type
|
||||
import numpy as np
|
||||
import pytest
|
||||
from test_dmatrix import set_base_margin_info
|
||||
from xgboost.testing.data import pd_arrow_dtypes, pd_dtypes
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.data import pd_arrow_dtypes, pd_dtypes
|
||||
|
||||
try:
|
||||
import pandas as pd
|
||||
|
||||
@@ -8,11 +8,11 @@ from typing import Callable, Optional
|
||||
import numpy as np
|
||||
import pytest
|
||||
from sklearn.utils.estimator_checks import parametrize_with_checks
|
||||
from xgboost.testing.shared import get_feature_weights, validate_data_initialization
|
||||
from xgboost.testing.updater import get_basescore
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.testing.shared import get_feature_weights, validate_data_initialization
|
||||
from xgboost.testing.updater import get_basescore
|
||||
|
||||
rng = np.random.RandomState(1994)
|
||||
pytestmark = [pytest.mark.skipif(**tm.no_sklearn()), tm.timeout(30)]
|
||||
|
||||
Reference in New Issue
Block a user