Feature interaction for GPU Hist. (#4534)
* GPU hist Interaction Constraints. * Duplicate related parameters. * Add tests for CPU interaction constraint. * Add better error reporting. * Thorough tests.
This commit is contained in:
17
tests/python-gpu/test_gpu_interaction_constraints.py
Normal file
17
tests/python-gpu/test_gpu_interaction_constraints.py
Normal file
@@ -0,0 +1,17 @@
|
||||
import numpy as np
|
||||
import unittest
|
||||
import sys
|
||||
sys.path.append("tests/python")
|
||||
# Don't import the test class, otherwise they will run twice.
|
||||
import test_interaction_constraints as test_ic
|
||||
rng = np.random.RandomState(1994)
|
||||
|
||||
|
||||
class TestGPUInteractionConstraints(unittest.TestCase):
|
||||
cputest = test_ic.TestInteractionConstraints()
|
||||
|
||||
def test_interaction_constraints(self):
|
||||
self.cputest.test_interaction_constraints(tree_method='gpu_hist')
|
||||
|
||||
def test_training_accuracy(self):
|
||||
self.cputest.test_training_accuracy(tree_method='gpu_hist')
|
||||
Reference in New Issue
Block a user