From 5e0d52cb8cf452b8aaba9345d0e6abc68cba220d Mon Sep 17 00:00:00 2001 From: tqchen Date: Thu, 8 May 2014 20:15:23 -0700 Subject: [PATCH] add python o3 --- python/Makefile | 2 +- python/xgboost_python.cpp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/python/Makefile b/python/Makefile index 0db0a1ed0..f21957a2e 100644 --- a/python/Makefile +++ b/python/Makefile @@ -1,6 +1,6 @@ export CC = gcc export CXX = g++ -export CFLAGS = -Wall -msse2 -Wno-unknown-pragmas -fopenmp +export CFLAGS = -Wall -O3 -msse2 -Wno-unknown-pragmas -fopenmp # specify tensor path SLIB = libxgboostpy.so diff --git a/python/xgboost_python.cpp b/python/xgboost_python.cpp index ee80429f8..d5442c8c3 100644 --- a/python/xgboost_python.cpp +++ b/python/xgboost_python.cpp @@ -75,6 +75,7 @@ namespace xgboost{ inline void CheckInit(void){ if(!init_col_){ this->data.InitData(); + init_col_ = true; } utils::Assert( this->data.NumRow() == this->info.labels.size(), "DMatrix: number of labels must match number of rows in matrix"); }