pub struct GpuMimiCodec { /* private fields */ }Implementations§
Source§impl GpuMimiCodec
impl GpuMimiCodec
pub fn open_weights( weights: &Path, cfg: MimiConfig, num_codebooks: usize, device: Device, ) -> Result<GpuMimiCodec, Error>
pub fn config(&self) -> &MimiConfig
pub fn candle_device(&self) -> &Device
pub fn encode_pcm( &mut self, pcm: &[f32], num_quantizers: Option<usize>, ) -> Result<MimiCodes, Error>
pub fn decode_codes(&mut self, codes: &MimiCodes) -> Result<Vec<f32>, Error>
Auto Trait Implementations§
impl !RefUnwindSafe for GpuMimiCodec
impl !UnwindSafe for GpuMimiCodec
impl Freeze for GpuMimiCodec
impl Send for GpuMimiCodec
impl Sync for GpuMimiCodec
impl Unpin for GpuMimiCodec
impl UnsafeUnpin for GpuMimiCodec
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
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