Cleanup Python GPU tests. (#9934)
* Cleanup Python GPU tests. - Remove the use of `gpu_hist` and `gpu_id` in cudf/cupy tests. - Move base margin test into the testing directory.
This commit is contained in:
@@ -1,14 +1,12 @@
|
||||
import sys
|
||||
from typing import Type
|
||||
|
||||
import numpy as np
|
||||
import pytest
|
||||
from test_dmatrix import set_base_margin_info
|
||||
|
||||
import xgboost as xgb
|
||||
from xgboost import testing as tm
|
||||
from xgboost.core import DataSplitMode
|
||||
from xgboost.testing.data import pd_arrow_dtypes, pd_dtypes
|
||||
from xgboost.testing.data import pd_arrow_dtypes, pd_dtypes, run_base_margin_info
|
||||
|
||||
try:
|
||||
import pandas as pd
|
||||
@@ -336,7 +334,7 @@ class TestPandas:
|
||||
np.testing.assert_array_equal(data.get_weight(), w)
|
||||
|
||||
def test_base_margin(self):
|
||||
set_base_margin_info(pd.DataFrame, xgb.DMatrix, "hist")
|
||||
run_base_margin_info(pd.DataFrame, xgb.DMatrix, "cpu")
|
||||
|
||||
def test_cv_as_pandas(self):
|
||||
dm, _ = tm.load_agaricus(__file__)
|
||||
|
||||
Reference in New Issue
Block a user