An advanced AI system that analyzes MP3 files and automatically generates guitar tablature in Guitar Pro format, with intelligent instrument separation and multi-track output.
- Audio Analysis: Advanced audio processing using librosa and essentia
- Instrument Separation: ML-powered source separation for multi-instrument tracks
- Pitch Detection: High-accuracy pitch and note detection algorithms
- Rhythm Analysis: Automatic tempo and rhythm pattern recognition
- Multi-Track Output: Separate tablature tracks for each identified instrument
- Guitar Pro Format: Native support for .gp5/.gpx file generation
- Custom Model Training: Infrastructure for training on your own Guitar Pro + audio datasets
AutoTablature/
├── src/
│ ├── audio/ # Audio processing and analysis
│ ├── models/ # ML models and training
│ ├── separation/ # Instrument separation
│ ├── tablature/ # Tablature generation
│ └── utils/ # Utility functions
├── data/ # Training data and datasets
├── models/ # Trained model files
├── notebooks/ # Jupyter notebooks for experimentation
└── tests/ # Unit tests
-
Install Dependencies:
pip install -r requirements.txt
-
Basic Usage:
from src.autotablature import AutoTablature # Initialize the system at = AutoTablature() # Process an MP3 file tablature = at.process_audio("path/to/song.mp3") # Save as Guitar Pro format tablature.save("output.gp5")
-
Command Line Usage:
# Process an audio file and generate tablature python examples/audio_to_tab.py --input song.mp3 --output tablature.gp5 --title "My Song" --artist "My Band"
-
Data Collection and Training:
# Collect data from Guitar Pro and audio files python -m src.utils.data_collector --gp-dir path/to/gp/files --audio-dir path/to/audio/files --output data --all # Train custom models python -m src.autotablature train_custom_model --data-path data/training --model-type all
- Audio to Tablature Demo: Complete pipeline demonstration
- Audio Analysis Training: Model training and evaluation
- Train Custom Model:
from src.models.trainer import ModelTrainer trainer = ModelTrainer() trainer.train_from_dataset("data/training/")
The system supports training on your own datasets:
- Guitar Pro Files: Place .gp5/.gpx files in
data/guitar_pro/
- Audio Files: Corresponding audio files in
data/audio/
- Automatic Matching: Built-in tools to match GP files with Spotify/YouTube audio
The AutoTablature system includes several AI models that can be trained on your own datasets for improved accuracy and customization to specific musical styles.
Use the quick start script to get training set up quickly:
# Check system requirements
python quick_start_training.py --check-only
# Basic training setup
python quick_start_training.py --data-dir data
# Training with custom data
python quick_start_training.py \
--data-dir data \
--gp-dir /path/to/guitar_pro_files \
--audio-dir /path/to/audio_files \
--model-type all \
--epochs 100
The system includes three main model types:
- Instrument Separation Model: Separates guitar tracks from mixed audio
- Pitch Detection Model: Identifies individual notes and timing
- Rhythm Analysis Model: Detects tempo and rhythmic patterns
# Collect and organize training data
python -m src.utils.data_collector --all \
--output data \
--gp-dir path/to/guitar_pro_files \
--audio-dir path/to/audio_files
# Train all models
python examples/train_models.py \
--data-path data/training \
--model-type all \
--epochs 100
# Train specific model
python examples/train_models.py \
--data-path data/training \
--model-type pitch \
--epochs 150 \
--batch-size 64
- GPU: CUDA-compatible GPU recommended (8GB+ VRAM)
- RAM: 16GB+ for processing large audio files
- Storage: 100GB+ for training data and models
- Data: Paired Guitar Pro files and corresponding audio recordings
For detailed training instructions, see MODEL_TRAINING_GUIDE.md.
- Guitar Pro (.gp5, .gpx): Native Guitar Pro format support
- AlphaTab Integration: Web-based tablature display
- MIDI Export: Standard MIDI file output
- JSON Format: Structured data for custom applications
- Python 3.8+
- CUDA-compatible GPU (recommended for model training)
- 8GB+ RAM for audio processing
- FFmpeg for audio format support
MIT License - See LICENSE file for details.
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Submit a pull request
- Real-time audio processing
- Bass and drum tablature support
- Advanced chord recognition
- Integration with popular DAWs
- Mobile app development
This project includes a DevContainer configuration for Visual Studio Code, which provides a consistent development environment with all dependencies pre-installed.
-
Clone the repository:
git clone https://github.com/your-username/AutoTablature.git cd AutoTablature
-
Open in VS Code:
code .
-
Launch DevContainer: When VS Code opens, it will detect the DevContainer configuration. Click on "Reopen in Container" in the notification or press F1 and select "Remote-Containers: Reopen in Container".
-
Wait for Container Setup: The first build may take several minutes as it installs all dependencies. Subsequent loads will be much faster.
-
Start Developing: Once the container is ready, you can run tasks, launch Jupyter notebooks, and develop as normal.
- Python 3.11 with all dependencies installed
- GPU support (if available on the host)
- Jupyter notebook server
- Pre-configured VS Code settings and extensions
- Persistent volumes for data and models
If you encounter issues with the DevContainer:
-
Package Installation Failures: Some advanced ML packages (like
tensorflow
oressentia
) may fail to install. The container is configured to continue with basic functionality. -
Guitar Pro Support: If
PyGuitarPro
package installation fails, the system will fall back to JSON output format. -
Building Issues:
- Try rebuilding the container:
Ctrl+Shift+P
→ "Remote-Containers: Rebuild Container" - Clear Docker cache:
docker system prune
- Check Docker Desktop has enough resources allocated
- Try rebuilding the container:
-
Testing Installation: Run
python test_environment.py
inside the container to verify what packages are available.