Make HostDeviceVector single gpu only (#4773)
* Make HostDeviceVector single gpu only
This commit is contained in:
@@ -23,7 +23,7 @@ class TestGPULinear(unittest.TestCase):
|
||||
@pytest.mark.skipif(**tm.no_sklearn())
|
||||
def test_gpu_coordinate(self):
|
||||
parameters = self.common_param.copy()
|
||||
parameters['n_gpus'] = [1]
|
||||
parameters['gpu_id'] = [0]
|
||||
for param in test_linear.parameter_combinations(parameters):
|
||||
results = test_linear.run_suite(
|
||||
param, 150, self.datasets, scale_features=True)
|
||||
|
||||
@@ -21,7 +21,7 @@ datasets = ["Boston", "Cancer", "Digits", "Sparse regression",
|
||||
|
||||
class TestGPU(unittest.TestCase):
|
||||
def test_gpu_hist(self):
|
||||
test_param = parameter_combinations({'n_gpus': [1], 'max_depth': [2, 8],
|
||||
test_param = parameter_combinations({'gpu_id': [0], 'max_depth': [2, 8],
|
||||
'max_leaves': [255, 4],
|
||||
'max_bin': [2, 256],
|
||||
'grow_policy': ['lossguide']})
|
||||
@@ -38,8 +38,7 @@ class TestGPU(unittest.TestCase):
|
||||
|
||||
@pytest.mark.mgpu
|
||||
def test_specified_gpu_id_gpu_update(self):
|
||||
variable_param = {'n_gpus': [1],
|
||||
'gpu_id': [1],
|
||||
variable_param = {'gpu_id': [1],
|
||||
'max_depth': [8],
|
||||
'max_leaves': [255, 4],
|
||||
'max_bin': [2, 64],
|
||||
|
||||
@@ -63,7 +63,7 @@ class TestGPU(unittest.TestCase):
|
||||
'nthread': 0,
|
||||
'eta': 1,
|
||||
'verbosity': 3,
|
||||
'n_gpus': 1,
|
||||
'gpu_id': 0,
|
||||
'objective': 'binary:logistic',
|
||||
'max_bin': max_bin,
|
||||
'eval_metric': 'auc'}
|
||||
|
||||
Reference in New Issue
Block a user