Skip to content

Commit e4e5bd8

Browse files
Fix serial libraries constructed after successful openmp libraries
1 parent 627c6c3 commit e4e5bd8

4 files changed

Lines changed: 9 additions & 5 deletions

File tree

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@
1616
"php": "^8.1",
1717
"ext-ffi": "*",
1818
"codewithkyrian/jinja-php": "^1.0",
19-
"codewithkyrian/transformers-libraries-downloader": "^1.0",
2019
"imagine/imagine": "^1.3",
2120
"symfony/console": "^6.4|^7.0",
2221
"rokka/imagine-vips": "^0.31.0",
2322
"rindow/rindow-math-matrix": "^2.0",
2423
"rindow/rindow-matlib-ffi": "^1.0",
25-
"rindow/rindow-openblas-ffi": "^1.0"
24+
"rindow/rindow-openblas-ffi": "^1.0",
25+
"codewithkyrian/transformers-libraries-downloader": "^1.0"
2626
},
2727
"require-dev": {
2828
"pestphp/pest": "^2.31",

examples/composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,12 @@
1414
"require": {
1515
"php": "^8.1",
1616
"symfony/console": "^7.0",
17-
"codewithkyrian/transformers": "dev-bump-math-matrix"
17+
"codewithkyrian/transformers": "*"
1818
},
1919
"require-dev": {
2020
"symfony/var-dumper": "^7.0"
2121
},
22+
"minimum-stability": "dev",
2223
"repositories": [
2324
{
2425
"type": "path",

libs/VERSIONS

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
TRANSFORMERS_PHP=0.4.0
1+
DOWNLOADER=1.0.0
22
OPENBLAS=0.3.27
3-
RINDOW_MATLIB=1.0.0
3+
RINDOW_MATLIB=1.0.1
44
ONNXRUNTIME=1.17.0

src/Tensor/TensorService.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,14 @@ protected function injectDefaultFactories(): void
2727
libFiles: [Libraries::RindowMatlib_OpenMP->libFile(Transformers::$libsDir)]
2828
);
2929

30+
3031
// Check if OpenMP-compatible factories are available
3132
if ($openblasFactory->isAvailable() && $mathFactory->isAvailable()) {
3233
$this->openblasFactory = $openblasFactory;
3334
$this->mathFactory = $mathFactory;
3435
$this->bufferFactory = $bufferFactory;
36+
37+
return;
3538
}
3639

3740
// If OpenMP is not available, try initializing serial-compatible factories

0 commit comments

Comments
 (0)