dmlc / xgboost

Scalable, Portable and Distributed Gradient Boosting (GBDT, GBRT or GBM) Library, for Python, R, Java, Scala, C++ and more. Runs on single machine, Hadoop, Spark, Dask, Flink and DataFlow
https://xgboost.readthedocs.io/en/stable/
Apache License 2.0
26.28k stars 8.73k forks source link

XGBoost version not compiled with GPU support. #6353

Closed stromal closed 4 years ago

stromal commented 4 years ago

CODE

it is a kaggle project that I am trying to run locally on GPU: GTX 1080, Ubuntu 20.04 TS

MAX_TREE_DEPTH = 8
TREE_METHOD = 'gpu_hist'
ITERATIONS = 1000
SUBSAMPLE = 0.6
REGULARIZATION = 0.1
GAMMA = 0.3
POS_WEIGHT = 1
EARLY_STOP = 10

params = {'tree_method': TREE_METHOD, 
          'max_depth': MAX_TREE_DEPTH, 
          'alpha': REGULARIZATION,
          'gamma': GAMMA, 
          'subsample': SUBSAMPLE, 
          'scale_pos_weight': POS_WEIGHT, 
          'learning_rate': 0.05, 
          'silent': 1, 
          'objective':'binary:logistic', 
          'eval_metric': 'auc',
          }
            ###'n_gpus': 1

%%time
''' ORIGINAL '''
#nfold = 5
#skf = StratifiedKFold(n_splits=nfold, shuffle=True, random_state=2019)

skf = RepeatedStratifiedKFold(n_splits=10, n_repeats=3, random_state=1)

oof = np.zeros(len(train_df))
predictions = np.zeros(len(test_df))

target = 'target'
predictors = train_df.columns.values.tolist()[2:]

i = 1
for train_index, valid_index in skf.split(train_df, train_df.target.values):
    print("\nFold {}".format(i))
    xg_train = xgb.DMatrix(train_df.iloc[train_index][predictors].values,
                           train_df.iloc[train_index][target].values,)
    xg_valid = xgb.DMatrix(train_df.iloc[valid_index][predictors].values,
                           train_df.iloc[valid_index][target].values,)   
    clf = xgb.train(params, 
                    xg_train, 
                    ITERATIONS, 
                    evals=[(xg_train, "train"), 
                           (xg_valid, "eval")],
                    early_stopping_rounds=EARLY_STOP, 
                    verbose_eval=False) 
    oof[valid_index] = clf.predict(xgb.DMatrix(train_df.iloc[valid_index][predictors].values)) 
    predictions += clf.predict(xgb.DMatrix(test_df[predictors].values)) / nfold
    i = i + 1

print("\n\nCV AUC: {:<0.2f}".format(metrics.roc_auc_score(train_df.target.values, oof)))

ERROR

Fold 1
---------------------------------------------------------------------------
XGBoostError                              Traceback (most recent call last)
<timed exec> in <module>

~/anaconda3/envs/ect2/lib/python3.8/site-packages/xgboost/training.py in train(params, dtrain, num_boost_round, evals, obj, feval, maximize, early_stopping_rounds, evals_result, verbose_eval, xgb_model, callbacks)
    206         callbacks.append(callback.record_evaluation(evals_result))
    207 
