Skip to content

Commit

Permalink
Specify required features for examples (#442)
Browse files Browse the repository at this point in the history
It will make `cargo test` not to break. They are not compilable without
those features enabled.
  • Loading branch information
blmarket committed Feb 10, 2024
1 parent c3a3f39 commit b68f7dc
Showing 1 changed file with 29 additions and 1 deletion.
30 changes: 29 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,32 @@ torch-sys = "0.14.0"
tempfile = "3"
itertools = "0.12"
tracing-subscriber = { version = "0.3", default-features = false, features = [ "env-filter", "fmt" ] }
ort = {version="~1.15.5", features = ["load-dynamic"]}
ort = {version="~1.15.5", features = ["load-dynamic"]}

[[example]]
name = "onnx-masked-lm"
required-features = ["onnx"]

[[example]]
name = "onnx-question-answering"
required-features = ["onnx"]

[[example]]
name = "onnx-sequence-classification"
required-features = ["onnx"]

[[example]]
name = "onnx-text-generation"
required-features = ["onnx"]

[[example]]
name = "onnx-token-classification"
required-features = ["onnx"]

[[example]]
name = "onnx-translation"
required-features = ["onnx"]

[[example]]
name = "generation_gpt2_hf_tokenizers"
required-features = ["hf-tokenizers"]

0 comments on commit b68f7dc

Please sign in to comment.