pub struct Codec { /* private fields */ }Expand description
The VibeVoice acoustic codec.
Implementations§
Source§impl Codec
impl Codec
pub fn from_model( model: &CmfModel, c: &HaruConfig, pool: Option<Arc<Pool>>, ) -> Result<Self, String>
Sourcepub fn encode(&self, audio: &[f32]) -> Vec<f32>
pub fn encode(&self, audio: &[f32]) -> Vec<f32>
Latent means [ceil(len / 3200)][64] of a whole clip.
Sourcepub fn decode(&self, latents: &[f32]) -> Vec<f32>
pub fn decode(&self, latents: &[f32]) -> Vec<f32>
The waveform of latents [t][64] (raw codec space), 3200 samples a latent.
Auto Trait Implementations§
impl !RefUnwindSafe for Codec
impl !UnwindSafe for Codec
impl Forget for Codec
impl Freeze for Codec
impl Move for Codec
impl Send for Codec
impl Sync for Codec
impl Unpin for Codec
impl UnsafeUnpin for Codec
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