564 MB
942 files
Updated 27 days ago
Ctrl+K
| Name | Size | Uploaded | Xet hash |
|---|---|---|---|
| .claude | 7 items | ||
| .github | 1 items | ||
| data | 1 items | ||
| examples | 1 items | ||
| mlflow | 2 items | ||
| notebooks | 3 items | ||
| src | 9 items | ||
| templates | 1 items | ||
| tests | 4 items | ||
| CLAUDE.md | 2.1 kB xet | 9202be88 | |
| FinalProjectDescription-FinalVersion.pdf | 249 kB xet | 25ab548e | |
| README.md | 2.12 kB xet | 883e2ef5 | |
| desc.md | 4.78 kB xet | f8080a25 | |
| requirements.txt | 176 Bytes xet | fa4eead0 | |
| run_pipeline.py | 2.42 kB xet | c134ede1 |
Traditional Persian Music — Classification & Clustering
This repository contains an end-to-end skeleton for the course project "Traditional Persian Music Classification and Clustering".
Structure
data/— place your raw.mp3files here, organized asinstrument_dastgah/filename.mp3or similar.src/— Python modules for preprocessing, feature extraction, modeling, and clustering.run_pipeline.py— example script to extract features and train baseline models.requirements.txt— Python dependencies.notebooks/— (empty) place for EDA and report notebooks.
Quickstart
- Create a virtual environment and install dependencies:
python -m venv .venv && . .venv/bin/activate && pip install -r requirements.txt(If you need plotting / keras:pip install seaborn tensorflow) - Put your
.mp3files underdata/(one folder per Dastgah, see project spec). - Extract features and create
features.csv:python run_pipeline.py --input_dir data --out_csv features.csv - Train baseline models (from extracted features):
python run_pipeline.py --input_dir data --out_csv features.csv --train
Example: full pipeline with model saving
- Run the end-to-end example (extract features, train models, clustering, save artifacts):
python examples/full_pipeline.py --data_dir data --save_models_dir models - Perform inference on a single file using the helper:
from src.inference import predict_file label, details = predict_file("data/shur/song1.mp3", "models") print(label, details)
MLflow (optional)
- To track experiments with MLflow, install
mlflowand call tracking functions:from src.mlflow_tracking import log_classic_experiment, log_lstm_history log_classic_experiment("svm_experiment", params={"C":1.0}, metrics={"f1":0.78}, artifacts_dir="experiments") - Start the MLflow UI locally:
mlflow ui --port 5000
Notes
- Follow the course specification: each student collects 35 pieces (5 per Dastgah).
- See
src/for functions and examples to customize feature extraction and modeling.
- Total size
- 564 MB
- Files
- 942
- Last updated
- Sep 12
- Pre-warmed CDN
- US EU US EU