定制 rindow/rindow-clblast-ffi 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

rindow/rindow-clblast-ffi

最新稳定版本:1.0.4

Composer 安装命令:

composer require rindow/rindow-clblast-ffi

包简介

The CLBlast interface for FFI on PHP

README 文档

README

Status: Build Status Downloads Latest Stable Version License

"The CLBlast ffi" is a interface for the CLBlast library. Available in libraries with FFI interface.

Please see the documents about Buffer objects on Rindow Mathematics web pages.

Requirements

  • PHP 8.1, PHP8.2, PHP8.3, PHP8.4
  • CLBlast 1.5.1 or later
  • Windows 10/11, Ubuntu(Recommends 2204-), Debian(Recommends 12-), or later

How to setup OpenCL & CLBlast

You can download and setup pre-built CLBlast binaries. Please download the binaries for your platform.

Windows

CLBlast and OpenBLAS DLL's path to Windows PATH environment variable.

C:\tmp>PATH %PATH%;/path/to/OpenBLAS/bin;/path/to/CLBlast-Library/lib
C:\tmp>cd /some/app/directory
C:\app\dir>composer require rindow/rindow-clblast-ffi

Ubuntu

On Linux, you first need to set up OpenCL.

For example, in the case of Ubuntu standard AMD driver, install as follows

$ sudo apt install clinfo
$ sudo apt install mesa-opencl-icd
$ sudo mkdir -p /usr/local/usr/lib
$ sudo ln -s /usr/lib/clc /usr/local/usr/lib/clc

Ubuntu standard OpenCL drivers include:

  • mesa-opencl-icd
  • beignet-opencl-icd
  • intel-opencl-icd
  • nvidia-opencl-icd-xxx
  • pocl-opencl-icd

Next, Setup clblast.

Install clbast on Ubuntu 22.04 or Debian 12 or later.

$ sudo apt install libclblast1

If you use Ubuntu 20.04 or Debian 11, download and Extract Archive file and Pack to deb

$ cd /some/app/directory
$ composer require rindow/rindow-clblast-ffi
$ cp vendor/rindow/rindow-clblast-ffi/clblast-packdeb.sh .
$ sh ./clblast-packdeb.sh
$ sudo apt install ./clblast_X.X.X_amd64.deb

And then, Please install rindow-clblast-ffi if you have not already done so.

$ cd /some/app/directory
$ composer require rindow/rindow-clblast-ffi

统计信息

  • 总下载量: 452
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2024-03-18