From a352ed0269ba6995b72e5c58c2e1d11698f21bf3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Xavier=20Dupr=C3=A9?= Date: Sun, 30 Nov 2025 13:21:20 +0100 Subject: [PATCH 1/2] fix documentation and upgrade version --- _doc/examples/plot_benchmark_rf.py | 2 +- onnx_array_api/array_api/_onnx_common.py | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/_doc/examples/plot_benchmark_rf.py b/_doc/examples/plot_benchmark_rf.py index c1ce486..a910c56 100644 --- a/_doc/examples/plot_benchmark_rf.py +++ b/_doc/examples/plot_benchmark_rf.py @@ -126,7 +126,7 @@ def measure_inference(fct, X, repeat, max_time=5, quantile=1): # model for a random forest and onnxruntime after it was converted # into ONNX and for the following configurations. -small = cpu_count() < 12 +small = cpu_count() < 25 if small: N = 1000 n_features = 10 diff --git a/onnx_array_api/array_api/_onnx_common.py b/onnx_array_api/array_api/_onnx_common.py index 7c486ce..3e92472 100644 --- a/onnx_array_api/array_api/_onnx_common.py +++ b/onnx_array_api/array_api/_onnx_common.py @@ -1,7 +1,11 @@ from typing import Any, Optional import numpy as np from onnx import TensorProto -import array_api_strict + +try: + import array_api_strict +except ImportError: + array_api_strict = None from ..npx.npx_types import ( DType, @@ -27,7 +31,7 @@ ) -Array = type(array_api_strict.ones((1,))) +Array = type(array_api_strict.ones((1,))) if array_api_strict else None # These functions with no specific code do not have to be From 3a82a01475179298a1c5aae147ebce58a7f9ac59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Xavier=20Dupr=C3=A9?= Date: Sun, 30 Nov 2025 13:21:41 +0100 Subject: [PATCH 2/2] doc --- CHANGELOGS.rst | 3 +++ onnx_array_api/__init__.py | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOGS.rst b/CHANGELOGS.rst index 462c794..60088b6 100644 --- a/CHANGELOGS.rst +++ b/CHANGELOGS.rst @@ -1,6 +1,9 @@ Change Logs =========== +0.3.4 ++++++ + 0.3.3 +++++ diff --git a/onnx_array_api/__init__.py b/onnx_array_api/__init__.py index f3e0d56..0728d99 100644 --- a/onnx_array_api/__init__.py +++ b/onnx_array_api/__init__.py @@ -2,5 +2,5 @@ APIs to create ONNX Graphs. """ -__version__ = "0.3.3" +__version__ = "0.3.4" __author__ = "Xavier Dupré"