• Stars
    star
    237
  • Rank 169,885 (Top 4 %)
  • Language
    Python
  • License
    MIT License
  • Created over 6 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Singing synthesis from MIDI file

Singing Synthesis from MIDI file

This script relies on the sinsy.jp website from the Nagoya Institute of Technology which implements a HMM-based Singing Voice Synthesis System.

You can find a sample merged with the instrumental audio here.

Requirements

  • musescore: It's used to convert midi to musicxml
  • python 3

Installation

pip install git+git://github.com/mathigatti/midi2voice.git

Usage

You can use it running the installed module using python -m midi2voice. It has serveral parameters, most are optional and you need to use them only if you want to specify something different than the default

python -m midi2voice
  -h, --help # show this help message and exit
  -l LYRICS, --lyrics LYRICS # Path to txt file containing the lyrics
  -m MIDI, --midi MIDI # Path to midi file
  -lang {english,japanese,mandarin} # Language of the voice (OPTIONAL / DEFAULT: english)
  -g {female,male} # Gender voice (female/male) (OPTIONAL / DEFAULT: female)
  -i VOICEINDEX # Each language has different voices, for example japanese has 4 different female voices at the moment, mandarin only one. (OPTIONAL / DEFAULT: 0)
  -t TEMPO # Song tempo in BPMs (OPTIONAL / DEFAULT 80)
  -s SYNALPHA # Gender parameter [between -0.8 and 0.8, default: 0.55]
  -v VIBPOWER # Vibrato intensity [between 0 and 2, default: 1]
  -p F0SHIFT # Pitch shift [in half tones, between -24 and 24, default: 0]
  -d DESTINATION_FOLDER # Destination folder

Usage example

Check the midi and text samples here.

# Print help
python3 -m midi2voice -h

# Basic example
python -m midi2voice -l shallow.txt -m shallow.mid

# Generate the voice given a midi file and a text file with the lyrics
python -m midi2voice -l shallow.txt -m shallow.mid -lang english -g female -t 96

Try it on Colab

If you don't have python installed or you just want to check it quickly you can try it online here.

Open In Colab

Voices available

At the moment sinsy.jp provides this voices. You can use the VOICEINDEX parameter to choose them.

  • Japanese

    • Female

      • 0 - f00001j_dnn_beta4 : Yoko : Japanese
      • 1 - f00002j_dnn_beta4 : Xiang-Ling : Japanese
      • 2 - f01018j_dnn_beta4 : undefined : Japanese
      • 3 - f00001j : Yoko : Japanese
      • 4 - f00002j : Xiang-Ling : Japanese
      • 5 - f00004j_beta : Namine Ritsu S : Japanese
      • 6 - f00005j : undefined : Japanese
    • Male

      • 0 - m01083j_dnn_beta4 : undefined : Japanese
      • 1 - m01083j : undefined : Japanese
  • English

    • Female

      • 0 - f00002e_dnn_beta4 : Xiang-Ling : English
      • 1 - f00002e : Xiang-Ling : English
    • Male

      • 0 - m00003e_beta : Matsuo-P : English
  • Mandarin

    • Female

      • 0 - f00002m : Xiang-Ling : Chinese (Mandarin)
    • Male

      • None at the moment

Credits

This source code was developed by Mathias Gatti (@mathigatti) if you use it please remember to cite me. For scientific publications you can use this DOI.

Gatti, M. (2020). mathigatti/midi2voice v1.0.0 (v1.0.0) [Computer software]. Zenodo. https://doi.org/10.5281/ZENODO.3969003

DOI

Support my work

If you want to help me to keep going developing and maintaining open-source projects you can contribute buying me some ko-fi.

License

MIT

More Repositories

1

midi2img

MIDI to image and image to MIDI conversion scripts
Python
58
star
2

sexting-dataset

Erotic conversations scraped from public resources on the internet
Shell
55
star
3

RealTimeSingingSynthesizer

Live Coding Singing Synthesizer. Python sinsy-NG wrapper.
C
54
star
4

img2txt

