summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkean-smullen-nnl <51930705+kean-smullen-nnl@users.noreply.github.com>2021-02-09 18:12:20 -0500
committerGitHub <noreply@github.com>2021-02-09 23:12:20 +0000
commit32056da93bcbae9b4b6d5bfdf2bd0a3b62e2d3b7 (patch)
treea734da7d853586e921b32b9fb2bd54eb45455174
parent42e8a646600eaac0491347338f2a4780cd5000d1 (diff)
downloadspack-32056da93bcbae9b4b6d5bfdf2bd0a3b62e2d3b7.tar.gz
spack-32056da93bcbae9b4b6d5bfdf2bd0a3b62e2d3b7.tar.bz2
spack-32056da93bcbae9b4b6d5bfdf2bd0a3b62e2d3b7.tar.xz
spack-32056da93bcbae9b4b6d5bfdf2bd0a3b62e2d3b7.zip
New Package: py-xgboost (#21470)
* new python package py-xgboost added * py-xgboost spack style applied * py-xgboost: Addressing PR #21470 comments. Added variant descriptions and fixed scikit-learn when clause
-rw-r--r--var/spack/repos/builtin/packages/py-xgboost/package.py39
1 files changed, 39 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/py-xgboost/package.py b/var/spack/repos/builtin/packages/py-xgboost/package.py
new file mode 100644
index 0000000000..5a12966afe
--- /dev/null
+++ b/var/spack/repos/builtin/packages/py-xgboost/package.py
@@ -0,0 +1,39 @@
+# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+
+from spack import *
+
+
+class PyXgboost(PythonPackage):
+ """XGBoost is an optimized distributed gradient boosting library designed to be
+ highly efficient, flexible and portable."""
+
+ homepage = 'https://xgboost.ai/'
+ pypi = 'xgboost/xgboost-1.3.3.tar.gz'
+
+ version('1.3.3', sha256='397051647bb837915f3ff24afc7d49f7fca57630ffd00fb5ef66ae2a0881fb43')
+
+ variant('pandas', default=False, description='Enable Pandas extensions for training.')
+ variant('scikit-learn', default=False, description='Enable scikit-learn extensions for training.')
+ variant('dask', default=False, description='Enables Dask extensions for distributed training.')
+ variant('plotting', default=False, description='Enables tree and importance plotting.')
+
+ depends_on('cmake', type='build')
+ depends_on('python@3.6:', type=('build', 'run'))
+ depends_on('py-setuptools', type=('build'))
+ depends_on('py-numpy', type=('build', 'run'))
+ depends_on('py-scipy', type=('build', 'run'))
+
+ depends_on('py-pandas', when='+pandas', type=('build', 'run'))
+
+ depends_on('py-scikit-learn', when='+scikit-learn', type=('build', 'run'))
+
+ depends_on('py-dask', when='+dask', type=('build', 'run'))
+ depends_on('py-pandas', when='+dask', type=('build', 'run'))
+ depends_on('py-distributed', when='+dask', type=('build', 'run'))
+
+ depends_on('py-graphviz', when='+plotting', type=('build', 'run'))
+ depends_on('py-matplotlib', when='+plotting', type=('build', 'run'))