setup_logger(os.path.join(self._tmp_dir, "%s.log" % str(logger_name)))
self._logger = get_logger(logger_name)
if isinstance(metric, str):
metric = STRING_TO_METRIC[metric]
if feat_type is not None and len(feat_type) != X.shape[1]:
raise ValueError("Array feat_type does not have same number of "
"variables as X has features. %d vs %d." %
(len(feat_type), X.shape[1]))
After Change
setup_logger(os.path.join(self._tmp_dir, "%s.log" % str(logger_name)))
self._logger = get_logger(logger_name)
metric = get_metric(metric, task)
if feat_type is not None and len(feat_type) != X.shape[1]:
raise ValueError("Array feat_type does not have same number of "
"variables as X has features. %d vs %d." %