forked from tinygrad/tinygrad
onnxruntime respects NUM_CPU_THREADS (#17788)
Autogen / In-tree Autogen (macos) (push) Waiting to run
Benchmarks / Mac pytest (push) Waiting to run
Benchmarks / LLM (DEV=AMD) (push) Waiting to run
Benchmarks / LLM (DEV=METAL) (push) Waiting to run
Benchmarks / LLM (DEV=NV) (push) Waiting to run
Benchmarks / HLB-CIFAR10 (DEV=AMD) (push) Waiting to run
Benchmarks / HLB-CIFAR10 (DEV=METAL) (push) Waiting to run
Benchmarks / HLB-CIFAR10 (DEV=NV) (push) Waiting to run
Benchmarks / MLPerf (AMD) (push) Waiting to run
Benchmarks / MLPerf (NV) (push) Waiting to run
Benchmarks / Stable Diffusion (DEV=AMD) (push) Waiting to run
Benchmarks / Stable Diffusion (DEV=METAL) (push) Waiting to run
Benchmarks / Stable Diffusion (DEV=NV) (push) Waiting to run
Benchmarks / Multi-GPU Benchmarks (DEV=AMD) (push) Waiting to run
Benchmarks / Multi-GPU Benchmarks (DEV=NV) (push) Waiting to run
Benchmarks / Tests (DEV=AMD) (push) Waiting to run
Benchmarks / Tests (DEV=METAL) (push) Waiting to run
Benchmarks / Tests (DEV=NV) (push) Waiting to run
Benchmarks / UsbGPU Benchmark (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 dmonitoring (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 dmonitoring (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 policy (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 supercombo (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 vision (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 dmonitoring (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 dmonitoring (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 policy (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 supercombo (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 vision (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / DSP Benchmark (push) Waiting to run
Benchmarks / UsbGPU Benchmark (comma) (push) Waiting to run
Benchmarks / PCI Driver Benchmark (DEV=AMD) (push) Waiting to run
Benchmarks / PCI Driver Benchmark (DEV=NV) (push) Waiting to run
Benchmarks / LLVM Speed (push) Waiting to run
Platform Tests / MacOS (unit) (push) Waiting to run
Platform Tests / MacOS (unit, mock) (push) Waiting to run
Platform Tests / MacOS (DEV=METAL) (1) (push) Waiting to run
Platform Tests / MacOS (DEV=METAL) (2) (push) Waiting to run
Platform Tests / MacOS (DEV=CPU:CLANG) (push) Waiting to run
Platform Tests / MacOS (DEV=CPU:LLVM) (push) Waiting to run
Platform Tests / MacOS (DEV=CPU:LVP) (push) Waiting to run
Platform Tests / MacOS (DEV=WEBGPU) (push) Waiting to run
Platform Tests / Windows (DEV=CPU:CLANG) (push) Waiting to run
Platform Tests / Windows (DEV=CPU:LLVM) (push) Waiting to run
Platform Tests / Windows (DEV=CPU:X86) (push) Waiting to run
Platform Tests / Windows (DEV=WEBGPU) (push) Waiting to run
Unit Tests / Models (push) Successful in 1m43s
Unit Tests / Linux (DSP) (push) Successful in 1m54s
Unit Tests / Linters (push) Successful in 2m3s
Unit Tests / Test LLM (push) Successful in 2m5s
Unit Tests / ONNX (CPU) Tests (push) Successful in 2m15s
Unit Tests / Docs (push) Successful in 2m52s
Unit Tests / AMD ASM IDE (push) Successful in 2m56s
Unit Tests / hcq2 (push) Successful in 2m59s
Unit Tests / Fuzzing (push) Successful in 3m13s
Unit Tests / Python Backend (push) Successful in 3m15s
Unit Tests / openpilot Compile Tests (push) Successful in 3m18s
Unit Tests / Null Tests (push) Successful in 3m21s
Unit Tests / CL IMAGE Tests (push) Successful in 3m25s
Unit Tests / Torch Backend Training (push) Successful in 3m31s
Unit Tests / Linux (DEV=CPU:X86) (push) Successful in 3m28s
Unit Tests / Unit Tests (push) Successful in 3m48s
Unit Tests / Linux (DEV=CPU:LVP) (push) Successful in 3m48s
Unit Tests / Linux (DEV=CPU:LLVM) (push) Successful in 3m50s
Unit Tests / Linux (amdllvm gfx1201) (push) Successful in 3m51s
Unit Tests / Linux (amdllvm gfx1100) (push) Successful in 3m53s
Unit Tests / SPEC=2 (2) (push) Successful in 4m2s
Unit Tests / SPEC=2 (1) (push) Successful in 4m8s
Unit Tests / Linux (DEV=CL) (push) Successful in 4m9s
Unit Tests / Optimization Tests (push) Successful in 4m13s
Unit Tests / Linux (DEV=WEBGPU) (push) Successful in 4m11s
Unit Tests / Linux (am) (push) Successful in 4m16s
Unit Tests / Linux (amd gfx1100) (push) Successful in 4m19s
Unit Tests / Torch Backend Tests (push) Successful in 4m26s
Unit Tests / Linux (amd gfx1201) (push) Successful in 4m19s
Unit Tests / Compile-only (DEV=NULL:NAK:sm_120) (push) Successful in 1m39s
Unit Tests / Compile-only (DEV=NULL:IR3:a630) (push) Successful in 2m18s
Deploy Docs / deploy (push) Successful in 4m38s
Unit Tests / Linux (DEV=CPU:CLANG) (push) Successful in 4m41s
Unit Tests / Linux (amdllvm gfx950) (push) Successful in 3m12s
Unit Tests / Linux (ptx) (push) Successful in 3m12s
Unit Tests / Linux (nv) (push) Successful in 3m48s
Unit Tests / Linux (amd gfx950) (push) Successful in 4m18s
Unit Tests / Compile-only (DEV=NULL:QCOMCL:a630) (push) Successful in 3m49s
Autogen / In-tree Autogen (push) Successful in 11m29s
Autogen / In-tree Autogen (macos) (push) Waiting to run
Benchmarks / Mac pytest (push) Waiting to run
Benchmarks / LLM (DEV=AMD) (push) Waiting to run
Benchmarks / LLM (DEV=METAL) (push) Waiting to run
Benchmarks / LLM (DEV=NV) (push) Waiting to run
Benchmarks / HLB-CIFAR10 (DEV=AMD) (push) Waiting to run
Benchmarks / HLB-CIFAR10 (DEV=METAL) (push) Waiting to run
Benchmarks / HLB-CIFAR10 (DEV=NV) (push) Waiting to run
Benchmarks / MLPerf (AMD) (push) Waiting to run
Benchmarks / MLPerf (NV) (push) Waiting to run
Benchmarks / Stable Diffusion (DEV=AMD) (push) Waiting to run
Benchmarks / Stable Diffusion (DEV=METAL) (push) Waiting to run
Benchmarks / Stable Diffusion (DEV=NV) (push) Waiting to run
Benchmarks / Multi-GPU Benchmarks (DEV=AMD) (push) Waiting to run
Benchmarks / Multi-GPU Benchmarks (DEV=NV) (push) Waiting to run
Benchmarks / Tests (DEV=AMD) (push) Waiting to run
Benchmarks / Tests (DEV=METAL) (push) Waiting to run
Benchmarks / Tests (DEV=NV) (push) Waiting to run
Benchmarks / UsbGPU Benchmark (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 dmonitoring (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 dmonitoring (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 policy (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 supercombo (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 vision (DEV=QCOM) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 dmonitoring (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 dmonitoring (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 policy (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.2 compile3 supercombo (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / openpilot 0.11.0 compile3 vision (DEV=QCOM:IR3) (push) Waiting to run
Benchmarks / DSP Benchmark (push) Waiting to run
Benchmarks / UsbGPU Benchmark (comma) (push) Waiting to run
Benchmarks / PCI Driver Benchmark (DEV=AMD) (push) Waiting to run
Benchmarks / PCI Driver Benchmark (DEV=NV) (push) Waiting to run
Benchmarks / LLVM Speed (push) Waiting to run
Platform Tests / MacOS (unit) (push) Waiting to run
Platform Tests / MacOS (unit, mock) (push) Waiting to run
Platform Tests / MacOS (DEV=METAL) (1) (push) Waiting to run
Platform Tests / MacOS (DEV=METAL) (2) (push) Waiting to run
Platform Tests / MacOS (DEV=CPU:CLANG) (push) Waiting to run
Platform Tests / MacOS (DEV=CPU:LLVM) (push) Waiting to run
Platform Tests / MacOS (DEV=CPU:LVP) (push) Waiting to run
Platform Tests / MacOS (DEV=WEBGPU) (push) Waiting to run
Platform Tests / Windows (DEV=CPU:CLANG) (push) Waiting to run
Platform Tests / Windows (DEV=CPU:LLVM) (push) Waiting to run
Platform Tests / Windows (DEV=CPU:X86) (push) Waiting to run
Platform Tests / Windows (DEV=WEBGPU) (push) Waiting to run
Unit Tests / Models (push) Successful in 1m43s
Unit Tests / Linux (DSP) (push) Successful in 1m54s
Unit Tests / Linters (push) Successful in 2m3s
Unit Tests / Test LLM (push) Successful in 2m5s
Unit Tests / ONNX (CPU) Tests (push) Successful in 2m15s
Unit Tests / Docs (push) Successful in 2m52s
Unit Tests / AMD ASM IDE (push) Successful in 2m56s
Unit Tests / hcq2 (push) Successful in 2m59s
Unit Tests / Fuzzing (push) Successful in 3m13s
Unit Tests / Python Backend (push) Successful in 3m15s
Unit Tests / openpilot Compile Tests (push) Successful in 3m18s
Unit Tests / Null Tests (push) Successful in 3m21s
Unit Tests / CL IMAGE Tests (push) Successful in 3m25s
Unit Tests / Torch Backend Training (push) Successful in 3m31s
Unit Tests / Linux (DEV=CPU:X86) (push) Successful in 3m28s
Unit Tests / Unit Tests (push) Successful in 3m48s
Unit Tests / Linux (DEV=CPU:LVP) (push) Successful in 3m48s
Unit Tests / Linux (DEV=CPU:LLVM) (push) Successful in 3m50s
Unit Tests / Linux (amdllvm gfx1201) (push) Successful in 3m51s
Unit Tests / Linux (amdllvm gfx1100) (push) Successful in 3m53s
Unit Tests / SPEC=2 (2) (push) Successful in 4m2s
Unit Tests / SPEC=2 (1) (push) Successful in 4m8s
Unit Tests / Linux (DEV=CL) (push) Successful in 4m9s
Unit Tests / Optimization Tests (push) Successful in 4m13s
Unit Tests / Linux (DEV=WEBGPU) (push) Successful in 4m11s
Unit Tests / Linux (am) (push) Successful in 4m16s
Unit Tests / Linux (amd gfx1100) (push) Successful in 4m19s
Unit Tests / Torch Backend Tests (push) Successful in 4m26s
Unit Tests / Linux (amd gfx1201) (push) Successful in 4m19s
Unit Tests / Compile-only (DEV=NULL:NAK:sm_120) (push) Successful in 1m39s
Unit Tests / Compile-only (DEV=NULL:IR3:a630) (push) Successful in 2m18s
Deploy Docs / deploy (push) Successful in 4m38s
Unit Tests / Linux (DEV=CPU:CLANG) (push) Successful in 4m41s
Unit Tests / Linux (amdllvm gfx950) (push) Successful in 3m12s
Unit Tests / Linux (ptx) (push) Successful in 3m12s
Unit Tests / Linux (nv) (push) Successful in 3m48s
Unit Tests / Linux (amd gfx950) (push) Successful in 4m18s
Unit Tests / Compile-only (DEV=NULL:QCOMCL:a630) (push) Successful in 3m49s
Autogen / In-tree Autogen (push) Successful in 11m29s
This commit is contained in:
@@ -1,10 +1,12 @@
|
||||
from tinygrad import Tensor
|
||||
from tinygrad.helpers import NUM_CPU_THREADS
|
||||
from tinygrad.tensor import _to_np_dtype
|
||||
from tinygrad.nn.onnx import OnnxRunner, OnnxValue
|
||||
import numpy as np
|
||||
import onnxruntime as ort
|
||||
ort_options = ort.SessionOptions()
|
||||
ort_options.log_severity_level = 3
|
||||
ort_options.intra_op_num_threads = NUM_CPU_THREADS.value
|
||||
|
||||
def get_example_inputs(graph_inputs:dict[str, OnnxValue], config={}):
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user