使用Rapids.ai版本0.11+将cudf&cuML安装到Colab中

Installing cuDF amp; cuML into Colab with Rapids.ai version 0.11+(使用Rapids.ai版本0.11+将cudfamp;cuML安装到Colab中)

本文介绍了使用Rapids.ai版本0.11+将cudf&cuML安装到Colab中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将带有cudf和cuML的Rapids库安装到Colab Session, 并根据此示例执行代码: 从… Install RAPIDS library on Googe Colab notebook
!wget -nc https://raw.githubusercontent.com/rapidsai/notebooks-contrib/890b04ed8687da6e3a100c81f449ff6f7b559956/utils/rapids-colab.sh
!bash rapids-colab.sh

import sys, os

dist_package_index = sys.path.index("/usr/local/lib/python3.6/dist-packages")
sys.path = sys.path[:dist_package_index] + ["/usr/local/lib/python3.6/site-packages"] + sys.path[dist_package_index:]```
sys.path
if os.path.exists('update_pyarrow.py'): ## This file only exists if you're using RAPIDS version 0.11 or higher
  exec(open("update_pyarrow.py").read(), globals())

在安装过程中,我收到以下错误:


  - cudf=0.11

Current channels:

  - https://conda.anaconda.org/rapidsai-nightly/label/xgboost/linux-64
  - https://conda.anaconda.org/rapidsai-nightly/label/xgboost/noarch
  - https://conda.anaconda.org/rapidsai-nightly/linux-64
  - https://conda.anaconda.org/rapidsai-nightly/noarch
  - https://conda.anaconda.org/nvidia/linux-64
  - https://conda.anaconda.org/nvidia/noarch
  - https://conda.anaconda.org/conda-forge/linux-64
  - https://conda.anaconda.org/conda-forge/noarch
  - https://repo.anaconda.com/pkgs/main/linux-64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/free/linux-64
  - https://repo.anaconda.com/pkgs/free/noarch
  - https://repo.anaconda.com/pkgs/r/linux-64
  - https://repo.anaconda.com/pkgs/r/noarch
  - https://repo.anaconda.com/pkgs/pro/linux-64
  - https://repo.anaconda.com/pkgs/pro/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.

我已尝试使用

分别安装cudf和cuML
conda install -c rapidsai -c nvidia -c conda-forge 
    -c defaults cudf=0.12 python=3.6 cudatoolkit=10.0

但仍收到错误:

ModuleNotFoundError Traceback (most recent call last)

<ipython-input-10-a95ca25217db> in <module>()
----> 1 import cudf
      2 import io, requests
      3 
      4 # download CSV file from GitHub
      5 url="https://github.com/plotly/datasets/raw/master/tips.csv"

ModuleNotFoundError: No module named 'cudf'

如何解决此错误?

推荐答案

更新(2020年12月21日):您可以使用BlazingSQL(Rapids0.15+)或继续使用Colabratory(仅限Rapids0.14)

,直接在线进入基于GPU的Rapids笔记本电脑

更新(2020年2月19日):回到这个问题上,Colab正在@try工作。玩得开心!

如果您有任何其他问题,请告诉我们。如果您需要更新您的个人Colab笔记本电脑,请使用以下脚本安装Rapids:

# Install RAPIDS
!git clone https://github.com/rapidsai/rapidsai-csp-utils.git
!bash rapidsai-csp-utils/colab/rapids-colab.sh

import sys, os

dist_package_index = sys.path.index('/usr/local/lib/python3.6/dist-packages')
sys.path = sys.path[:dist_package_index] + ['/usr/local/lib/python3.6/site-packages'] + sys.path[dist_package_index:]
sys.path
exec(open('rapidsai-csp-utils/colab/update_modules.py').read(), globals())

上一次回复:

我们正在将Colab脚本过渡到新的repo。 我们应该尽快更新我们所有的笔记本,努力帮助别人 也要迁移。如果不是今天太平洋标准时间的EOD,在24小时内。

这篇关于使用Rapids.ai版本0.11+将cudf&amp;cuML安装到Colab中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本文标题为:使用Rapids.ai版本0.11+将cudf&amp;cuML安装到Colab中

基础教程推荐