Skip to content

phpmlkit/onnxruntime-cpu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ONNX Runtime for PHP (CPU)

High-performance ONNX Runtime bindings for PHP using CPU execution.

⚠️ This is a read-only split repository.

For full documentation, contributing guidelines, bug reports, and feature requests, please visit the main repository: https://github.com/phpmlkit/onnxruntime

Installation

composer require phpmlkit/onnxruntime

Quick Start

use PhpMlKit\ONNXRuntime\InferenceSession;
use PhpMlKit\ONNXRuntime\OrtValue;
use PhpMlKit\ONNXRuntime\Enums\DataType;

$session = InferenceSession::fromFile('model.onnx');
$input = OrtValue::fromArray([1.0, 2.0, 3.0], DataType::FLOAT);
$outputs = $session->run(['input' => $input]);
$result = $outputs['output']->toArray();

Documentation

GPU Support

Need GPU acceleration? Use the GPU package instead:

composer require phpmlkit/onnxruntime-gpu

Contributing

Contributions are welcome! Please submit pull requests to the main repository: https://github.com/phpmlkit/onnxruntime

Support

License

This project is licensed under the MIT License - see the LICENSE file for details.


Note: This package is automatically generated from the monorepo. Do not submit pull requests to this repository.

About

High-performance ONNX Runtime bindings for PHP (CPU only)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors