transformers
c43b380e
- Add MusicGen Melody (#28819)
Go
Login via GitHub
Home
Pricing
FAQ
Install
Login
via GitHub
Commit
View On
GitHub
Hide Minimap (CTRL+M)
Commit
1 year ago
Add MusicGen Melody (#28819) * first modeling code * make repository * still WIP * update model * add tests * add latest change * clean docstrings and copied from * update docstrings md and readme * correct chroma function * correct copied from and remove unreleated test * add doc to toctree * correct imports * add convert script to notdoctested * Add suggestion from Sanchit Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com> * correct get_uncoditional_inputs docstrings * modify README according to SANCHIT feedback * add chroma to audio utils * clean librosa and torchaudio hard dependencies * fix FE * refactor audio decoder -> audio encoder for consistency with previous musicgen * refactor conditional -> encoder * modify sampling rate logics * modify license at the beginning * refactor all_self_attns->all_attentions * remove ignore copy from causallm generate * add copied from for from_sub_models * fix make copies * add warning if audio is truncated * add copied from where relevant * remove artefact * fix convert script * fix torchaudio and FE * modify chroma method according to feedback-> better naming * refactor input_values->input_features * refactor input_values->input_features and fix import fe * add input_features to docstrigs * correct inputs_embeds logics * remove dtype conversion * refactor _prepare_conditional_hidden_states_kwargs_for_generation ->_prepare_encoder_hidden_states_kwargs_for_generation * change warning for chroma length * Update src/transformers/models/musicgen_melody/convert_musicgen_melody_transformers.py Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com> * change way to save wav, using soundfile * correct docs and change to soundfile * fix import * fix init proj layers * remove line breaks from md * fix issue with docstrings * add FE suggestions * improve is in logics and remove useless imports * remove custom from_pretrained * simplify docstring code * add suggestions for modeling tests * make style * update converting script with sanity check * remove encoder attention mask from conditional generation * replace musicgen melody checkpoints with official orga * rename ylacombe->facebook in checkpoints * fix copies * remove unecessary warning * add shape in code docstrings * add files to slow doc tests * fix md bug and add md to not_tested * make fix-copies * fix hidden states test and batching --------- Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com>
References
#32831 - [Docs] Update resources
#29969 - [SigLIP] Add fast tokenizer
#38622 - [AutoModelForMaskGeneration] Remove duplicate code
#33111 - [Backbone] Remove out_features everywhere
#33174 - [Zero-shot image classification pipeline] Remove tokenizer_kwargs
#28819 - Add MusicGen Melody
Author
ylacombe
Parents
bf3dfd11
Files
40
README.md
README_de.md
README_es.md
README_fr.md
README_hd.md
README_ja.md
README_ko.md
README_pt-br.md
README_ru.md
README_te.md
README_vi.md
README_zh-hans.md
README_zh-hant.md
docs/source/en
_toctree.yml
index.md
model_doc
musicgen_melody.md
tasks
language_modeling.md
src/transformers
__init__.py
audio_utils.py
models
__init__.py
auto
configuration_auto.py
modeling_auto.py
tokenization_auto.py
musicgen_melody
__init__.py
configuration_musicgen_melody.py
convert_musicgen_melody_transformers.py
feature_extraction_musicgen_melody.py
modeling_musicgen_melody.py
processing_musicgen_melody.py
utils
dummy_pt_objects.py
dummy_torchaudio_objects.py
tests
models/musicgen_melody
__init__.py
test_feature_extraction_musicgen_melody.py
test_modeling_musicgen_melody.py
test_processor_musicgen_melody.py
utils
test_audio_utils.py
utils
check_docstrings.py
check_repo.py
not_doctested.txt
slow_documentation_tests.txt
Loading