pub struct Mamba3DoubleSsdCachesConfig {
pub n_real_caches: usize,
pub cache: Mamba3DoubleSsdCacheConfig,
}Expand description
Configuration / factory for Mamba3DoubleSsdCaches.
Fields§
§n_real_caches: usizeNumber of cache slots (= number of virtual layers).
cache: Mamba3DoubleSsdCacheConfigShared configuration that determines the shape of each cache.
Implementations§
Source§impl Mamba3DoubleSsdCachesConfig
impl Mamba3DoubleSsdCachesConfig
Sourcepub fn new_from_block_config(
n_real_caches: usize,
batch: usize,
block_config: Mamba3Config,
) -> Self
pub fn new_from_block_config( n_real_caches: usize, batch: usize, block_config: Mamba3Config, ) -> Self
Convenience constructor from a block config.
Sourcepub fn init(&self, device: &Device) -> Mamba3DoubleSsdCaches
pub fn init(&self, device: &Device) -> Mamba3DoubleSsdCaches
Allocate all cache tensors (zero-initialised) on device.
Trait Implementations§
Source§impl Clone for Mamba3DoubleSsdCachesConfig
impl Clone for Mamba3DoubleSsdCachesConfig
Source§impl Config for Mamba3DoubleSsdCachesConfig
impl Config for Mamba3DoubleSsdCachesConfig
§fn load_binary(data: &[u8]) -> Result<Self, ConfigError>
fn load_binary(data: &[u8]) -> Result<Self, ConfigError>
Loads the configuration from a binary buffer. Read more
Source§impl Debug for Mamba3DoubleSsdCachesConfig
impl Debug for Mamba3DoubleSsdCachesConfig
Source§impl<'de> Deserialize<'de> for Mamba3DoubleSsdCachesConfig
impl<'de> Deserialize<'de> for Mamba3DoubleSsdCachesConfig
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Mamba3DoubleSsdCachesConfig
impl RefUnwindSafe for Mamba3DoubleSsdCachesConfig
impl Send for Mamba3DoubleSsdCachesConfig
impl Sync for Mamba3DoubleSsdCachesConfig
impl Unpin for Mamba3DoubleSsdCachesConfig
impl UnsafeUnpin for Mamba3DoubleSsdCachesConfig
impl UnwindSafe for Mamba3DoubleSsdCachesConfig
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