Buckets:
AutoencoderOobleck
The Oobleck variational autoencoder (VAE) model with KL loss was introduced in Stability-AI/stable-audio-tools and Stable Audio Open by Stability AI. The model is used in 🤗 Diffusers to encode audio waveforms into latents and to decode latent representations into audio waveforms.
The abstract from the paper is:
Open generative models are vitally important for the community, allowing for fine-tunes and serving as baselines when presenting new models. However, most current text-to-audio models are private and not accessible for artists and researchers to build upon. Here we describe the architecture and training process of a new open-weights text-to-audio model trained with Creative Commons data. Our evaluation shows that the model's performance is competitive with the state-of-the-art across various metrics. Notably, the reported FDopenl3 results (measuring the realism of the generations) showcase its potential for high-quality stereo sound synthesis at 44.1kHz.
AutoencoderOobleck[[diffusers.AutoencoderOobleck]]
- encoder_hidden_size (
int, optional, defaults to 128) -- Intermediate representation dimension for the encoder. - downsampling_ratios (
list[int], optional, defaults to[2, 4, 4, 8, 8]) -- Ratios for downsampling in the encoder. These are used in reverse order for upsampling in the decoder. - channel_multiples (
list[int], optional, defaults to[1, 2, 4, 8, 16]) -- Multiples used to determine the hidden sizes of the hidden layers. - decoder_channels (
int, optional, defaults to 128) -- Intermediate representation dimension for the decoder. - decoder_input_channels (
int, optional, defaults to 64) -- Input dimension for the decoder. Corresponds to the latent dimension. - audio_channels (
int, optional, defaults to 2) -- Number of channels in the audio data. Either 1 for mono or 2 for stereo. - sampling_rate (
int, optional, defaults to 44100) -- The sampling rate at which the audio waveform should be digitalized expressed in hertz (Hz).
An autoencoder for encoding waveforms into latents and decoding latent representations into waveforms. First introduced in Stable Audio.
This model inherits from ModelMixin. Check the superclass documentation for it's generic methods implemented for all models (such as downloading or saving).
- z (
torch.Tensor) -- Input batch of latent vectors. - return_dict (
bool, optional, defaults toTrue) -- Whether to return a~models.vae.OobleckDecoderOutputinstead of a plain tuple.~models.vae.OobleckDecoderOutputortupleIf return_dict is True, a~models.vae.OobleckDecoderOutputis returned, otherwise a plaintupleis returned.
Decode a batch of images.
- x (
torch.Tensor) -- Input batch of images. - return_dict (
bool, optional, defaults toTrue) -- Whether to return a~models.autoencoder_kl.AutoencoderKLOutputinstead of a plain tuple.The latent representations of the encoded images. Ifreturn_dictis True, a~models.autoencoder_kl.AutoencoderKLOutputis returned, otherwise a plaintupleis returned.
Encode a batch of images into latents.
- sample (
torch.Tensor) -- Input sample. - sample_posterior (
bool, optional, defaults toFalse) -- Whether to sample from the posterior. - return_dict (
bool, optional, defaults toTrue) -- Whether or not to return aOobleckDecoderOutputinstead of a plain tuple. - generator (
torch.Generator, optional) -- Atorch.Generatorto make sampling deterministic.~models.vae.OobleckDecoderOutputortupleIfreturn_dictis True, a~models.vae.OobleckDecoderOutputis returned, otherwise a plaintupleis returned.
OobleckDecoderOutput[[diffusers.models.autoencoders.autoencoder_oobleck.OobleckDecoderOutput]]
- sample (
torch.Tensorof shape(batch_size, audio_channels, sequence_length)) -- The decoded output sample from the last layer of the model.
Output of decoding method.
AutoencoderOobleckOutput[[diffusers.models.autoencoders.autoencoder_oobleck.AutoencoderOobleckOutput]]
- latent_dist (
OobleckDiagonalGaussianDistribution) -- Encoded outputs ofEncoderrepresented as the mean and standard deviation ofOobleckDiagonalGaussianDistribution.OobleckDiagonalGaussianDistributionallows for sampling latents from the distribution.
Output of AutoencoderOobleck encoding method.
Xet Storage Details
- Size:
- 4.69 kB
- Xet hash:
- d9a8771d2ae2c723b326e0b1a5c612ff20c760fa5c84dae7369ef4a662e07f65
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.