Easy formatted text extraction from images using Google Vision API
Python
36
star
5

ArtWithAICourse

Course about artificial intelligence applied to the arts. Available in spanish and english.
29
star
6

MusicVideoMaker

Automatically generate a music video by extracting scenes from another video
Python
25
star
7

MellotronCPU

Mellotron singing synthesizer using CPU
Python
14
star
8

CellularAutomataClustering

Cellular automata patterns are clustered based on features related to beauty such as fractal dimensionality and compression efficiency.
Jupyter Notebook
14
star
9

ArtificialWorldBuildingCourse

Learn what are the logic rules behind natural phenomena and how we can simulate and modify them using a computer
JavaScript
12
star
10

DeepSingingSynthesizer

Extension of Sinsy-NG using deep learning models for voice conversion in order to synthesize good and realistic vocals.
Python
11
star
11

ASMRDataset

Recordings and transcriptions of ASMR artists compiled for the purpose of training voice synthesizers
8
star
12

gestures2anything

Use your webcam to identify gestures and trigger any script
HTML
8
star
13

midi2foxdot

MIDI to FoxDot code conversion script
Python
6
star
14

okCupidScraper

Download okCupid users public data automatically
Jupyter Notebook
6
star
15

GesturesController

Basic flask web for triggering anything from python using hand gestures
HTML
5
star
16

PornHubPerCountry

Finding keywords used on video titles of different countries using TF-IDF
Jupyter Notebook
5
star
17

EmotionsInferenceWithMicrosoftBand

Physiological signals recorded with a Microsoft Band 2 are processed and modeled with a basic bayesian model to infer exaltation and relaxation states of mind
Jupyter Notebook
4
star
18

magenta-piano-duet-api

Rest API to interact with magenta RNN composer from ai-duet website
Python
4
star
19

EmotivClassifier

Scripts for prediction of individual characteristics based on brain connectome using Emotiv Epoch Data
Python
4
star
20

EmotivExperiments

Go-NoGo and Resting, cognitive experiments for Emotiv Epoch
Python
4
star
21

aysa-datos-meteorologicos

Datos diarios provenientes de las estaciones meteorológicas de aysa.
JavaScript
3
star
22

harmonizer

Real time microphone harmonizer inspired on Jacob Collier's keyboard
Python
3
star
23

sampleTuner

Change the pitch of a sample so it is tuned to the closest C note
Python
3
star
24

pop-lyrics-dataset

XX and XXI century pop artist lyrics
3
star
25

WeatherSensorStreamer

Website running on raspberry pi server, temperature and humidity sensors connected to the microcontroller record data which is then plotted in the frontend with Plotly and Flask python libraries
Python
3
star
26

mathigatti

Personal Website
EJS
2
star
27

SingingSynthesizer

Singing Synthesizer
C
2
star
28

dc_tts

A TensorFlow Implementation of DC-TTS: yet another text-to-speech model
Python
2
star
29

moreAbstractLiveCoding

Functions made on top of FoxDot to code cool live music more quickly and easily
Python
2
star
30

awesome-psiconautica

Repositorio de recursos para experimentar estados alterados de conciencia
HTML
2
star
31

gpt-2-chatbot

GPT-2 chatbot in spanish (and any other language using google translate)
HTML
2
star
32

julio-bot

Asistente virtual con la voz de Julio Cortazar
C++
1
star
33

algo3-tp1

TeX
1
star
34

basic-gpt-2-website

Sitio web hecho en flask para generar periodicamente textos nuevos en español con el modelo de red neuronal GPT-2
Python
1
star
35

audio-streaming

Audio streaming project
HTML
1
star
36

MELI-Escuelita

Some Projects made during MELI (Mercado Libre) introductory course
JavaScript
1
star
37

orga2-tp

Red Neuronal para reconocer dígitos númericos hecho con C y SIMD, realizado como trabajo final para la materia Organización del Computador 2
C
1
star
38

AdvancedCellularAutomatas

Compilation of cool cellular automatas implemented on WebGL and Javascript by different people
JavaScript
1
star