pub struct SnacConfig {
pub sampling_rate: u32,
pub encoder_dim: usize,
pub encoder_rates: Vec<usize>,
pub decoder_dim: usize,
pub decoder_rates: Vec<usize>,
pub attn_window_size: Option<usize>,
pub codebook_size: usize,
pub codebook_dim: usize,
pub vq_strides: Vec<usize>,
pub noise: bool,
pub depthwise: bool,
pub latent_dim: Option<usize>,
}Expand description
SNAC model hyper-parameters (hubertsiuzdak/snac_24khz).
Fields§
§sampling_rate: u32§encoder_dim: usize§encoder_rates: Vec<usize>§decoder_dim: usize§decoder_rates: Vec<usize>§attn_window_size: Option<usize>§codebook_size: usize§codebook_dim: usize§vq_strides: Vec<usize>§noise: bool§depthwise: bool§latent_dim: Option<usize>Implementations§
Source§impl SnacConfig
impl SnacConfig
Sourcepub fn latent_dim(&self) -> usize
pub fn latent_dim(&self) -> usize
Latent channel width — explicit in export JSON or derived from encoder stack.
pub fn n_codebooks(&self) -> usize
Trait Implementations§
Source§impl Clone for SnacConfig
impl Clone for SnacConfig
Source§fn clone(&self) -> SnacConfig
fn clone(&self) -> SnacConfig
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 moreSource§impl Debug for SnacConfig
impl Debug for SnacConfig
Source§impl<'de> Deserialize<'de> for SnacConfig
impl<'de> Deserialize<'de> for SnacConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<SnacConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<SnacConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for SnacConfig
impl RefUnwindSafe for SnacConfig
impl Send for SnacConfig
impl Sync for SnacConfig
impl Unpin for SnacConfig
impl UnsafeUnpin for SnacConfig
impl UnwindSafe for SnacConfig
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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