在QT中引用Shark Machine Learning library
来源:互联网 发布:炉石传说mac下载 编辑:程序博客网 时间:2024/06/06 04:28
最近因为项目需要,看了看机器学习方面的东西。Google一番,发现Shark正是朕需要的东西。于是准备按官方文档来使用它了。但是官方文档只有怎么生成静态库,并没有在QT里引用的sample。
废话不多说,直接上步骤:
首先,环境: Ubuntu 16.04,Qt5.7,shark 3.1.3
在开始编译安装shark之前,先安装其所依赖的其他组件:
sudo apt-get install cmake cmake-curses-gui libatlas-base-dev libboost-all-dev
Shark 3.1.3的source地址:https://github.com/Shark-ML/Shark/releases
可以选择下载zip,或者tar.gz。里面的东西都一样,只是压缩格式不同。
解压后,命令行到 Shark-3.1.3 目录。
然后按顺序执行下列命令:
mkdir buildcd buildcmake ../makesudo make install
友情提醒:以上make命令大概需要30分钟左右。注意预留足够的时间。
然后,在QT project中引用shark library: 在pro文件中添加如下代码:
#Shark libraryLIBS += -lshark -lboost_serialization -lcblas -latlas -llapackINCLUDEPATH += /usr/include/atlas
可以看到以上LIBS除了添加了lshark library, 还添加了shark所引用的 atlas的library。 这是必需的。
若项目中还用到了其他boost library的话,编译可能不过,那么也需要在LIBS上继续追加对应的library。
总结于此,希望有所帮助。
0 0
- 在QT中引用Shark Machine Learning library
- 在QT中引用Shark Machine Learning library
- Shark machine learning library
- Shark machine learning library在linux下的安装
- Shark Machine Learning Library 安装配置运行
- Shark Machine Learning Library --之安装篇
- Shark Machine Learning Library --之运行篇
- Shark Machine Learning Library 安装配置运行
- Shark Machine Learning Library 安装配置运行
- Shark Machine Learning Library 安装配置运行
- Machine Learning Library for Python
- Machine Learning 中Bayes
- spark1.1.0 Machine Learning Library (MLlib)
- Machine learning algorithms-Dlib C++ Library
- 在Shark中创建用户
- CatBoost: A machine learning library to handle categorical (CAT) data automatically MACHINE LEARNING
- The ARM Computer Vision and Machine Learning library
- Android Studio 在library中引用本地arr的办法
- pat a1002
- Fliptile [反转问题][dfs]
- 算法训练 6-1 递归求二项式系数值
- 初始结构体,计算量点距离
- HDU3065 病毒侵袭持续中(AC自动机)
- 在QT中引用Shark Machine Learning library
- 【Dongle】【SSH】框架学习
- 多线程安全开启问题
- 总结一些工具、参考类的网站(总结自己常用的网站)
- 满满的爱
- Java面向对象(五)封装
- Kotlin VS Java:基本语法差异
- File -详解
- jqueryeasyui动态生成分页的相关属性设置datagrid