Expand description
This prelude is meant for code extending tract (like implementing new ops).
Re-exports§
pub use crate::axes::AxesMapping;
pub use crate::axes::Axis;
pub use crate::ops::element_wise::ElementWiseMiniOp;
pub use crate::ops::Cost;
pub use crate::ops::EvalOp;
pub use crate::ops::FrozenOpState;
pub use crate::ops::Op;
pub use crate::ops::OpState;
pub use crate::ops::Validation;
pub use crate::plan::SessionState;
pub use crate::plan::SessionStateHandler;
pub use crate::runtime::DefaultRuntime;
pub use crate::runtime::Runnable;
pub use crate::runtime::Runtime;
pub use crate::runtime::State;
pub use downcast_rs as tract_downcast_rs;
pub use crate::model::*;
pub use crate::ops::change_axes::*;
pub use crate::prelude::*;
Modules§
- num_
integer - Integer trait and functions.
- tract_
itertools - Extra iterator adaptors, functions and macros.
- tract_
ndarray - The
ndarray
crate provides an n-dimensional container for general elements and for numerics. - tract_
num_ traits - Numeric traits for generic mathematics
- tract_
smallvec - Small vectors in various sizes. These store a certain number of elements inline, and fall back to the heap for larger allocations. This can be a useful optimization for improving cache locality and reducing allocator traffic for workloads that fit within the inline buffer.
Macros§
- anyhow
- Construct an ad-hoc error from a string or existing non-
anyhow
error value. - args_1
- args_2
- args_3
- args_4
- args_5
- args_6
- args_7
- args_8
- as_op
- bail
- Return early with an error.
- bin_
to_ super_ type - dims
- dispatch_
copy - dispatch_
copy_ by_ size - dispatch_
datum - dispatch_
datum_ by_ size - dispatch_
floatlike - dispatch_
hash - dispatch_
numbers - dispatch_
signed - element_
wise - element_
wise_ oop - ensure
- Return early with an error if a condition is not satisfied.
- format_
err - Construct an ad-hoc error from a string or existing non-
anyhow
error value. - impl_
op_ same_ as - not_
a_ typed_ op - op_
as_ typed_ op - tvec
Structs§
- Blob
- HashMap
- A hash map implemented with quadratic probing and SIMD lookup.
- Opaque
- Phantom
Data - Zero-sized type used to mark things that “act like” they own a
T
. - Symbol
- Symbol
Scope - Symbol
Values - Tensor
- Tensor is a concrete tensor in tract.
- Tensor
View - f16
- A 16-bit floating point type implementing the IEEE 754-2008 standard
binary16
a.k.a “half” format.
Enums§
- Approximation
- Cow
- A clone-on-write smart pointer.
- Datum
Type - Geometry
Bound - QParams
- TDim
Traits§
- Clamp
Cast - Datum
- DimLike
- A super-trait for value acting as tensor dimensions in tract.
- Hash
- A hashable type.
- Into
ArcTensor - Convenient conversion to Arc
. - Into
Tensor - Convenient conversion to Tensor.
- Opaque
Fact - Opaque
Payload - Resolve
To - ToDim
- Convenience trait to convert values to TDim.
- Tract
Error Context - Provides the
context
method forResult
.
Functions§
- arr4
- natural_
strides - parse_
tdim - rctensor0
- rctensor1
- rctensor2
- rctensor3
- rctensor4
- round_
ties_ to_ even - solve_
for - tensor0
- tensor1
- tensor2
- tensor3
- tensor4
- vector_
size
Type Aliases§
- Static
Name - TVec
- A Smallvec instantiation with 4 embeddable values.
- Tract
Error - Tract
Result
Derive Macros§
- Hash
- Derive macro generating an impl of the trait
Hash
.