2012-03-29 14:34:45 +08:00
|
|
|
import numpy
|
|
|
|
|
from numpy.distutils.misc_util import Configuration
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def configuration(parent_package="", top_path=None):
|
|
|
|
|
config = Configuration("ensemble", parent_package, top_path)
|
2019-04-27 03:14:59 +08:00
|
|
|
|
2012-03-29 14:34:45 +08:00
|
|
|
config.add_extension("_gradient_boosting",
|
2016-11-02 19:57:04 +08:00
|
|
|
sources=["_gradient_boosting.pyx"],
|
2012-03-29 14:34:45 +08:00
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_subpackage("tests")
|
|
|
|
|
|
2019-04-27 03:14:59 +08:00
|
|
|
# Histogram-based gradient boosting files
|
|
|
|
|
config.add_extension(
|
|
|
|
|
"_hist_gradient_boosting._gradient_boosting",
|
|
|
|
|
sources=["_hist_gradient_boosting/_gradient_boosting.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_extension("_hist_gradient_boosting.histogram",
|
|
|
|
|
sources=["_hist_gradient_boosting/histogram.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_extension("_hist_gradient_boosting.splitting",
|
|
|
|
|
sources=["_hist_gradient_boosting/splitting.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_extension("_hist_gradient_boosting._binning",
|
|
|
|
|
sources=["_hist_gradient_boosting/_binning.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_extension("_hist_gradient_boosting._predictor",
|
|
|
|
|
sources=["_hist_gradient_boosting/_predictor.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_extension("_hist_gradient_boosting._loss",
|
|
|
|
|
sources=["_hist_gradient_boosting/_loss.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
2019-08-21 17:22:00 +08:00
|
|
|
config.add_extension("_hist_gradient_boosting.common",
|
|
|
|
|
sources=["_hist_gradient_boosting/common.pyx"],
|
2019-04-27 03:14:59 +08:00
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_extension("_hist_gradient_boosting.utils",
|
|
|
|
|
sources=["_hist_gradient_boosting/utils.pyx"],
|
|
|
|
|
include_dirs=[numpy.get_include()])
|
|
|
|
|
|
|
|
|
|
config.add_subpackage("_hist_gradient_boosting.tests")
|
|
|
|
|
|
2012-03-29 14:34:45 +08:00
|
|
|
return config
|
|
|
|
|
|
|
|
|
|
if __name__ == "__main__":
|
|
|
|
|
from numpy.distutils.core import setup
|
|
|
|
|
setup(**configuration().todict())
|