Skip to content

Commit

Permalink
updated blend_models test and create test_stack_models.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Moez Ali committed May 9, 2020
1 parent 2525193 commit b7f81d6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pycaret/tests/test_blend_models.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import os, sys
sys.path.insert(0, os.path.abspath(".."))

#compare_models_test
#blend_models_test
import pytest
import pycaret.regression
import pycaret.datasets

def test_compare_models():
def test_blend_models():
data = pycaret.datasets.get_data('boston')
data = data.head(50)
reg1 = pycaret.regression.setup(data, target='medv',silent=True, html=False, session_id=123)
Expand Down
15 changes: 15 additions & 0 deletions pycaret/tests/test_stack_models.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import os, sys
sys.path.insert(0, os.path.abspath(".."))

#stack_models_test
import pytest
import pycaret.regression
import pycaret.datasets

def test_stack_models():
data = pycaret.datasets.get_data('boston')
data = data.head(50)
reg1 = pycaret.regression.setup(data, target='medv',silent=True, html=False, session_id=123)
estimator_list = pycaret.regression.compare_models(blacklist = ['catboost', 'tr'], n_select=3, verbose=False) #select top 3
stacker = pycaret.regression.stack_models(estimator_list=estimator_list, improve_only=False, verbose=False)
assert type(stacker) == list

0 comments on commit b7f81d6

Please sign in to comment.