Downloads · 30 days
0
lucasnewman/descript-audio-codec-44khz
descript-audio-codec-44khz is a machine learning model from lucasnewman. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for mlx. The card lists the license as mit.
This model is reshaped for MLX from the original weights and is designed for use with descript-mlx
Downloads · 30 days
0
Access
Public
Updated Oct 28, 2024
Parameters
76.7M
920 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors307 MB · 100%
From the Hugging Face model README
This model is reshaped for MLX from the original weights and is designed for use with descript-mlx
pip install descript-mlx
You can load a pretrained model from Python like this:
import mlx.core as mx
from descript_mlx import DAC
dac = DAC.from_pretrained("44khz")
audio = mx.array(...)
# encode into latents and codes
z, codes, latents, commitment_loss, codebook_loss = dac.encode(audio)
# reconstruct from latents/codes to audio
reconstucted_audio = dac.decode(z)
# compress audio to a DAC file
dac_file = dac.compress(audio)
dac_file.save("/path/to/file.dac")
# decompress audio from a DAC file
reconstructed_audio = dac.decompress("/path/to/file.dac")