Skip to main content

ruda_tensor/api/
mod.rs

1pub(crate) mod stats;
2
3pub(crate) mod check;
4
5mod autodiff;
6mod base;
7mod bool;
8mod cartesian_grid;
9#[path = "cast.rs"]
10mod tensor_cast;
11mod float;
12mod fmod;
13mod int;
14mod numeric;
15mod options;
16mod orderable;
17mod pad;
18pub use pad::IntoPadding;
19mod take;
20mod transaction;
21pub mod sparse;
22
23mod trunc;
24
25pub use autodiff::*;
26pub use base::*;
27pub use cartesian_grid::cartesian_grid;
28pub use tensor_cast::*;
29pub use crate::element::cast;
30pub use float::{DEFAULT_ATOL, DEFAULT_RTOL};
31pub use numeric::*;
32pub use options::*;
33pub use transaction::*;
34
35pub use crate::tensor::IndexingUpdateOp;
36
37// Re-exported types
38pub use crate::{
39    BoolDType, BoolStore, DType, DataError, FloatDType, IntDType, TensorData, TensorMetadata,
40    TensorPrimitive, Tolerance,
41    distribution::*,
42    element::*,
43    indexing::*,
44    ops::TransactionPrimitive,
45    shape::*,
46    slice::*,
47    tensor::{Bool, Float, Int, TensorKind},
48};
49
50/// The activation module.
51pub mod activation;
52
53/// The backend module.
54pub mod backend {
55    pub use crate::backend::*;
56}
57
58/// The container module.
59pub mod container {
60    pub use crate::tensor::TensorContainer;
61}
62
63/// The grid module.
64pub mod grid;
65
66/// The linalg module.
67pub mod linalg;
68
69/// The loss module.
70pub mod loss;
71
72/// The neural network module.
73pub mod module;
74
75/// The signal processing module.
76pub mod signal;
77
78/// Operations on tensors module.
79pub mod ops {
80    pub use crate::backend::ops::*;
81    pub use crate::tensor::{
82        BoolElem, BoolTensor, Device, FloatElem, FloatTensor, IntElem, IntTensor, QuantizedTensor,
83    };
84}
85
86/// Tensor quantization module.
87pub mod quantization;
88
89#[cfg(feature = "api-std")]
90pub use report::*;
91
92#[cfg(feature = "api-std")]
93mod report;
94
95pub use ops::Device; // Re-export device so that it's available from `ruda_tensor::api::Device`.
96
97pub(crate) use check::macros::check;
98
99pub use crate::{
100    AllocationProperty, Bytes, DeviceSettings, StreamId, bf16, f16, get_device_settings, read_sync,
101    set_default_dtypes, try_read_sync,
102};