Support more input types for categorical data. (#7220)
* Support more input types for categorical data. * Shorten the type name from "categorical" to "c". * Tests for np/cp array and scipy csr/csc/coo. * Specify the type for feature info.
This commit is contained in:
@@ -83,7 +83,7 @@ class FeatureMap {
|
||||
if (!strcmp("q", tname)) return kQuantitive;
|
||||
if (!strcmp("int", tname)) return kInteger;
|
||||
if (!strcmp("float", tname)) return kFloat;
|
||||
if (!strcmp("categorical", tname)) return kCategorical;
|
||||
if (!strcmp("c", tname)) return kCategorical;
|
||||
LOG(FATAL) << "unknown feature type, use i for indicator and q for quantity";
|
||||
return kIndicator;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user