Commit Graph

469 Commits

Author SHA1 Message Date
Carson M.
ab13822ff2 docs: switch rustdoc links back to docs.rs v2.0.0-rc.7 2024-10-18 17:50:08 -05:00
Carson M.
b1996eb4f9 2.0.0-rc.7 2024-10-18 17:47:55 -05:00
Carson M.
d0ee39533d feat: impl Clone for MemoryInfo 2024-10-18 17:38:36 -05:00
Carson M.
b0e7ebe322 fix(sys): more abseil lib fixes for master onnxruntime 2024-10-18 16:29:25 -05:00
Carson M.
884c2959f6 ci(test): run on macOS 13 (x64) and 15 (ARM64)
since 12 is now deprecated
2024-10-18 13:35:42 -05:00
Carson M.
74fb47d0bf ci(code-quality): run coverage on ubuntu 24.04 2024-10-18 13:33:08 -05:00
Carson M.
a779c3b1bd fix(sys): link lora lib if it exists, fixes #300 2024-10-18 13:28:02 -05:00
Carson M.
b19cff4de3 feat: expose pointers for everything 2024-10-18 09:35:58 -05:00
Carson M.
1e2e7b04ae feat: explicit io binding synchronization 2024-10-18 09:35:58 -05:00
Carson M.
67d579404a chore: address clippy warnings 2024-10-18 09:35:58 -05:00
web3nomad.eth
87dc4f21fa examples(phi-3-vision): Simplify input processing with KV cache (#296)
With KV cache, full input sequence reconstruction is unnecessary.
Only process the newly generated token for each iteration.
2024-10-15 11:02:09 -05:00
Carson M.
cdd6be7a66 chore(*): format code 2024-10-14 00:41:21 -05:00
Brad Neuman
ae7b594d7f feat(sys): Support explicit dynamic linking of onnxruntime (#295)
Previously, if static library files were found, the build script in ort-sys
would always prefer static linking.

This PR introduces a new env variable, ORT_PREFER_DYNAMIC_LINK, that can be
set (to 1 or "true") to use dynamic linking even if the static library files are
present in the onnxruntime path.

Additionally, since cuda and tensorrt require dynamic linking, static linking is
disabled when these features are present.
2024-10-11 16:41:41 -05:00
Brad Neuman
c882c58bcb fix(sys): Add abs_debugging_internal to rust-c link to avoid linker error. (#294)
Without this change, I was getting an error in linking when linking against a
local build of onnxruntime
2024-10-11 14:16:55 -05:00
Carson M.
fbe8cbf0e9 fix: maybe handle non-UTF-8/null error messages 2024-10-10 09:12:07 -05:00
Julien Cretin
b31f28a080 docs: bump requirements for x86-64 on linux (#293)
See https://github.com/pykeio/ort/issues/268#issuecomment-2297772586
2024-10-10 08:52:48 -05:00
web3nomad.eth
b17dbdb643 examples: image chat generation with phi-3 vision (#291) 2024-10-04 10:26:52 -05:00
Carson M.
f915bcaa57 feat: expose arbitrary session config entries 2024-10-03 14:07:24 -05:00
Carson M.
542f210d7c refactor: make Environment and ExecutionProvider send & sync 2024-10-03 14:00:39 -05:00
Carson M.
2e1f014377 feat: upgrade ValueRef(Mut) to Value 2024-10-01 11:42:37 -05:00
Carson M.
b1fb8c028e fix: return owned Values from extract_sequence 2024-10-01 11:34:22 -05:00
Carson M.
1f6f436117 fix: ValueRef(Mut) should clone ValueInner 2024-10-01 11:33:23 -05:00
Carson M.
250222443b fix(sys): do not link clog on android, ref #288 2024-09-25 10:57:41 -05:00
Carson M.
89416d1976 docs: explain up/downcasting 2024-09-24 13:17:16 -05:00
Carson M.
c8b36f33e8 feat: load external initializers from memory, closes #286 2024-09-23 14:05:19 -05:00
Carson M.
4da570026a fix(sys): absl linking, closes #285 2024-09-23 13:48:11 -05:00
Carson M.
cf1be8637c refactor: remove lifetime bound for IoBinding
And implement `Send` for it. yw audioxd
2024-09-22 23:23:47 -05:00
Carson M.
bd3c891e77 feat: impl Send for Allocator 2024-09-22 10:47:27 -05:00
Carson M.
abd527b6a1 feat: arbitrarily configurable execution providers 2024-09-20 21:04:12 -05:00
Carson M.
e16fd5bbcf feat: more options for CUDA EP 2024-09-20 20:12:44 -05:00
Carson M.
7f71e6cf3e feat: impl Sync for Value
A type is Sync "if there is no possibility of undefined behavior (including data races) when passing &T references between threads."
In the case of `ort::Value`, we don't offer any mutability on `&self`, only `&mut self`, so it is `Sync` by definition.
2024-09-19 12:22:48 -05:00
Carson M.
6de6aa5b60 feat: get overridable graph initializers 2024-09-17 16:44:58 -05:00
Carson M.
b58595c26d refactor: use new oneDNN registration API 2024-09-16 14:33:31 -05:00
Carson M.
359a051419 refactor!: remove redundant error checks; more useful downcast messages
Many of the ORT APIs are hardcoded to actually *never* return a failure status, despite returning `*mut OrtStatus`, probably for consistency (which is appreciated!)
For `ort`, this means almost every API requires a ? or unwrap, even if it will never fail. Notably, this includes all functions on `MemoryInfo`.
This commit makes many of these functions return `T` instead of `Result<T>`.

Additionally, I found that all of the `downcast` methods on `Value` just panic if the type is not downcastable - that's bad! Now a nice `Display` is implemented for `ValueType`, and the downcast functions actually return errors. Extraction methods also have better error messages.

Also in this commit: checking if memory is CPU accessible the *correct* way instead of matching AllocationDevices.
2024-09-14 17:15:06 -05:00
Carson M.
b9ef6aa529 docs: clarity, add favicon & description 2024-09-14 17:02:47 -05:00
Carson M.
af30987812 docs: update 2024-09-12 15:22:39 -05:00
Carson M.
b8d09a24e5 chore(sys): remove CUDA version detection logic 2024-09-12 14:47:21 -05:00
Carson M.
7ad5b84e5a temporarily redirect rustdoc links 2024-09-10 21:57:46 -05:00
Carson M.
66111eccf1 fix: docs.rs build 2024-09-10 19:51:07 -05:00
Carson M.
ee5cc2046c 2.0.0-rc.6 v2.0.0-rc.6 2024-09-10 16:19:06 -05:00
Carson M.
6b3e7a0730 feat: threadpool access in operator kernels 2024-09-09 16:31:21 -05:00
Carson M.
41ef65abd6 feat: RKNPU execution provider 2024-09-09 16:29:07 -05:00
Carson M.
25768125a2 feat: Vitis AI execution provider 2024-09-08 23:08:10 -05:00
Carson M.
eb918fecc5 fix: import 2024-09-06 22:15:49 -05:00
Carson M.
c7ddbdb18e refactor: let ONNX Runtime manage operator library handles
This removes the `libc` & `winapi` dependencies (though they were gated behind `operator-libraries`, so not really any impact...)
2024-09-06 22:08:16 -05:00
Carson M.
60f6ecae90 chore: update to ONNX Runtime v1.19.2 2024-09-05 00:17:56 -05:00
Carson M.
e91a8ad7b5 feat: get build info 2024-09-04 20:18:22 -05:00
Carson M.
a9557aae39 examples(model-info): display optional types 2024-09-04 20:15:53 -05:00
Carson M.
52422ae47d feat: support optional ValueTypes
According to the C API, these only appear in model metadata, so no need to implement another `Value<T>`.
2024-09-04 20:08:03 -05:00
Carson M.
dc08a6b3fd chore: update API ignorelist 2024-09-02 19:59:11 -05:00