#1747 Upgrade Rust dependencies (#1748)

* #1747
Upgrade Rust dependencies

* Revert upgrade for tch

The update of tch on windows gives an error:

INTEL MKL ERROR: The specified module could not be found. mkl_vml_avx2.1.dll.
Intel MKL FATAL ERROR: cannot load mkl_vml_avx2.1.dll or mkl_vml_def.1.dll.

* Keep only .cargo/config.toml file which works with rust > 1.75

---------

Co-authored-by: Sylvain Benner <sylvain@benner.online>
This commit is contained in:
Ahmed Yarub Hani Al Nuaimi 2024-05-10 17:25:19 -03:00 committed by GitHub
parent b09d8431df
commit 10737527d8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
27 changed files with 779 additions and 292 deletions

1
.gitignore vendored
View File

@ -2,7 +2,6 @@ target
# These are backup files generated by rustfmt
**/*.rs.bk
.DS_Store
.cargo/config.toml
.dir-locals.el
.idea

858
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -21,61 +21,61 @@ exclude = [
[workspace.package]
edition = "2021"
version = "0.14.0"
version = "0.15.0"
readme = "README.md"
license = "MIT OR Apache-2.0"
[workspace.dependencies]
async-trait = "0.1.80"
bytemuck = "1.15"
bytemuck = "1.15.0"
# candle-core = { version = "0.4.1" }
candle-core = { git = "https://github.com/huggingface/candle.git", rev = "2817643" }
candle-core = { git = "https://github.com/huggingface/candle.git", rev = "82b641f" }
clap = { version = "4.5.4", features = ["derive"] }
colored = "2.1.0"
console_error_panic_hook = "0.1.7"
csv = "1.3.0"
dashmap = "5.5.3"
dirs = "5.0.1"
fake = "2.9.1"
flate2 = "1.0.29"
fake = "2.9.2"
flate2 = "1.0.30"
float-cmp = "0.9.0"
getrandom = { version = "0.2.14", default-features = false }
gix-tempfile = { version = "11.0.0", features = ["signals"] }
getrandom = { version = "0.2.15", default-features = false }
gix-tempfile = { version = "13.1.1", features = ["signals"] }
globwalk = "0.9.1"
hashbrown = "0.14.5"
indicatif = "0.17.8"
js-sys = "0.3.69"
libm = "0.2.8"
log = { default-features = false, version = "0.4.21" }
pretty_assertions = "1.4"
proc-macro2 = "1.0.79"
protobuf = "3.3"
protobuf-codegen = "3.3"
quote = "1.0.33"
pretty_assertions = "1.4.0"
proc-macro2 = "1.0.82"
protobuf = "3.4.0"
protobuf-codegen = "3.4.0"
quote = "1.0.36"
percent-encoding = "2.3.1"
r2d2 = "0.8.10"
r2d2_sqlite = { version = "0.23.0" }
r2d2_sqlite = { version = "0.24.0" }
rayon = "1.10.0"
regex = "1.10.4"
reqwest = "0.11.27"
reqwest = "0.12.4"
rmp-serde = "1.3.0"
rstest = "0.18.2"
rusqlite = { version = "0.30.0" }
rstest = "0.19.0"
rusqlite = { version = "0.31.0" }
rust-format = { version = "0.3.4" }
sanitize-filename = "0.5.0"
serde_rusqlite = "0.34.0"
serde_rusqlite = "0.35.0"
serde-wasm-bindgen = "0.6.5"
spin = { version = "0.9.8", features = ["mutex", "spin_mutex"] }
strum = "0.25.0"
strum_macros = "0.25.3"
syn = { version = "2.0", features = ["full", "extra-traits"] }
strum = "0.26.2"
strum_macros = "0.26.2"
syn = { version = "2.0.61", features = ["full", "extra-traits"] }
tempfile = "3.10.1"
thiserror = "1.0.58"
thiserror = "1.0.60"
tokio = { version = "1.37.0", features = ["rt", "macros"] }
tracing-appender = "0.2.3"
tracing-core = "0.1.32"
tracing-subscriber = "0.3.18"
wasm-bindgen = "0.2.88"
wasm-bindgen = "0.2.92"
wasm-bindgen-futures = "0.4.42"
wasm-logger = "0.2.0"
wasm-timer = "0.2.5"
@ -84,20 +84,20 @@ serial_test = "3.1.1"
web-time = "1.1.0"
hound = "3.5.1"
image = "0.25.1"
zip = "0.6.6"
zip = "1.2.1"
# Terminal UI
ratatui = "0.25"
crossterm = "0.27"
ratatui = "0.26.2"
crossterm = "0.27.0"
# WGPU stuff
futures-intrusive = "0.5"
futures-intrusive = "0.5.0"
text_placeholder = "0.5.0"
pollster = "0.3"
wgpu = "0.19.4"
pollster = "0.3.0"
wgpu = "0.20.0"
# Benchmarks and Burnbench
arboard = "3.3.2"
arboard = "3.4.0"
github-device-flow = "0.2.0"
os_info = "3.8.2"
wsl = "0.1.0"
@ -120,7 +120,7 @@ half = { version = "2.4.1", features = [
ndarray = { version = "0.15.6", default-features = false }
matrixmultiply = { version = "0.3.8", default-features = false }
openblas-src = "0.10.9"
blas-src = { version = "0.9.0", default-features = false }
blas-src = { version = "0.10.0", default-features = false }
num-traits = { version = "0.2.19", default-features = false, features = [
"libm",
] } # libm is for no_std
@ -128,17 +128,17 @@ rand = { version = "0.8.5", default-features = false, features = [
"std_rng",
] } # std_rng is for no_std
rand_distr = { version = "0.4.3", default-features = false }
serde = { version = "1.0.200", default-features = false, features = [
serde = { version = "1.0.201", default-features = false, features = [
"derive",
"alloc",
] } # alloc is for no_std, derive is needed
serde_json = { version = "1.0.115", default-features = false }
serde_json = { version = "1.0.117", default-features = false }
uuid = { version = "1.8.0", default-features = false }
libc = "0.2.154"
tch = "0.15.0"
nvml-wrapper = "0.9.0"
sysinfo = "0.30.10"
nvml-wrapper = "0.10.0"
sysinfo = "0.30.12"
systemstat = "0.2.3"

View File

@ -28,8 +28,8 @@ wgpu-fusion = ["wgpu", "burn/fusion"]
[dependencies]
arboard = { workspace = true }
burn = { path = "../crates/burn", default-features = false }
burn-common = { path = "../crates/burn-common", version = "0.14.0" }
burn-wgpu = { path = "../crates/burn-wgpu", default-features = false, version = "0.14.0" }
burn-common = { path = "../crates/burn-common", version = "0.15.0" }
burn-wgpu = { path = "../crates/burn-wgpu", default-features = false, version = "0.15.0" }
clap = { workspace = true }
colored = { workspace = true }
derive-new = { workspace = true }

View File

@ -14,7 +14,7 @@ automatically add the missing imports as you add the code snippets to your code.
Be sure to checkout the git branch corresponding to the version of Burn you are using to follow
this guide.
The current version of Burn is `0.14` and the corresponding branch to checkout is `main`.
The current version of Burn is `0.15` and the corresponding branch to checkout is `main`.
</div>
The code for this demo can be executed from Burn's base directory using the command:

View File

@ -20,7 +20,7 @@ version = "0.1.0"
edition = "2021"
[dependencies]
burn = { version = "0.14.0", features = ["train", "wgpu", "vision"] }
burn = { version = "0.15.0", features = ["train", "wgpu", "vision"] }
```
Our goal will be to create a basic convolutional neural network used for image classification. We

View File

@ -17,15 +17,15 @@ std = []
async = [] # Require std
[dependencies]
burn-common = { path = "../burn-common", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false }
burn-tensor-testgen = { path = "../burn-tensor-testgen", version = "0.14.0", optional = true }
burn-common = { path = "../burn-common", version = "0.15.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false }
burn-tensor-testgen = { path = "../burn-tensor-testgen", version = "0.15.0", optional = true }
derive-new = { workspace = true }
spin = { workspace = true }
log = { workspace = true }
[dev-dependencies]
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false, features = [
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false, features = [
"export_tests",
] }

View File

@ -21,17 +21,17 @@ accelerate = ["candle-core/accelerate"]
[dependencies]
derive-new = { workspace = true }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false }
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false }
half = { workspace = true }
candle-core = { workspace = true }
[dev-dependencies]
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0", default-features = false, features = [
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0", default-features = false, features = [
"export_tests",
] }
burn-tch = { path = "../burn-tch", version = "0.14.0", default-features = false, features = [
burn-tch = { path = "../burn-tch", version = "0.15.0", default-features = false, features = [
] }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false, features = [
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false, features = [
"export_tests",
] }

View File

@ -34,7 +34,7 @@ autotune-persistent-cache = [
] # Assume std
[dependencies]
burn-common = { path = "../burn-common", version = "0.14.0", default-features = false }
burn-common = { path = "../burn-common", version = "0.15.0", default-features = false }
derive-new = { workspace = true }
spin = { workspace = true }
log = { workspace = true }

View File

@ -99,17 +99,17 @@ test-wgpu = ["wgpu"] # To use wgpu during testing, default uses ndarray.
# ** Please make sure all dependencies support no_std when std is disabled **
burn-common = { path = "../burn-common", version = "0.14.0", default-features = false }
burn-dataset = { path = "../burn-dataset", version = "0.14.0", optional = true, default-features = false }
burn-derive = { path = "../burn-derive", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false }
burn-common = { path = "../burn-common", version = "0.15.0", default-features = false }
burn-dataset = { path = "../burn-dataset", version = "0.15.0", optional = true, default-features = false }
burn-derive = { path = "../burn-derive", version = "0.15.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false }
# Backends
burn-ndarray = { path = "../burn-ndarray", version = "0.14.0", optional = true, default-features = false }
burn-wgpu = { path = "../burn-wgpu", version = "0.14.0", optional = true, default-features = false }
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0", optional = true }
burn-tch = { path = "../burn-tch", version = "0.14.0", optional = true }
burn-candle = { path = "../burn-candle", version = "0.14.0", optional = true }
burn-ndarray = { path = "../burn-ndarray", version = "0.15.0", optional = true, default-features = false }
burn-wgpu = { path = "../burn-wgpu", version = "0.15.0", optional = true, default-features = false }
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0", optional = true }
burn-tch = { path = "../burn-tch", version = "0.15.0", optional = true }
burn-candle = { path = "../burn-candle", version = "0.15.0", optional = true }
derive-new = { workspace = true }
log = { workspace = true, optional = true }
@ -135,12 +135,12 @@ num-traits = { workspace = true }
[dev-dependencies]
tempfile = { workspace = true }
burn-dataset = { path = "../burn-dataset", version = "0.14.0", features = [
burn-dataset = { path = "../burn-dataset", version = "0.15.0", features = [
"fake",
] }
burn-ndarray = { path = "../burn-ndarray", version = "0.14.0", default-features = false }
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0" }
burn-ndarray = { path = "../burn-ndarray", version = "0.15.0", default-features = false }
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0" }
[package.metadata.docs.rs]
features = ["doc"]

View File

@ -18,11 +18,11 @@ doc = ["burn-jit/doc"]
std = ["burn-jit/std"]
[dependencies]
burn-jit = { path = "../burn-jit", version = "0.14.0", default-features = false }
burn-compute = { path = "../burn-compute", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.14.0" }
burn-common = { path = "../burn-common", version = "0.14.0" }
burn-fusion = { path = "../burn-fusion", version = "0.14.0", optional = true }
burn-jit = { path = "../burn-jit", version = "0.15.0", default-features = false }
burn-compute = { path = "../burn-compute", version = "0.15.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0" }
burn-common = { path = "../burn-common", version = "0.15.0" }
burn-fusion = { path = "../burn-fusion", version = "0.15.0", optional = true }
half = { workspace = true }
bytemuck = { workspace = true }
@ -32,7 +32,7 @@ log = { workspace = true }
derive-new = { workspace = true }
[dev-dependencies]
burn-jit = { path = "../burn-jit", version = "0.14.0", default-features = false, features = [
burn-jit = { path = "../burn-jit", version = "0.15.0", default-features = false, features = [
"export_tests",
] }

View File

@ -33,7 +33,7 @@ __sqlite-shared = [
]
[dependencies]
burn-common = { path = "../burn-common", version = "0.14.0", optional = true, features = [
burn-common = { path = "../burn-common", version = "0.15.0", optional = true, features = [
"network",
] }
csv = { workspace = true }

View File

@ -16,8 +16,8 @@ std = ["serde/std"]
doc = ["default"]
[dependencies]
burn-tensor = { path = "../burn-tensor", version = "0.14.0" }
burn-common = { path = "../burn-common", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0" }
burn-common = { path = "../burn-common", version = "0.15.0" }
hashbrown = { workspace = true }
derive-new = {workspace = true }
spin = { workspace = true }

View File

@ -19,7 +19,7 @@ onnx = []
pytorch = ["burn/record-item-custom-serde", "thiserror", "zip"]
[dependencies]
burn = { path = "../burn", version = "0.14.0", features = ["ndarray"] }
burn = { path = "../burn", version = "0.15.0", features = ["ndarray"] }
bytemuck = { workspace = true }
candle-core = { workspace = true }

View File

@ -27,9 +27,9 @@ export_tests = [
]
[dependencies]
burn-common = { path = "../burn-common", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.14.0" }
burn-fusion = { path = "../burn-fusion", version = "0.14.0", optional = true }
burn-common = { path = "../burn-common", version = "0.15.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0" }
burn-fusion = { path = "../burn-fusion", version = "0.15.0", optional = true }
bytemuck = { workspace = true }
derive-new = { workspace = true }
@ -44,16 +44,16 @@ serde = { workspace = true }
text_placeholder = { workspace = true, features = ["struct_context"] }
hashbrown = { workspace = true }
burn-compute = { path = "../burn-compute", version = "0.14.0", default-features = false, features = [
burn-compute = { path = "../burn-compute", version = "0.15.0", default-features = false, features = [
"channel-mutex",
"std",
] }
burn-tensor-testgen = { path = "../burn-tensor-testgen", version = "0.14.0", optional = true }
burn-tensor-testgen = { path = "../burn-tensor-testgen", version = "0.15.0", optional = true }
# When exporting tests
serial_test = { workspace = true, optional = true }
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0", default-features = false, optional = true }
burn-ndarray = { path = "../burn-ndarray", version = "0.14.0", optional = true }
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0", default-features = false, optional = true }
burn-ndarray = { path = "../burn-ndarray", version = "0.15.0", optional = true }
[package.metadata.docs.rs]
features = ["doc"]

View File

@ -42,9 +42,9 @@ blas-openblas-system = [
# ** Please make sure all dependencies support no_std when std is disabled **
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0", optional = true }
burn-common = { path = "../burn-common", version = "0.14.0", default-features = false }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false }
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0", optional = true }
burn-common = { path = "../burn-common", version = "0.15.0", default-features = false }
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false }
matrixmultiply = { workspace = true, default-features = false }
rayon = { workspace = true, optional = true }
@ -58,10 +58,10 @@ rand = { workspace = true }
spin = { workspace = true } # using in place of use std::sync::Mutex;
[dev-dependencies]
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0", default-features = false, features = [
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0", default-features = false, features = [
"export_tests",
] }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false, features = [
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false, features = [
"export_tests",
] }

View File

@ -14,7 +14,7 @@ version.workspace = true
# ** Please make sure all dependencies support no_std **
burn = { path = "../burn", version = "0.14.0", default-features = false }
burn-ndarray = { path = "../burn-ndarray", version = "0.14.0", default-features = false }
burn = { path = "../burn", version = "0.15.0", default-features = false }
burn-ndarray = { path = "../burn-ndarray", version = "0.15.0", default-features = false }
serde = { workspace = true }

View File

@ -15,7 +15,7 @@ default = []
doc = ["tch/doc-only"]
[dependencies]
burn-tensor = { path = "../burn-tensor", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0" }
half = { workspace = true, features = ["std"] }
libc = { workspace = true }
@ -23,10 +23,10 @@ rand = { workspace = true, features = ["std"] }
tch = { workspace = true, features = ["download-libtorch"] }
[dev-dependencies]
burn-autodiff = { path = "../burn-autodiff", version = "0.14.0", default-features = false, features = [
burn-autodiff = { path = "../burn-autodiff", version = "0.15.0", default-features = false, features = [
"export_tests",
] }
burn-tensor = { path = "../burn-tensor", version = "0.14.0", default-features = false, features = [
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false, features = [
"export_tests",
] }

View File

@ -20,8 +20,8 @@ repr = []
wasm-sync = []
[dependencies]
burn-common = { path = "../burn-common", version = "0.14.0", default-features = false }
burn-tensor-testgen = { path = "../burn-tensor-testgen", version = "0.14.0", optional = true }
burn-common = { path = "../burn-common", version = "0.15.0", default-features = false }
burn-tensor-testgen = { path = "../burn-tensor-testgen", version = "0.15.0", optional = true }
derive-new = { workspace = true }
half = { workspace = true }

View File

@ -17,7 +17,7 @@ metrics = ["nvml-wrapper", "sysinfo", "systemstat"]
tui = ["ratatui", "crossterm"]
[dependencies]
burn-core = { path = "../burn-core", version = "0.14.0", features = ["dataset"] }
burn-core = { path = "../burn-core", version = "0.15.0", features = ["dataset"] }
log = { workspace = true }
tracing-subscriber = { workspace = true }
@ -38,7 +38,7 @@ derive-new = { workspace = true }
serde = { workspace = true, features = ["std", "derive"] }
[dev-dependencies]
burn-ndarray = { path = "../burn-ndarray", version = "0.14.0" }
burn-ndarray = { path = "../burn-ndarray", version = "0.15.0" }
[package.metadata.docs.rs]
features = ["doc"]

View File

@ -219,12 +219,7 @@ impl<'a> NumericMetricView<'a> {
)
.split(size);
let titles = titles
.iter()
.map(|i| Line::from(vec![i.clone().yellow()]))
.collect();
let tabs = Tabs::new(titles)
let tabs = Tabs::new(titles.iter().map(|i| Line::from(vec![i.clone().yellow()])))
.select(selected)
.style(Style::default())
.highlight_style(

View File

@ -19,11 +19,11 @@ doc = ["burn-jit/doc"]
std = ["burn-jit/std"]
[dependencies]
burn-jit = { path = "../burn-jit", version = "0.14.0", default-features = false }
burn-compute = { path = "../burn-compute", version = "0.14.0" }
burn-tensor = { path = "../burn-tensor", version = "0.14.0" }
burn-common = { path = "../burn-common", version = "0.14.0" }
burn-fusion = { path = "../burn-fusion", version = "0.14.0", optional = true }
burn-jit = { path = "../burn-jit", version = "0.15.0", default-features = false }
burn-compute = { path = "../burn-compute", version = "0.15.0" }
burn-tensor = { path = "../burn-tensor", version = "0.15.0" }
burn-common = { path = "../burn-common", version = "0.15.0" }
burn-fusion = { path = "../burn-fusion", version = "0.15.0", optional = true }
bytemuck = { workspace = true }
wgpu = { workspace = true, features = ["fragile-send-sync-non-atomic-wasm"] }
@ -35,6 +35,6 @@ derive-new = { workspace = true }
hashbrown = { workspace = true }
[dev-dependencies]
burn-jit = { path = "../burn-jit", version = "0.14.0", default-features = false, features = [
burn-jit = { path = "../burn-jit", version = "0.15.0", default-features = false, features = [
"export_tests",
] }

View File

@ -109,6 +109,7 @@ where
layout: None,
module: &module,
entry_point: "main",
compilation_options: Default::default(),
}),
)
}

View File

@ -68,8 +68,8 @@ record-item-custom-serde = ["burn-core/record-item-custom-serde"]
# ** Please make sure all dependencies support no_std when std is disabled **
burn-core = { path = "../burn-core", version = "0.14.0", default-features = false }
burn-train = { path = "../burn-train", version = "0.14.0", optional = true, default-features = false }
burn-core = { path = "../burn-core", version = "0.15.0", default-features = false }
burn-train = { path = "../burn-train", version = "0.15.0", optional = true, default-features = false }
[package.metadata.docs.rs]
features = ["doc"]

View File

@ -14,11 +14,11 @@ default = []
half_precision = []
[dependencies]
burn = { path = "../../crates/burn", version = "0.14.0", default-features = false, features = [
burn = { path = "../../crates/burn", version = "0.15.0", default-features = false, features = [
"ndarray",
] }
burn-wgpu = { path = "../../crates/burn-wgpu", version = "0.14.0", default-features = false }
burn-candle = { path = "../../crates/burn-candle", version = "0.14.0", default-features = false }
burn-wgpu = { path = "../../crates/burn-wgpu", version = "0.15.0", default-features = false }
burn-candle = { path = "../../crates/burn-candle", version = "0.15.0", default-features = false }
js-sys = { workspace = true }
log = { workspace = true }

View File

@ -4,7 +4,7 @@ edition = "2021"
license = "MIT OR Apache-2.0"
name = "pytorch-import"
publish = false
version = "0.14.0"
version = "0.15.0"
[dependencies]
burn = { path = "../../crates/burn", features = [