mirror of https://github.com/tracel-ai/burn.git
enable doc_auto_cfg to show feature-req-hint in docs.rs (#2271)
This commit is contained in:
parent
0592af0e8a
commit
e3b10c65ce
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-autodiff"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-autodiff"
|
||||
documentation = "https://docs.rs/burn-autodiff"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -29,3 +30,7 @@ log = { workspace = true }
|
|||
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false, features = [
|
||||
"export_tests",
|
||||
] }
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["default"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! # Burn Autodiff
|
||||
//!
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-candle"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-candle"
|
||||
documentation = "https://docs.rs/burn-candle"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -18,7 +19,6 @@ cuda = ["candle-core/cuda"]
|
|||
metal = ["candle-core/metal"]
|
||||
accelerate = ["candle-core/accelerate"]
|
||||
|
||||
|
||||
[dependencies]
|
||||
derive-new = { workspace = true }
|
||||
burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features = false }
|
||||
|
@ -37,3 +37,4 @@ burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features =
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
#![allow(unused)] // TODO remove when backend filled
|
||||
|
||||
//! Burn Candle Backend
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-common"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-common"
|
||||
documentation = "https://docs.rs/burn-common"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -21,7 +22,6 @@ rayon = ["dep:rayon"]
|
|||
getrandom = { workspace = true, features = ["js"] }
|
||||
web-time = { version = "1.1.0" }
|
||||
|
||||
|
||||
[dependencies]
|
||||
# Network downloader
|
||||
indicatif = { workspace = true, optional = true }
|
||||
|
@ -37,3 +37,4 @@ dashmap = { workspace = true }
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#![cfg_attr(not(feature = "std"), no_std)]
|
||||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! # Burn Common Library
|
||||
//!
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-core"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-core"
|
||||
documentation = "https://docs.rs/burn-core"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -50,6 +51,7 @@ doc = [
|
|||
"ndarray",
|
||||
"tch",
|
||||
"wgpu",
|
||||
"cuda-jit",
|
||||
"vision",
|
||||
"autodiff",
|
||||
# Doc features
|
||||
|
@ -155,3 +157,4 @@ burn-autodiff = { path = "../burn-autodiff", version = "0.15.0" }
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#![cfg_attr(not(feature = "std"), no_std)]
|
||||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! The core crate of Burn.
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-cuda"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-cuda"
|
||||
documentation = "https://docs.rs/burn-cuda"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -36,3 +37,4 @@ burn-jit = { path = "../burn-jit", version = "0.15.0", default-features = false,
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
use burn_jit::JitBackend;
|
||||
|
|
|
@ -8,21 +8,17 @@ license.workspace = true
|
|||
name = "burn-dataset"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-dataset"
|
||||
documentation = "https://docs.rs/burn-dataset"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
default = ["sqlite-bundled"]
|
||||
doc = ["default"]
|
||||
|
||||
audio = ["hound"]
|
||||
|
||||
fake = ["dep:fake"]
|
||||
|
||||
sqlite = ["__sqlite-shared", "dep:rusqlite"]
|
||||
sqlite-bundled = ["__sqlite-shared", "rusqlite/bundled"]
|
||||
|
||||
vision = ["dep:flate2", "dep:globwalk", "dep:burn-common", "dep:image"]
|
||||
|
||||
# internal
|
||||
__sqlite-shared = [
|
||||
"dep:r2d2",
|
||||
|
@ -31,7 +27,6 @@ __sqlite-shared = [
|
|||
"dep:image",
|
||||
"dep:gix-tempfile",
|
||||
]
|
||||
|
||||
dataframe = ["dep:polars"]
|
||||
|
||||
[dependencies]
|
||||
|
@ -72,3 +67,4 @@ normal = ["strum", "strum_macros"]
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! # Burn Dataset
|
||||
//!
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-fusion"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-fusion"
|
||||
documentation = "https://docs.rs/burn-fusion"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -27,3 +28,4 @@ half = { workspace = true }
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! # Burn Fusion
|
||||
//!
|
||||
|
|
|
@ -9,6 +9,7 @@ license.workspace = true
|
|||
name = "burn-import"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-import"
|
||||
documentation = "https://docs.rs/burn-import"
|
||||
version.workspace = true
|
||||
|
||||
default-run = "onnx2burn"
|
||||
|
@ -40,3 +41,7 @@ zip = { workspace = true, optional = true }
|
|||
[dev-dependencies]
|
||||
pretty_assertions = { workspace = true }
|
||||
rstest = { workspace = true }
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["default"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
#![allow(clippy::ptr_arg)]
|
||||
#![allow(clippy::single_match)]
|
||||
#![allow(clippy::upper_case_acronyms)]
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-jit"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-jit"
|
||||
documentation = "https://docs.rs/burn-jit"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -56,3 +57,4 @@ serial_test = { workspace = true, optional = true }
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! Burn JIT Backend
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-ndarray"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-ndarray"
|
||||
documentation = "https://docs.rs/burn-ndarray"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -70,3 +71,4 @@ burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features =
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#![cfg_attr(not(feature = "std"), no_std)]
|
||||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! Burn ndarray backend.
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-tch"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-tch"
|
||||
documentation = "https://docs.rs/burn-tch"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -33,3 +34,4 @@ burn-tensor = { path = "../burn-tensor", version = "0.15.0", default-features =
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
#![allow(clippy::single_range_in_vec_init)]
|
||||
|
||||
//! Burn Tch Backend
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-tensor"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-tensor"
|
||||
documentation = "https://docs.rs/burn-tensor"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -53,3 +54,4 @@ rand = { workspace = true, features = ["std", "std_rng"] } # Default enables std
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#![cfg_attr(not(feature = "std"), no_std)]
|
||||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
// Allow deprecated `Data` and `DataSerialize`
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-train"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-train"
|
||||
documentation = "https://docs.rs/burn-train"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -17,7 +18,10 @@ metrics = ["nvml-wrapper", "sysinfo", "systemstat"]
|
|||
tui = ["ratatui", "crossterm"]
|
||||
|
||||
[dependencies]
|
||||
burn-core = { path = "../burn-core", version = "0.15.0", features = ["dataset", "std"], default-features = false }
|
||||
burn-core = { path = "../burn-core", version = "0.15.0", features = [
|
||||
"dataset",
|
||||
"std",
|
||||
], default-features = false }
|
||||
|
||||
log = { workspace = true }
|
||||
tracing-subscriber = { workspace = true }
|
||||
|
@ -42,3 +46,4 @@ burn-ndarray = { path = "../burn-ndarray", version = "0.15.0" }
|
|||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["doc"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#![warn(missing_docs)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
//! A library for training neural networks using the burn crate.
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ license.workspace = true
|
|||
name = "burn-wgpu"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/burn-wgpu"
|
||||
documentation = "https://docs.rs/burn-wgpu"
|
||||
version.workspace = true
|
||||
|
||||
[features]
|
||||
|
@ -32,3 +33,7 @@ burn-tensor = { path = "../burn-tensor", version = "0.15.0", features = [
|
|||
burn-jit = { path = "../burn-jit", version = "0.15.0", default-features = false, features = [
|
||||
"export_tests",
|
||||
] }
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["default"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
#[cfg(feature = "template")]
|
||||
|
|
|
@ -8,13 +8,14 @@ license.workspace = true
|
|||
name = "burn"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn"
|
||||
documentation = "https://docs.rs/burn"
|
||||
version.workspace = true
|
||||
rust-version = "1.80"
|
||||
|
||||
[features]
|
||||
default = ["burn-core/default", "burn-train?/default", "std"]
|
||||
std = ["burn-core/std"]
|
||||
doc = ["default", "burn-core/doc", "burn-train/doc"]
|
||||
doc = ["default", "train", "burn-core/doc", "burn-train/doc"]
|
||||
|
||||
# Training with full features
|
||||
train = ["burn-train", "autodiff", "dataset"]
|
||||
|
@ -69,6 +70,3 @@ record-backward-compat = ["burn-core/record-backward-compat"]
|
|||
|
||||
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"]
|
||||
|
|
|
@ -93,6 +93,8 @@
|
|||
//! - `std`: Activates the standard library (deactivate for no_std)
|
||||
//! - `network`: Enables network utilities (currently, only a file downloader with progress bar)
|
||||
//! - `experimental-named-tensor`: Enables named tensors (experimental)
|
||||
//!
|
||||
//! You can also check the details in sub-crates [`burn-core`](https://docs.rs/burn-core) and [`burn-train`](https://docs.rs/burn-train).
|
||||
|
||||
pub use burn_core::*;
|
||||
|
||||
|
|
|
@ -9,6 +9,7 @@ license.workspace = true
|
|||
name = "onnx-ir"
|
||||
readme.workspace = true
|
||||
repository = "https://github.com/tracel-ai/burn/tree/main/crates/onnx-ir"
|
||||
documentation = "https://docs.rs/onnx-ir"
|
||||
version.workspace = true
|
||||
|
||||
|
||||
|
|
|
@ -17,8 +17,8 @@ tch-gpu = ["burn/tch"]
|
|||
wgpu = ["burn/wgpu"]
|
||||
|
||||
[dependencies]
|
||||
burn = {path = "../../crates/burn", features=["train"]}
|
||||
burn = { path = "../../crates/burn", features = ["train"] }
|
||||
|
||||
# Serialization
|
||||
log = {workspace = true}
|
||||
serde = {workspace = true, features = ["std", "derive"]}
|
||||
log = { workspace = true }
|
||||
serde = { workspace = true, features = ["std", "derive"] }
|
||||
|
|
Loading…
Reference in New Issue