(二)Graphvite 安装过程整理

在安装Graphvite之前,请确保你已经下载了graphvite源码,并且安装好CUDA(只使用CPU可以不需要)以及安装好了faiss。

Graphvite 源码地址:https://github.com/DeepGraphLearning/graphvite

faiss 安装教程请参考上一篇博客:(一)Graphvite源码编译安装——faiss 源码安装

-----------------------------分割线--------------------------------------------------------------------------------------

安装步骤:
1、下载graphvite v0.1.0 版本并解压 

nohup wget https://github.com/DeepGraphLearning/graphvite/archive/v0.1.0.tar.gz > a.log 2>&1 & 
tar -xvf v0.1.0.tar.gz 

2、安装配置环境

cd graphvite-0.1.0
conda install -y --file conda/requirements.txt


3、创建build 文件进行编译

mkdir build && cd build

 

4、修改cmake/FindGFlags.cmake与FindGlog.cmake文件,指定conda install 安装的gflags 与 glog (可以不修改)

cmake ..
vim ./cmake/FindGFlags.cmake
vim ./cmake/FindGlog.cmake
if(WIN32)
    find_path(GFLAGS_INCLUDE_DIR gflags/gflags.h
        PATHS ${GFLAGS_ROOT_DIR}/src/windows)
else()
    find_path(GFLAGS_INCLUDE_DIR gflags/gflags.h
        PATHS ${GFLAGS_ROOT_DIR}
        /home/deng/anaconda3/envs/graphvite/include) # add gflags include
endif()

4、编译(修改3)

cmake -DFAISS_PATH=/home/deng/usr/local/faiss_gpu/lib -DCMAKE_INSTALL_PREFIX=$HOME/usr/local/graphvite_gpu ..
make

存在的warning :

[ 33%] Building CUDA object src/CMakeFiles/graphvite.dir/graphvite.cu.o
/home/deng/anaconda3/envs/graphvite/include/python3.7m/pybind11/cast.h(1003): warning: pointless comparison of unsigned integer with zero
          detected during:
            instantiation of "__nv_bool pybind11::detail::type_caster<T, pybind11::detail::enable_if_t<<expression>, void>>::load(pybind11::handle, __nv_bool) [with T=pybind11::detail::intrinsic_t<pybind11::detail::conditional_t<false, pybind11::detail::void_type, const size_t &>>]" 
(1927): here
            instantiation of "__nv_bool pybind11::detail::argument_loader<Args...>::load_impl_sequence(pybind11::detail::function_call &, pybind11::detail::index_sequence<Is...>) [with Args=<pybind11::detail::value_and_holder &, std::vector<int, std::allocator<int>>, int, size_t>, Is=<0UL, 1UL, 2UL, 3UL>]" 
(1907): here
            instantiation of "__nv_bool pybind11::detail::argument_loader<Args...>::load_args(pybind11::detail::function_call &) [with Args=<pybind11::detail::value_and_holder &, std::vector<int, std::allocator<int>>, int, size_t>]" 
/home/deng/anaconda3/envs/graphvite/include/python3.7m/pybind11/pybind11.h(141): here
            instantiation of "void pybind11::cpp_function::initialize(Func &&, Return (*)(Args...), const Extra &...) [with Func=lambda [](pybind11::detail::value_and_holder &, std::vector<int, std::allocator<int>>, int, size_t)->void, Return=void, Args=<pybind11::detail::value_and_holder &, std::vector<int, std::allocator<int>>, int, size_t>, Extra=<pybind11::name, pybind11::is_method, pybind11::sibling, pybind11::detail::is_new_style_constructor, pybind11::no_gil, pybind11::arg_v, pybind11::arg_v, pybind11::arg_v>]" 
/hom
  • 0
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值