Skip to content

Commit a83d715

Browse files
committed
fix: build error
1 parent 04383f9 commit a83d715

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

Cargo.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "stochastic-rs"
3-
version = "0.13.1"
3+
version = "0.13.2"
44
edition = "2021"
55
license = "MIT"
66
description = "A Rust library for quant finance and simulating stochastic processes."
@@ -16,10 +16,9 @@ anyhow = "1.0.89"
1616
approx = "0.5.1"
1717
argmin = "0.10.0"
1818
bytemuck = "1.22.0"
19-
candle-core = "=0.8.1"
20-
candle-datasets = "=0.8.1"
21-
candle-nn = "=0.8.1"
22-
candle-transformers = "=0.8.1"
19+
candle-core = { version = "=0.8.1", optional = true }
20+
candle-datasets = { version = "=0.8.1", optional = true }
21+
candle-nn = { version = "=0.8.1", optional = true }
2322
chrono = "0.4.38"
2423
cudarc = { version = "0.13.9", optional = true, features = [
2524
"cuda-12080",
@@ -74,6 +73,7 @@ yahoo_finance_api = { version = "2.3.0", optional = true }
7473
[dev-dependencies]
7574

7675
[features]
76+
ai = ["dep:candle-core", "dep:candle-datasets", "dep:candle-nn"]
7777
cuda = ["dep:cudarc", "dep:libloading"]
7878
default = []
7979
jemalloc = ["dep:tikv-jemallocator"]

src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
1616
#[global_allocator]
1717
static GLOBAL: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc;
1818

19+
#[cfg(feature = "ai")]
1920
pub mod ai;
2021
#[doc(hidden)]
2122
mod macros;

0 commit comments

Comments
 (0)