Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

INTRODUCTION

This is a PHP extension which computes float matrix products.

  • It supports OpenBLAS sgemm and cuBLAS sgemm function.
  • To Enable OpenBLAS support, you have to specify its library path.
  • To Enable cuBLAS support, CUDA development environment required.
  • Some other functions like sum, scale, transpose, etc... included. (But, they are not utilize OpenBLAS nor cuBLAS.)
  • PHP7 required.

INSTALL

Clone this repository to your computer.

PHP development environment required.

$ cd PHPMatrix
$ phpize

# for simple matrix multiplication
$ ./configure

# to enable OpenBLAS support
$ ./configure --with-openblas=/PATH/TO/OpenBLAS # ex.) /opt/OpenBLAS

# to enable cuBLAS support
$ ./configure --enable-cublas
$ ./build_cublas_support_lib.sh # to build CUDA code.

$ make
$ make install # if needed

Running sample code

# specify the extension file explicitly unless installed globally.
$ php -d extension=./modules/matrix.so sample.php

LICENSE

This software is released under the MIT License, see LICENSE.

About

PHP extension for computing matrix product linking to OpenBLAS and cuBLAS

Resources

License

Releases

No releases published

Packages

No packages published