Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
A
alpha-mind
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dr.李
alpha-mind
Commits
82bf3388
Commit
82bf3388
authored
Apr 01, 2019
by
Dr.李
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slightly loose the assert condition to pass the tests
parent
8c73ccdf
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
treemodel.py
alphamind/model/treemodel.py
+1
-1
test_composer.py
alphamind/tests/model/test_composer.py
+1
-1
No files found.
alphamind/model/treemodel.py
View file @
82bf3388
...
...
@@ -71,7 +71,6 @@ class XGBRegressor(create_model_base('xgboost')):
n_jobs
=
n_jobs
,
missing
=
missing
,
**
kwargs
)
self
.
impl
=
XGBRegressor
.
model_decode
(
self
.
model_encode
())
@
property
def
importances
(
self
):
...
...
@@ -140,6 +139,7 @@ class XGBTrainer(create_model_base('xgboost')):
self
.
early_stopping_rounds
=
early_stopping_rounds
self
.
impl
=
None
self
.
kwargs
=
kwargs
self
.
trained_time
=
None
def
fit
(
self
,
x
:
pd
.
DataFrame
,
y
:
np
.
ndarray
):
if
self
.
eval_sample
:
...
...
alphamind/tests/model/test_composer.py
View file @
82bf3388
...
...
@@ -15,7 +15,7 @@ from alphamind.model.treemodel import XGBClassifier
class
TestComposer
(
unittest
.
TestCase
):
def
_assert_composer_equal
(
self
,
lhs
:
Composer
,
rhs
:
Composer
):
self
.
assertEqual
(
lhs
.
alpha_model
,
rhs
.
alpha_model
)
self
.
assertEqual
(
type
(
lhs
.
alpha_model
),
type
(
rhs
.
alpha_model
)
)
self
.
assertEqual
(
lhs
.
data_meta
,
rhs
.
data_meta
)
def
test_data_meta_persistence
(
self
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment