pub enum KernelMatch {
Supported {
cost: Cost,
required_input_layouts: Option<Vec<TensorLayout>>,
output_layouts: Vec<TensorLayout>,
},
Unsupported {
reason: Cow<'static, str>,
},
}Expand description
Result of crate::ExecutionProvider::supports_op.
A decline reason travels with the decision that produced it. EPs must not
maintain a separate reason table: colocating the reason with Unsupported
keeps diagnostics from drifting away from the actual claim predicate.
Variants§
Supported
Fields
§
required_input_layouts: Option<Vec<TensorLayout>>Layouts the kernel requires for each input, if constrained.
§
output_layouts: Vec<TensorLayout>Layouts the kernel produces for each output.
Unsupported
Implementations§
Source§impl KernelMatch
impl KernelMatch
Sourcepub fn unsupported(reason: impl Into<Cow<'static, str>>) -> Self
pub fn unsupported(reason: impl Into<Cow<'static, str>>) -> Self
Construct an unsupported match with its actionable decline reason.
Sourcepub fn is_supported(&self) -> bool
pub fn is_supported(&self) -> bool
Whether the op is supported.
Auto Trait Implementations§
impl Freeze for KernelMatch
impl RefUnwindSafe for KernelMatch
impl Send for KernelMatch
impl Sync for KernelMatch
impl Unpin for KernelMatch
impl UnsafeUnpin for KernelMatch
impl UnwindSafe for KernelMatch
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more