fix lint errors in core
This commit is contained in:
parent
7be496a051
commit
a7e79e089b
@ -2,7 +2,7 @@
|
||||
|
||||
ignore=tests
|
||||
|
||||
disable=invalid-name,wildcard-import,too-many-arguments,attribute-defined-outside-init,no-member,too-many-instance-attributes,too-few-public-methods,import-error,super-on-old-class,fixme,too-many-nested-blocks
|
||||
unexpected-special-method-signature,too-many-nested-blocks,consider-using-enumerate
|
||||
|
||||
dummy-variables-rgx=(unused|)_.*
|
||||
|
||||
|
||||
@ -523,7 +523,7 @@ class DMatrix(object):
|
||||
feature_names : list or None
|
||||
Labels for features. None will reset existing feature names
|
||||
"""
|
||||
if not feature_names is None:
|
||||
if feature_names is not None:
|
||||
# validate feature name
|
||||
if not isinstance(feature_names, list):
|
||||
feature_names = list(feature_names)
|
||||
@ -554,7 +554,7 @@ class DMatrix(object):
|
||||
feature_types : list or None
|
||||
Labels for features. None will reset existing feature names
|
||||
"""
|
||||
if not feature_types is None:
|
||||
if feature_types is not None:
|
||||
|
||||
if self.feature_names is None:
|
||||
msg = 'Unable to set feature types before setting names'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user