diff --git a/Cargo.toml b/Cargo.toml index b63f11ab..200e5d7a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -76,14 +76,14 @@ features = ["doc-only"] [dependencies] rust_tokenizers = "8.1.1" -tch = { version = "0.16.0", features = ["download-libtorch"] } +tch = { version = "0.17.0", features = ["download-libtorch"] } serde_json = "1" serde = { version = "1", features = ["derive"] } ordered-float = "4.2.0" uuid = { version = "1", features = ["v4"] } thiserror = "1" half = "2" -regex = "1.6" +regex = "1.10" cached-path = { version = "0.6", default-features = false, optional = true } dirs = { version = "5", optional = true } @@ -92,7 +92,7 @@ ort = { version = "1.16.3", optional = true, default-features = false, features "half", ] } ndarray = { version = "0.15", optional = true } -tokenizers = { version = "0.19.1", optional = true, default-features = false, features = [ +tokenizers = { version = "0.20", optional = true, default-features = false, features = [ "onig", ] } diff --git a/README.md b/README.md index f91cf7ff..e3f380f7 100644 --- a/README.md +++ b/README.md @@ -103,7 +103,7 @@ models used by this library are in the order of the 100s of MBs to GBs. package requires `v2.2`: if this version is no longer available on the "get started" page, the file should be accessible by modifying the target link, for example - `https://download.pytorch.org/libtorch/cu121/libtorch-cxx11-abi-shared-with-deps-2.2.0%2Bcu121.zip` + `https://download.pytorch.org/libtorch/cu124/libtorch-cxx11-abi-shared-with-deps-2.4.0%2Bcu124.zip` for a Linux version with CUDA12. **NOTE:** When using `rust-bert` as dependency from [crates.io](https://crates.io), please check the required `LIBTORCH` on the published package @@ -140,7 +140,7 @@ Alternatively, you can let the `build` script automatically download the `libtorch` library for you. The `download-libtorch` feature flag needs to be enabled. The CPU version of libtorch will be downloaded by default. To download a CUDA version, please set the environment variable `TORCH_CUDA_VERSION` to -`cu118`. Note that the libtorch library is large (order of several GBs for the +`cu124`. Note that the libtorch library is large (order of several GBs for the CUDA-enabled version) and the first build may therefore take several minutes to complete. diff --git a/src/lib.rs b/src/lib.rs index 20164892..511348d1 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -90,8 +90,8 @@ //! //! ### Manual installation (recommended) //! -//! 1. Download `libtorch` from . This package requires `v2.2`: if this version is no longer available on the "get started" page, -//! the file should be accessible by modifying the target link, for example `https://download.pytorch.org/libtorch/cu121/libtorch-cxx11-abi-shared-with-deps-2.2.0%2Bcu121.zip` for a Linux version with CUDA12. +//! 1. Download `libtorch` from . This package requires `v2.4`: if this version is no longer available on the "get started" page, +//! the file should be accessible by modifying the target link, for example `https://download.pytorch.org/libtorch/cu124/libtorch-cxx11-abi-shared-with-deps-2.4.0%2Bcu124.zip` for a Linux version with CUDA12. //! 2. Extract the library to a location of your choice //! 3. Set the following environment variables //! ##### Linux: @@ -109,7 +109,7 @@ //! ### Automatic installation //! //! Alternatively, you can let the `build` script automatically download the `libtorch` library for you. The `download-libtorch` feature flag needs to be enabled. -//! The CPU version of libtorch will be downloaded by default. To download a CUDA version, please set the environment variable `TORCH_CUDA_VERSION` to `cu118`. +//! The CPU version of libtorch will be downloaded by default. To download a CUDA version, please set the environment variable `TORCH_CUDA_VERSION` to `cu124`. //! Note that the libtorch library is large (order of several GBs for the CUDA-enabled version) and the first build may therefore take several minutes to complete. //! //! ## ONNX Support (Optional)