pub struct ModelComponent {
pub variant: ModelVariant,
pub kernel_dispatch: KernelDispatchConfig,
pub compilation_mode: CompilationMode,
pub profile_key: u64,
pub quant: Option<QuantScheme>,
pub layer_composition_key: u64,
}Expand description
Full specialization + binding bundle (Slang shader-component analogue).
Fields§
§variant: ModelVariant§kernel_dispatch: KernelDispatchConfig§compilation_mode: CompilationMode§profile_key: u64Hash of tier-1 [CompileProfile] or arch preset (see rlx-flow presets).
quant: Option<QuantScheme>Optional quant scheme affecting lowers and weight layout.
layer_composition_key: u64Composite layer-stack fingerprint (homogeneous depth, pair nesting).
Implementations§
Source§impl ModelComponent
impl ModelComponent
pub fn new(variant: ModelVariant) -> ModelComponent
pub fn with_kernel_dispatch( self, config: KernelDispatchConfig, ) -> ModelComponent
pub fn with_compilation_mode(self, mode: CompilationMode) -> ModelComponent
pub fn with_profile_key(self, key: u64) -> ModelComponent
pub fn with_quant(self, scheme: QuantScheme) -> ModelComponent
pub fn with_layer_composition_key(self, key: u64) -> ModelComponent
Sourcepub fn cache_key(&self) -> u64
pub fn cache_key(&self) -> u64
Stable key for compile caches (variant + dispatch + profile + composition).
pub fn dim_binding(&self) -> DimBinding
Sourcepub fn aot_disk_base(&self) -> String
pub fn aot_disk_base(&self) -> String
Stable on-disk prefix for [rlx_runtime::AotCache] ({base}__{binding_hash} per variant).
Trait Implementations§
Source§impl Clone for ModelComponent
impl Clone for ModelComponent
Source§fn clone(&self) -> ModelComponent
fn clone(&self) -> ModelComponent
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ModelComponent
impl RefUnwindSafe for ModelComponent
impl Send for ModelComponent
impl Sync for ModelComponent
impl Unpin for ModelComponent
impl UnsafeUnpin for ModelComponent
impl UnwindSafe for ModelComponent
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more