Wiki-Quellcode von Audiocraft Plus Soundeffects
Zuletzt geändert von René Schmidt am 2025/04/03 00:21
Zeige letzte Bearbeiter
| author | version | line-number | content |
|---|---|---|---|
| 1 | = AudioCraft Plus = | ||
| 2 | |||
| 3 | |||
| 4 | [[~[~[image:https://github.com/facebookresearch/audiocraft/workflows/audiocraft_docs/badge.svg~|~|alt="docs badge"~]~]>>url:https://github.com/facebookresearch/audiocraft/workflows/audiocraft_docs/badge.svg]] [[~[~[image:https://github.com/facebookresearch/audiocraft/workflows/audiocraft_linter/badge.svg~|~|alt="linter badge"~]~]>>url:https://github.com/facebookresearch/audiocraft/workflows/audiocraft_linter/badge.svg]] [[~[~[image:https://github.com/facebookresearch/audiocraft/workflows/audiocraft_tests/badge.svg~|~|alt="tests badge"~]~]>>url:https://github.com/facebookresearch/audiocraft/workflows/audiocraft_tests/badge.svg]] | ||
| 5 | |||
| 6 | AudioCraft is a PyTorch library for deep learning research on audio generation. AudioCraft contains inference and training code for two state-of-the-art AI generative models producing high-quality audio: AudioGen and MusicGen. | ||
| 7 | |||
| 8 | [[~[~[image:https://camo.githubusercontent.com/96889048f8a9014fdeba2a891f97150c6aac6e723f5190236b10215a97ed41f3/68747470733a2f2f636f6c61622e72657365617263682e676f6f676c652e636f6d2f6173736574732f636f6c61622d62616467652e737667~|~|alt="Open In Colab"~]~] >>url:https://colab.research.google.com/github/camenduru/MusicGen-colab/blob/main/MusicGen_ClownOfMadness_plus_colab.ipynb]][[~[~[image:https://camo.githubusercontent.com/8436d0dbd9d29c58bfece9bf36e6cbdc6b38db1280c5007cad21f16debf04f39/68747470733a2f2f68756767696e67666163652e636f2f64617461736574732f68756767696e67666163652f6261646765732f7261772f6d61696e2f6f70656e2d696e2d68662d7370616365732d736d2e737667~|~|alt="Open in HugginFace"~]~] >>url:https://huggingface.co/spaces/facebook/MusicGen]] | ||
| 9 | |||
| 10 | |||
| 11 | [[~[~[image:https://private-user-images.githubusercontent.com/52707645/262005171-043fc037-54a9-48c4-bb5c-bf9b7440d146.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3NDM2Mjc5NzgsIm5iZiI6MTc0MzYyNzY3OCwicGF0aCI6Ii81MjcwNzY0NS8yNjIwMDUxNzEtMDQzZmMwMzctNTRhOS00OGM0LWJiNWMtYmY5Yjc0NDBkMTQ2LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTA0MDIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwNDAyVDIxMDExOFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTQ0ZTIyOTJkN2RiNTAyZTkzOTRlZGRkZTlkOGM2OTc5ODZlODZjZjhkNjM2ODQ0MzJmZGE0OTM2ZDgyNDE5YWUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.B0CaQAdeqzKGnrTqpzlp-HynG8FCndhlBmUhoMJmdNk~|~|alt="image"~]~]>>url:https://private-user-images.githubusercontent.com/52707645/262005171-043fc037-54a9-48c4-bb5c-bf9b7440d146.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3NDM2Mjc5NzgsIm5iZiI6MTc0MzYyNzY3OCwicGF0aCI6Ii81MjcwNzY0NS8yNjIwMDUxNzEtMDQzZmMwMzctNTRhOS00OGM0LWJiNWMtYmY5Yjc0NDBkMTQ2LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTA0MDIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwNDAyVDIxMDExOFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTQ0ZTIyOTJkN2RiNTAyZTkzOTRlZGRkZTlkOGM2OTc5ODZlODZjZjhkNjM2ODQ0MzJmZGE0OTM2ZDgyNDE5YWUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.B0CaQAdeqzKGnrTqpzlp-HynG8FCndhlBmUhoMJmdNk]] | ||
| 12 | |||
| 13 | == Features == | ||
| 14 | |||
| 15 | |||
| 16 | AudioCraft Plus is an all-in-one WebUI for the original AudioCraft, adding many quality features on top. | ||
| 17 | |||
| 18 | * AudioGen Model | ||
| 19 | * Multiband Diffusion | ||
| 20 | * Custom Model Support | ||
| 21 | * Generation Metadata and Audio Info tab | ||
| 22 | * Mono to Stereo | ||
| 23 | * Multiprompt/Prompt Segmentation with Structure Prompts | ||
| 24 | * Video Output Customization | ||
| 25 | * Music Continuation | ||
| 26 | |||
| 27 | == Installation == | ||
| 28 | |||
| 29 | |||
| 30 | If you are updating from the previous version of AudioCraft Plus, do the following steps in the AudioCraft Plus folder: | ||
| 31 | |||
| 32 | {{{git pull | ||
| 33 | pip install transformers --upgrade | ||
| 34 | pip install torchmetrics --upgrade}}} | ||
| 35 | |||
| 36 | ==== Otherwise: Clean Installation ==== | ||
| 37 | |||
| 38 | |||
| 39 | AudioCraft requires Python 3.9, PyTorch 2.0.0. To install AudioCraft, you can run the following: | ||
| 40 | |||
| 41 | {{{# Best to make sure you have torch installed first, in particular before installing xformers. | ||
| 42 | # Don't run this if you already have PyTorch installed. | ||
| 43 | pip install 'torch>=2.0' | ||
| 44 | # Then proceed to one of the following | ||
| 45 | pip install -U audiocraft # stable release | ||
| 46 | pip install -U git+https://git@github.com/GrandaddyShmax/audiocraft_plus#egg=audiocraft # bleeding edge | ||
| 47 | pip install -e . # or if you cloned the repo locally (mandatory if you want to train).}}} | ||
| 48 | |||
| 49 | We also recommend having ffmpeg installed, either through your system or Anaconda: | ||
| 50 | |||
| 51 | {{{sudo apt-get install ffmpeg | ||
| 52 | # Or if you are using Anaconda or Miniconda | ||
| 53 | conda install 'ffmpeg<5' -c conda-forge}}} | ||
| 54 | |||
| 55 | Installation video thanks to Pogs Cafe: | ||
| 56 | [[~[~[image:https://camo.githubusercontent.com/c5016f10ef6646ee645337023b4e04376adccd63f10e9a9a580ca1a0c2f1ac6e/687474703a2f2f696d672e796f75747562652e636f6d2f76692f576a476b34626362554f492f302e6a7067~|~|alt="Untitled"~]~]>>url:http://www.youtube.com/watch?v=WjGk4bcbUOI]] | ||
| 57 | |||
| 58 | Additional installation guide by [[radaevm>>url:https://github.com/radaevm]] can be found [[HERE>>url:https://github.com/GrandaddyShmax/audiocraft_plus/discussions/31]] | ||
| 59 | |||
| 60 | == Models == | ||
| 61 | |||
| 62 | |||
| 63 | At the moment, AudioCraft contains the training code and inference code for: | ||
| 64 | |||
| 65 | * [[MusicGen>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/MUSICGEN.md]]: A state-of-the-art controllable text-to-music model. | ||
| 66 | * [[AudioGen>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/AUDIOGEN.md]]: A state-of-the-art text-to-sound model. | ||
| 67 | * [[EnCodec>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/ENCODEC.md]]: A state-of-the-art high fidelity neural audio codec. | ||
| 68 | * [[Multi Band Diffusion>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/MBD.md]]: An EnCodec compatible decoder using diffusion. | ||
| 69 | |||
| 70 | == Training code == | ||
| 71 | |||
| 72 | |||
| 73 | AudioCraft contains PyTorch components for deep learning research in audio and training pipelines for the developed models. For a general introduction of AudioCraft design principles and instructions to develop your own training pipeline, refer to the [[AudioCraft training documentation>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/TRAINING.md]]. | ||
| 74 | |||
| 75 | For reproducing existing work and using the developed training pipelines, refer to the instructions for each specific model that provides pointers to configuration, example grids and model/task-specific information and FAQ. | ||
| 76 | |||
| 77 | == API documentation == | ||
| 78 | |||
| 79 | |||
| 80 | We provide some [[API documentation>>url:https://facebookresearch.github.io/audiocraft/api_docs/audiocraft/index.html]] for AudioCraft. | ||
| 81 | |||
| 82 | == FAQ == | ||
| 83 | |||
| 84 | |||
| 85 | ==== Is the training code available? ==== | ||
| 86 | |||
| 87 | |||
| 88 | Yes! We provide the training code for [[EnCodec>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/ENCODEC.md]], [[MusicGen>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/MUSICGEN.md]] and [[Multi Band Diffusion>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/docs/MBD.md]]. | ||
| 89 | |||
| 90 | ==== Where are the models stored? ==== | ||
| 91 | |||
| 92 | |||
| 93 | Hugging Face stored the model in a specific location, which can be overriden by setting the AUDIOCRAFT_CACHE_DIR environment variable. | ||
| 94 | |||
| 95 | == License == | ||
| 96 | |||
| 97 | |||
| 98 | * The code in this repository is released under the MIT license as found in the [[LICENSE file>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/LICENSE]]. | ||
| 99 | * The models weights in this repository are released under the CC-BY-NC 4.0 license as found in the [[LICENSE_weights file>>url:https://github.com/GrandaddyShmax/audiocraft_plus/blob/main/LICENSE_weights]]. |