--> 208     return _train_internal(params, dtrain,
    209                            num_boost_round=num_boost_round,
    210                            evals=evals,

~/anaconda3/envs/ect2/lib/python3.8/site-packages/xgboost/training.py in _train_internal(params, dtrain, num_boost_round, evals, obj, feval, xgb_model, callbacks)
     73         # Skip the first update if it is a recovery step.
     74         if version % 2 == 0:
---> 75             bst.update(dtrain, i, obj)
     76             bst.save_rabit_checkpoint()
     77             version += 1

~/anaconda3/envs/ect2/lib/python3.8/site-packages/xgboost/core.py in update(self, dtrain, iteration, fobj)
   1157 
   1158         if fobj is None:
-> 1159             _check_call(_LIB.XGBoosterUpdateOneIter(self.handle,
   1160                                                     ctypes.c_int(iteration),
   1161                                                     dtrain.handle))

~/anaconda3/envs/ect2/lib/python3.8/site-packages/xgboost/core.py in _check_call(ret)
    186     """
    187     if ret != 0:
--> 188         raise XGBoostError(py_str(_LIB.XGBGetLastError()))
    189 
    190 

XGBoostError: [14:47:48] /home/conda/feedstock_root/build_artifacts/xgboost_1598185621802/work/src/gbm/../common/common.h:153: XGBoost version not compiled with GPU support.
Stack trace:
  [bt] (0) /home/fanatical/anaconda3/envs/ect2/lib/libxgboost.so(+0x8977f) [0x7f53fe24777f]
  [bt] (1) /home/fanatical/anaconda3/envs/ect2/lib/libxgboost.so(xgboost::gbm::GBTree::ConfigureUpdaters()+0x106) [0x7f53fe321c26]
  [bt] (2) /home/fanatical/anaconda3/envs/ect2/lib/libxgboost.so(xgboost::gbm::GBTree::Configure(std::vector<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > const&)+0x309) [0x7f53fe331409]
  [bt] (3) /home/fanatical/anaconda3/envs/ect2/lib/libxgboost.so(+0x1a0dca) [0x7f53fe35edca]
  [bt] (4) /home/fanatical/anaconda3/envs/ect2/lib/libxgboost.so(+0x18934d) [0x7f53fe34734d]
  [bt] (5) /home/fanatical/anaconda3/envs/ect2/lib/libxgboost.so(XGBoosterUpdateOneIter+0x68) [0x7f53fe24bc18]
  [bt] (6) /home/fanatical/anaconda3/envs/ect2/lib/python3.8/lib-dynload/../../libffi.so.7(+0x69dd) [0x7f5431a769dd]
  [bt] (7) /home/fanatical/anaconda3/envs/ect2/lib/python3.8/lib-dynload/../../libffi.so.7(+0x6067) [0x7f5431a76067]
  [bt] (8) /home/fanatical/anaconda3/envs/ect2/lib/python3.8/lib-dynload/_ctypes.cpython-38-x86_64-linux-gnu.so(+0x1097a) [0x7f5431a8c97a]

INPUT

pipdeptree --reverse --packages xgboost

OUTPUT

Warning!!! Possibly conflicting dependencies found:
* wandb==0.10.4
 - subprocess32 [required: >=3.5.3, installed: ?]
* spyder==4.1.5
 - pyqt5 [required: <5.13, installed: ?]
 - pyqtwebengine [required: <5.13, installed: ?]
* QDarkStyle==2.8.1
 - helpdev [required: >=0.6.10, installed: ?]
* Flask-Compress==1.5.0
 - brotli [required: Any, installed: ?]
* dask-xgboost==0.1.11
 - xgboost [required: <=0.90, installed: 1.2.0]
* dash==1.16.3
 - dash-core-components [required: ==1.12.1, installed: 1.3.1]
 - dash-html-components [required: ==1.1.1, installed: 1.0.1]
 - dash-renderer [required: ==1.8.2, installed: 1.1.2]
 - dash-table [required: ==4.10.1, installed: 4.4.1]
------------------------------------------------------------------------
xgboost==1.2.0
  - dask-xgboost==0.1.11 [requires: xgboost<=0.90]

MY LIBRARIES

# Name                    Version                   Build  Channel
_anaconda_depends         2020.07                  py38_0    anaconda
_ipyw_jlab_nb_ext_conf    0.1.0                    py38_0    anaconda
_libgcc_mutex             0.1                        main    anaconda
_py-xgboost-mutex         2.0                       cpu_0    anaconda
aiohttp                   3.6.2            py38h7b6447c_0    anaconda
alabaster                 0.7.12                     py_0    anaconda
anaconda                  custom                   py38_1    anaconda
anaconda-client           1.7.2                    py38_0    anaconda
anaconda-navigator        1.9.12                   py38_0    anaconda
anaconda-project          0.8.4                      py_0    anaconda
argh                      0.26.2                   py38_0    anaconda
argon2-cffi               20.1.0           py38h7b6447c_1    anaconda
asn1crypto                1.4.0                      py_0    anaconda
astroid                   2.4.2                    py38_0    anaconda
astropy                   4.0.1.post1      py38h7b6447c_1    anaconda
async-timeout             3.0.1                    py38_0    anaconda
async_generator           1.10                       py_0    anaconda
atomicwrites              1.4.0                      py_0    anaconda
attrs                     20.2.0                     py_0    anaconda
automat                   20.2.0                     py_0    anaconda
autopep8                  1.5.4                      py_0    anaconda
babel                     2.8.0                      py_0    anaconda
backcall                  0.2.0                      py_0    anaconda
backports                 1.0                        py_2    anaconda
backports.functools_lru_cache 1.6.1                      py_0    anaconda
backports.shutil_get_terminal_size 1.0.0                    py38_2    anaconda
backports.tempfile        1.0                        py_1    anaconda
backports.weakref         1.0.post1                  py_1    anaconda
bcrypt                    3.2.0            py38h1e0a361_1    conda-forge
beautifulsoup4            4.9.3              pyhb0f4dca_0    anaconda
bitarray                  1.5.3            py38h7b6447c_0    anaconda
bkcharts                  0.2                      py38_0    anaconda
blas                      1.0                         mkl    anaconda
bleach                    3.2.1                      py_0    anaconda
blosc                     1.20.0               hd408876_0    anaconda
bokeh                     2.2.1                    py38_0    anaconda
boto                      2.49.0                   py38_0    anaconda
bottleneck                1.3.2            py38heb32a55_1    anaconda
brotlipy                  0.7.0           py38h7b6447c_1000    anaconda
bzip2                     1.0.8                h7b6447c_0    anaconda
ca-certificates           2020.10.14                    0    anaconda
cairo                     1.16.0            h18b612c_1001    conda-forge
certifi                   2020.6.20                py38_0    anaconda
cffi                      1.14.3           py38he30daa8_0    anaconda
chardet                   3.0.4                 py38_1003    anaconda
click                     7.1.2                      py_0    anaconda
cloudpickle               1.6.0                      py_0    anaconda
clyent                    1.2.2                    py38_1    anaconda
colorama                  0.4.3                      py_0    anaconda
conda                     4.9.0                    py38_0    anaconda
conda-build               3.18.11                  py38_0    anaconda
conda-env                 2.6.0                         1    anaconda
conda-package-handling    1.6.1            py38h7b6447c_0    anaconda
conda-verify              3.4.2                      py_1    anaconda
configparser              5.0.1                      py_0    anaconda
constantly                15.1.0                     py_0    anaconda
contextlib2               0.6.0.post1                py_0    anaconda
cryptography              3.1.1            py38h1ba5d50_0    anaconda
cssselect                 1.1.0                      py_0    anaconda
cudatoolkit               11.0.221             h6bb024c_0    anaconda
curl                      7.71.1               hbc83047_1    anaconda
cycler                    0.10.0                   py38_0    anaconda
cython                    0.29.21          py38he6710b0_0    anaconda
cytoolz                   0.11.0           py38h7b6447c_0    anaconda
dash                      1.16.3                     py_0    anaconda
dash-core-components      1.3.1                      py_0    anaconda
dash-html-components      1.0.1                      py_0    anaconda
dash-renderer             1.1.2                      py_0    anaconda
dash-table                4.4.1                      py_0    anaconda
dask                      2.30.0                     py_0    anaconda
dask-core                 2.30.0                     py_0    anaconda
dask-glm                  0.2.0                      py_1    conda-forge
dask-labextension         3.0.0                      py_0    conda-forge
dask-ml                   1.7.0                      py_0    anaconda
dask-xgboost              0.1.11             pyh9f0ad1d_0    conda-forge
dbus                      1.13.16              hb2f20db_0    anaconda
decorator                 4.4.2                      py_0    anaconda
defusedxml                0.6.0                      py_0    anaconda
diff-match-patch          20200713                   py_0    anaconda
distributed               2.30.0                   py38_0    anaconda
docker-pycreds            0.4.0                      py_0    anaconda
docutils                  0.16                     py38_1    anaconda
eli5                      0.10.1                     py_2    conda-forge
entrypoints               0.3                      py38_0    anaconda
et_xmlfile                1.0.1                   py_1001    anaconda
expat                     2.2.10               he6710b0_2    anaconda
fastcache                 1.1.0            py38h7b6447c_0    anaconda
filelock                  3.0.12                     py_0    anaconda
flake8                    3.8.4                      py_0    anaconda
flask                     1.1.2                      py_0    anaconda
flask-compress            1.5.0                      py_0    anaconda
fontconfig                2.13.1            he4413a7_1000    conda-forge
freetype                  2.10.2               h5ab3b9f_0    anaconda
fribidi                   1.0.10               h7b6447c_0    anaconda
fsspec                    0.8.0                      py_0    anaconda
future                    0.18.2                   py38_1    anaconda
get_terminal_size         1.0.0                haa9412d_0    anaconda
gettext                   0.19.8.1             h9b4dc7a_1    anaconda
gevent                    20.9.0           py38h7b6447c_0    anaconda
gitdb                     4.0.5                      py_0    anaconda
gitpython                 3.1.9                      py_1    anaconda
glib                      2.65.0               h3eb4bd4_0    anaconda
glob2                     0.7                        py_0    anaconda
gmp                       6.1.2                h6c8ec71_1  
gmpy2                     2.0.8            py38hd5f6e3b_3    anaconda
gputil                    1.4.0              pyh9f0ad1d_0    conda-forge
gql                       0.1.0                      py_0    conda-forge
graphite2                 1.3.14               h23475e2_0    anaconda
graphql-core              3.1.2                      py_0    conda-forge
graphviz                  2.42.3               h0511662_0    conda-forge
greenlet                  0.4.17           py38h7b6447c_0    anaconda
gst-plugins-base          1.14.0               hbbd80ab_1  
gstreamer                 1.14.0               hb31296c_0  
h5py                      2.10.0           py38h7918eee_0    anaconda
harfbuzz                  2.4.0                hca77d97_1    anaconda
hdf5                      1.10.4               hb1b8bf9_0    anaconda
heapdict                  1.0.1                      py_0    anaconda
html5lib                  1.1                        py_0    anaconda
hyperlink                 20.0.1             pyh9f0ad1d_0    conda-forge
icu                       58.2                 he6710b0_3    anaconda
idna                      2.10                       py_0    anaconda
imageio                   2.9.0                      py_0    anaconda
imagesize                 1.2.0                      py_0    anaconda
importlib-metadata        2.0.0                      py_1    anaconda
importlib_metadata        2.0.0                         1    anaconda
incremental               17.5.0                     py_0    conda-forge
iniconfig                 1.0.1                      py_0    anaconda
intel-openmp              2020.2                      254    anaconda
intervaltree              3.1.0                      py_0    anaconda
ipykernel                 5.3.4            py38h5ca1d4c_0    anaconda
ipython                   7.18.1           py38h5ca1d4c_0    anaconda
ipython_genutils          0.2.0                    py38_0    anaconda
ipywidgets                7.5.1                      py_1    anaconda
isort                     5.6.1                    py38_0    anaconda
itemadapter               0.1.1                      py_0    anaconda
itemloaders               1.0.3                      py_0    anaconda
itsdangerous              1.1.0                      py_0    anaconda
jbig                      2.1                  hdba287a_0    anaconda
jdcal                     1.4.1                      py_0    anaconda
jedi                      0.17.1                   py38_0    anaconda
jeepney                   0.4.3                      py_0    anaconda
jinja2                    2.11.2                     py_0    anaconda
jmespath                  0.10.0             pyh9f0ad1d_0    conda-forge
joblib                    0.17.0                     py_0    anaconda
jpeg                      9d                   h516909a_0    conda-forge
json5                     0.9.5                      py_0    anaconda
jsonschema                3.2.0                    py38_1    anaconda
jupyter                   1.0.0                    py38_7    anaconda
jupyter-kite              1.1.0                    pypi_0    pypi
jupyter-server-proxy      1.5.0                      py_0    conda-forge
jupyter_client            6.1.7                      py_0    anaconda
jupyter_console           6.2.0                      py_0    anaconda
jupyter_core              4.6.3                    py38_0    anaconda
jupyterlab                2.2.6                      py_0    anaconda
jupyterlab-dash           0.1.0a3                    py_0    conda-forge
jupyterlab-git            0.22.1                     py_0    conda-forge
jupyterlab_pygments       0.1.2                      py_0    anaconda
jupyterlab_server         1.2.0                      py_0    anaconda
keyring                   21.4.0                   py38_1    anaconda
kiwisolver                1.2.0            py38hfd86e86_0    anaconda
krb5                      1.18.2               h173b8e3_0    anaconda
lazy-object-proxy         1.4.3            py38h7b6447c_0    anaconda
lcms2                     2.11                 h396b838_0    anaconda
ld_impl_linux-64          2.33.1               h53a641e_7    anaconda
libarchive                3.4.2                h62408e4_0  
libcurl                   7.71.1               h20c2e04_1    anaconda
libedit                   3.1.20191231         h14c3975_1    anaconda
libffi                    3.3                  he6710b0_2    anaconda
libgcc-ng                 9.1.0                hdf63c60_0    anaconda
libgfortran-ng            7.3.0                hdf63c60_0    anaconda
liblief                   0.10.1               he6710b0_0    anaconda
libllvm10                 10.0.1               hbcb73fb_5    anaconda
libllvm9                  9.0.1                h4a3c616_1    anaconda
libpng                    1.6.37               hbc83047_0    anaconda
libprotobuf               3.13.0               hd408876_0    anaconda
libsodium                 1.0.18               h7b6447c_0    anaconda
libspatialindex           1.9.3                he6710b0_0    anaconda
libssh2                   1.9.0                h1ba5d50_1    anaconda
libstdcxx-ng              9.1.0                hdf63c60_0    anaconda
libtiff                   4.1.0                h2733197_1  
libtool                   2.4.6             h7b6447c_1005    anaconda
libuuid                   2.32.1            h14c3975_1000    conda-forge
libxcb                    1.14                 h7b6447c_0    anaconda
libxgboost                1.2.0                he1b5a44_0    conda-forge
libxml2                   2.9.10               he19cac6_1    anaconda
libxslt                   1.1.34               hc22bd24_0    anaconda
llvmlite                  0.34.0           py38h269e1b5_4    anaconda
locket                    0.2.0                    py38_1    anaconda
lxml                      4.5.2            py38hefd8a0e_0    anaconda
lz4-c                     1.9.2                heb0550a_3    anaconda
lzo                       2.10                 h7b6447c_2    anaconda
markupsafe                1.1.1            py38h7b6447c_0    anaconda
matplotlib                3.3.1                         0    anaconda
matplotlib-base           3.3.1            py38h817c723_0    anaconda
mccabe                    0.6.1                    py38_1    anaconda
mistune                   0.8.4           py38h7b6447c_1000    anaconda
mkl                       2020.2                      256    anaconda
mkl-service               2.3.0            py38he904b0f_0  
mkl_fft                   1.2.0            py38h23d657b_0  
mkl_random                1.1.1            py38h0573a6f_0    anaconda
mock                      4.0.2                      py_0    anaconda
more-itertools            8.5.0                      py_0    anaconda
mpc                       1.1.0                h10f8cd9_1    anaconda
mpfr                      4.0.2                hb69a4c5_1    anaconda
mpmath                    1.1.0                    py38_0    anaconda
msgpack-python            1.0.0            py38hfd86e86_1    anaconda
multidict                 4.7.6            py38h7b6447c_1    anaconda
multipledispatch          0.6.0                    py38_0    anaconda
navigator-updater         0.2.1                    py38_0    anaconda
nbclient                  0.5.0                      py_0    anaconda
nbconvert                 6.0.6                    py38_0    anaconda
nbdime                    2.1.0                      py_0    conda-forge
nbformat                  5.0.7                      py_0    anaconda
ncurses                   6.2                  he6710b0_1    anaconda
nest-asyncio              1.4.1                      py_0    anaconda
networkx                  2.5                        py_0    anaconda
nltk                      3.5                        py_0    anaconda
nodejs                    10.13.0              he6710b0_0    anaconda
nose                      1.3.7                    py38_2    anaconda
notebook                  6.1.4                    py38_0    anaconda
numba                     0.51.2           py38h0573a6f_1    anaconda
numexpr                   2.7.1            py38h423224d_0  
numpy                     1.18.5           py38ha1c710e_0  
numpy-base                1.18.5           py38hde5b4d6_0  
numpydoc                  1.1.0                      py_0    anaconda
nvidia-ml                 7.352.0                    py_0    conda-forge
olefile                   0.46                       py_0    anaconda
openpyxl                  3.0.5                      py_0    anaconda
openssl                   1.1.1h               h7b6447c_0    anaconda
packaging                 20.4                       py_0    anaconda
pandas                    1.0.5            py38h0573a6f_0    anaconda
pandoc                    2.10.1                        0    anaconda
pandocfilters             1.4.2                    py38_1    anaconda
pango                     1.42.4               h7062337_4    conda-forge
parsel                    1.6.0                      py_0    conda-forge
parso                     0.7.0                      py_0    anaconda
partd                     1.1.0                      py_0    anaconda
patchelf                  0.12                 he6710b0_0    anaconda
path                      15.0.0                   py38_0    anaconda
path.py                   12.5.0                        0    anaconda
pathlib2                  2.3.5                    py38_0    anaconda
pathtools                 0.1.2                      py_1    anaconda
patsy                     0.5.1                    py38_0    anaconda
pcre                      8.44                 he6710b0_0    anaconda
pep8                      1.7.1                    py38_0    anaconda
pexpect                   4.8.0                    py38_0    anaconda
pickleshare               0.7.5                 py38_1000    anaconda
pillow                    7.2.0            py38hb39fc2d_0    anaconda
pip                       20.2.3                   py38_0    anaconda
pixman                    0.38.0            h516909a_1003    conda-forge
pkginfo                   1.5.0.1                  py38_0    anaconda
plotly                    4.11.0                     py_0    plotly
plotly_express            0.4.1                      py_0    plotly
pluggy                    0.13.1                   py38_0    anaconda
ply                       3.11                     py38_0    anaconda
pprintpp                  0.4.0                    pypi_0    pypi
prometheus_client         0.8.0                      py_0    anaconda
promise                   2.3                      py38_0    anaconda
prompt-toolkit            3.0.7                      py_0    anaconda
prompt_toolkit            3.0.7                         0    anaconda
protego                   0.1.16                     py_0    anaconda
protobuf                  3.13.0           py38he6710b0_1    anaconda
psutil                    5.7.2            py38h7b6447c_0    anaconda
ptyprocess                0.6.0                    py38_0    anaconda
py                        1.9.0                      py_0    anaconda
py-lief                   0.10.1           py38h403a769_0    anaconda
py-xgboost                1.2.0            py38h32f6830_0    conda-forge
pyasn1                    0.4.8                      py_0    anaconda
pyasn1-modules            0.2.7                      py_0    anaconda
pycodestyle               2.6.0                      py_0    anaconda
pycosat                   0.6.3            py38h7b6447c_1    anaconda
pycparser                 2.20                       py_2    anaconda
pycurl                    7.43.0.6         py38h1ba5d50_0    anaconda
pydispatcher              2.0.5                      py_1    conda-forge
pydocstyle                5.1.1                      py_0    anaconda
pyflakes                  2.2.0                      py_0    anaconda
pygments                  2.7.1                      py_0    anaconda
pyhamcrest                2.0.2                      py_0    anaconda
pylint                    2.6.0                    py38_0    anaconda
pyodbc                    4.0.30           py38he6710b0_0    anaconda
pyopenssl                 19.1.0                     py_1    anaconda
pyparsing                 2.4.7                      py_0    anaconda
pyqt                      5.9.2            py38h05f1152_4    anaconda
pyrsistent                0.17.3           py38h7b6447c_0    anaconda
pysocks                   1.7.1                    py38_0    anaconda
pytables                  3.6.1            py38h9fd0a39_0    anaconda
pytest                    6.1.1                    py38_0    anaconda
python                    3.8.3                hcff3b4d_2    anaconda
python-dateutil           2.8.1                      py_0    anaconda
python-graphviz           0.14.2                     py_0    anaconda
python-jsonrpc-server     0.4.0                      py_0    anaconda
python-language-server    0.35.1                     py_0    anaconda
python-libarchive-c       2.9                        py_0    anaconda
python_abi                3.8                      1_cp38    conda-forge
pytz                      2020.1                     py_0    anaconda
pywavelets                1.1.1            py38h7b6447c_2    anaconda
pyxdg                     0.26                       py_0    anaconda
pyyaml                    5.3.1            py38h7b6447c_1    anaconda
pyzmq                     19.0.2           py38he6710b0_1    anaconda
qdarkstyle                2.8.1                      py_0    anaconda
qt                        5.9.7                h5867ecd_1  
qtawesome                 1.0.1                      py_0    anaconda
qtconsole                 4.7.7                      py_0    anaconda
qtpy                      1.9.0                      py_0    anaconda
queuelib                  1.5.0              pyh9f0ad1d_0    conda-forge
readline                  8.0                  h7b6447c_0    anaconda
regex                     2020.9.27        py38h7b6447c_0    anaconda
requests                  2.24.0                     py_0    anaconda
retrying                  1.3.3                      py_2    anaconda
rfpimp                    1.3.2                      py_0    conda-forge
ripgrep                   12.1.1                        0    anaconda
rope                      0.18.0                     py_0    anaconda
rtree                     0.9.4                    py38_1    anaconda
ruamel_yaml               0.15.87          py38h7b6447c_1    anaconda
scikit-image              0.16.2           py38h0573a6f_0    anaconda
scikit-learn              0.23.2           py38h0573a6f_0    anaconda
scipy                     1.5.2            py38h0b6359f_0  
scrapy                    2.3.0            py38h32f6830_2    conda-forge
seaborn                   0.11.0                     py_0    anaconda
secretstorage             3.1.2                    py38_0    anaconda
send2trash                1.5.0                    py38_0    anaconda
sentry-sdk                0.18.0             pyh9f0ad1d_0    conda-forge
service_identity          18.1.0                     py_0    anaconda
setuptools                50.3.0           py38hb0f4dca_1    anaconda
shortuuid                 1.0.1            py38h32f6830_2    conda-forge
simpervisor               0.3                        py_1    plotly
simplegeneric             0.8.1                    py38_2    anaconda
singledispatch            3.4.0.3                  py38_0    anaconda
sip                       4.19.13          py38he6710b0_0    anaconda
six                       1.15.0                     py_0    anaconda
smmap                     3.0.4                      py_0    anaconda
snappy                    1.1.8                he6710b0_0    anaconda
snowballstemmer           2.0.0                      py_0    anaconda
sortedcollections         1.2.1                      py_0    anaconda
sortedcontainers          2.2.2                      py_0    anaconda
soupsieve                 2.0.1                      py_0    anaconda
sphinx                    3.2.1                      py_0    anaconda
sphinxcontrib             1.0                      py38_1    anaconda
sphinxcontrib-applehelp   1.0.2                      py_0    anaconda
sphinxcontrib-devhelp     1.0.2                      py_0    anaconda
sphinxcontrib-htmlhelp    1.0.3                      py_0    anaconda
sphinxcontrib-jsmath      1.0.1                      py_0    anaconda
sphinxcontrib-qthelp      1.0.3                      py_0    anaconda
sphinxcontrib-serializinghtml 1.1.4                      py_0    anaconda
sphinxcontrib-websupport  1.2.4                      py_0    anaconda
spyder                    4.1.5                    py38_0    anaconda
spyder-kernels            1.9.4                    py38_0    anaconda
sqlalchemy                1.3.19           py38h7b6447c_0    anaconda
sqlite                    3.33.0               h62c20be_0    anaconda
statsmodels               0.11.1           py38h7b6447c_0    anaconda
sympy                     1.6.2                    py38_0    anaconda
tabulate                  0.8.7                    py38_0    anaconda
tbb                       2020.3               hfd86e86_0    anaconda
tblib                     1.7.0                      py_0    anaconda
terminado                 0.9.1                    py38_0    anaconda
testpath                  0.4.4                      py_0    anaconda
threadpoolctl             2.1.0              pyh5ca1d4c_0    anaconda
tk                        8.6.10               hbc83047_0    anaconda
toml                      0.10.1                     py_0    anaconda
toolz                     0.11.1                     py_0    anaconda
tornado                   6.0.4            py38h7b6447c_1    anaconda
tqdm                      4.50.2                     py_0    anaconda
traitlets                 5.0.4                    py38_0    anaconda
twisted                   20.3.0           py38h1e0a361_1    conda-forge
typing_extensions         3.7.4.3                    py_0    anaconda
ujson                     4.0.0            py38he6710b0_0    anaconda
unicodecsv                0.14.1                   py38_0    anaconda
unixodbc                  2.3.7                h14c3975_0    anaconda
urllib3                   1.25.10                    py_0    anaconda
w3lib                     1.22.0             pyh9f0ad1d_0    conda-forge
wandb                     0.10.4             pyh9f0ad1d_0    conda-forge
watchdog                  0.10.3                   py38_0    anaconda
wcwidth                   0.2.5                      py_0    anaconda
webencodings              0.5.1                    py38_1    anaconda
werkzeug                  1.0.1                      py_0    anaconda
wheel                     0.35.1                     py_0    anaconda
widgetsnbextension        3.5.1                    py38_0    anaconda
wrapt                     1.11.2           py38h7b6447c_0    anaconda
wurlitzer                 2.0.1                    py38_0    anaconda
xgboost                   1.2.0            py38h950e882_0    conda-forge
xlrd                      1.2.0                      py_0    anaconda
xlsxwriter                1.3.6                      py_0    anaconda
xlwt                      1.3.0                    py38_0    anaconda
xmltodict                 0.12.0                     py_0    anaconda
xorg-kbproto              1.0.7             h14c3975_1002    conda-forge
xorg-libice               1.0.10               h516909a_0    conda-forge
xorg-libsm                1.2.3             h84519dc_1000    conda-forge
xorg-libx11               1.6.12               h516909a_0    conda-forge
xorg-libxext              1.3.4                h516909a_0    conda-forge
xorg-libxpm               3.5.13               h516909a_0    conda-forge
xorg-libxrender           0.9.10            h516909a_1002    conda-forge
xorg-libxt                1.1.5             h516909a_1003    conda-forge
xorg-renderproto          0.11.1            h14c3975_1002    conda-forge
xorg-xextproto            7.3.0             h14c3975_1002    conda-forge
xorg-xproto               7.0.31            h14c3975_1007    conda-forge
xz                        5.2.5                h7b6447c_0    anaconda
yaml                      0.2.5                h7b6447c_0    anaconda
yapf                      0.30.0                     py_0    anaconda
yarl                      1.6.0            py38h7b6447c_0    anaconda
zeromq                    4.3.2                he6710b0_3    anaconda
zict                      2.0.0                      py_0    anaconda
zipp                      3.3.0                      py_0    anaconda
zlib                      1.2.11               h7b6447c_3    anaconda
zope                      1.0                      py38_1    anaconda
zope.event                4.4                      py38_0    anaconda
zope.interface            5.1.2            py38h7b6447c_0    anaconda
zstd                      1.4.5                h9ceee32_0    anaconda

I have installed the following but they did not helped:

conda install -c conda-forge xgboost
conda install -c rapidsai dask-cuda
conda install -c anaconda py-xgboost-gpu
hcho3 commented 4 years ago

See https://discuss.xgboost.ai/t/xgboost-version-not-compiled-with-gpu-support/1936/2

stromal commented 4 years ago

It is an incorrect answer I have tried that as well and it does not works. conda install -c nvidia -c rapidsai py-xgboost

hcho3 commented 4 years ago

I left my answer in the forum post.

https://discuss.xgboost.ai/t/xgboost-version-not-compiled-with-gpu-support/1936/4?u=hcho3

GoulartNogueira commented 2 years ago

I was struggling to run XGBoost on AWS sagemaker GPU.

But conda install py-xgboost-gpu worked as as charm for me!

Thanks to @bonyii, on this issue here.

juanerolon commented 12 months ago

Still having same issue, even after following @GoulartNogueira. Do you need to uninstall any of the below after installing py-xgboost-gpu? My current installed libraries are: py-xgboost-mutex 2.0 gpu_0 conda-forge libxgboost 1.7.6 cuda120ha80de60_5 conda-forge py-xgboost 1.7.6 cuda120py311h647eaca_5 conda-forge py-xgboost-gpu 1.7.6 py311h0f3d150_5 conda-forge xgboost 1.7.6 cuda120py311h647eaca_5 conda-forge

ayman-codes commented 3 months ago

check if you still have conflicting libraries between pip and conda, i had a similar issue, I used my other pc that only had conda and it worked. you can also try your code on collab/Kaggle, remember to set the GPU runtime. also make sure you've installed you gpu drivers and make sure you've cuda installed.