You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by tq...@apache.org on 2020/10/11 18:36:54 UTC
[incubator-tvm] branch master updated: filter out error features
(#5952)
This is an automated email from the ASF dual-hosted git repository.
tqchen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-tvm.git
The following commit(s) were added to refs/heads/master by this push:
new 1097ba1 filter out error features (#5952)
1097ba1 is described below
commit 1097ba1a25a21af84b2e837935fc93b735a652ec
Author: Meteorix <lx...@gmail.com>
AuthorDate: Mon Oct 12 02:36:42 2020 +0800
filter out error features (#5952)
---
python/tvm/autotvm/tuner/xgboost_cost_model.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/python/tvm/autotvm/tuner/xgboost_cost_model.py b/python/tvm/autotvm/tuner/xgboost_cost_model.py
index 7b9df1c..9fd19ec 100644
--- a/python/tvm/autotvm/tuner/xgboost_cost_model.py
+++ b/python/tvm/autotvm/tuner/xgboost_cost_model.py
@@ -245,6 +245,8 @@ class XGBoostCostModel(CostModel):
else:
raise RuntimeError("Invalid feature type: " + self.fea_type)
res = pool.map(feature_extract_func, data)
+ # filter out None output, which is caused by extract exception
+ res = [r for r in res if r is not None]
# filter out feature with different shapes
fea_len = len(self._get_feature([0])[0])