Skip to content

Commit

Permalink
Merge pull request #3 from spicytigermeat/v030
Browse files Browse the repository at this point in the history
v030
  • Loading branch information
spicytigermeat authored Apr 3, 2024
2 parents 94d51d9 + 83a2532 commit 98715d0
Show file tree
Hide file tree
Showing 43 changed files with 2,180 additions and 355 deletions.
Binary file added .github/labelmakr_sc.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 26 additions & 1 deletion CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,29 @@ v020
- French transcriptions automatically account for contractions (j' in j'taime)
- Implemented the tenatively named "OovG2P" into SOFA.
- this utilizes OpenUTAU's G2P model system to guess the pronunciation for words that are not in the given dictionaries.
- This is only applied to English and French, since Japanese has it's own weird G2p thing and Chinese... doesn't really need one.
- This is only applied to English and French, since Japanese has it's own weird G2p thing and Chinese... doesn't really need one.

v021
- Fixed a few scripts to allow for early CPU inference.

v030
- Huge update
- Support for colstone's Korean SOFA model!
- Korean GUI translation by 군곰 (KUNGOM)
- Lot's of small GUI tweaks/changes/addition
- Light/Dark mode toggle (Dark mode by default)
- cute little icons on the buttons, custom fonts for English/Japanese/Chinese/Korean
- Allows you to choose to install CPU or GPU version
- More code consistency
- Global implementation of Pathlib
- removed weird inconsistencies, like unused variables
- Implemented the logging module for slightly easier troubleshooting
- Implemented a python module I wrote called "ez-localizr", to make localization easy :)
- First (beta) implementation of Labbu label fixing.
- uses label tool I wrote called "labbu" to contextually post-process labels
- Currently it's most useful for English, but there's still some good fixes for non-English languages.
- Fixed up the transcription editor
- Less unhelpful text in the file selection box
- Better interfacing with pygame mixer for playing audio
- Much easier to implement custom SOFA models.
- Here's a guide! https://github.com/spicytigermeat/LabelMakr/blob/v030/DOCS/implement_custom_sofa_model.md
24 changes: 24 additions & 0 deletions DOCS/credits.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Credits

## SOFA & SOFA Models 🛋️

- [SOFA](https://github.com/qiuqiao/SOFA/releases) & [Mandarin SOFA model](https://github.com/qiuqiao/SOFA/releases/tag/v1.0.1) developed by suco/qiuqiao.
- [tgm_sofa_en](https://github.com/spicytigermeat/SOFA-Models/releases/tag/v0.0.5) is developed by me, tigermeat
- [Japanese](https://github.com/colstone/SOFA_Models/releases/tag/JPN-V0.0.2b) & [Korean](https://github.com/colstone/SOFA_Models/releases/tag/KOR-V0.01b) SOFA models trained by colstone. The installed versions are trimmed by me to save space. (removed opimizer keys from statedict)
- [Millefeuille SOFA model](https://github.com/imsupposedto/SOFA-Models/releases/tag/millefeuille_b001) & fr_g2p model trained by imsupposedto.
- [Japanese G2p Compiled Version](https://github.com/CjangCjengh/japanese_g2p) by CjangCjengh.
- G2P models used are trained with [OpenUTAU's G2P system](https://github.com/stakira/OpenUtau/tree/master/py).

## GUI Translations 🗣️
- English/Japanese: tigermeat
- Traditional Chinese: ArchiVoice
- Indonesian: Koji
- French: [Hibya](https://twitter.com/Tweek_Twix) & [Mim](https://twitter.com/mimsynth)
- Korean: [군곰 (KUNGOM)](https://twitter.com/utaukg)

## Beta Testers 🧪
- [nobodyP](https://github.com/nobodyP)
- [Asteriski](https://github.com/agentasteriski)
- [Guillotama](https://twitter.com/Guillotamaa)
- [imsupposedto](https://github.com/imsupposedto)
- [Arden](https://github.com/Mildemelwe)
60 changes: 60 additions & 0 deletions DOCS/implement_custom_sofa_model.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# How to implement your own SOFA Model.
Here is a guide on how to implement your own SOFA model into LabelMakr!

NOTE:
- Please use ISO lang codes for LabelMakr. For example, if you are training an English model, suffix it with "en". If the accent is a specific region or dialect, you can do this: "en_uk". This is done to keep the naming cohesive.
- The G2p is TOTALLY optional! It's only necessary for languages where you will be likely to find words outside of the dictionary provided. For example, english has a lot of strange compound words, so the G2p can guess that. If your language is consistent in terms of spelling/pronunciation, like Spanish, a G2p is probably not necessary.
- There's no simple guides out there for the G2p's, but it uses OpenUTAU's G2p models with modified training parameters.

## What you will need
- SOFA Model (renamed to model.ckpt)
- SOFA Dictionary (renamed to dict.txt)

So, the folder structure will look like this once you have it set. Let's assume your model is called "custom_sofa_en"
```
LabelMakr
| assets
| corpus
| models
| | custom_sofa_en
| | | dict.txt
| | | model.ckpt
| strings
| labelmakr.py
...
```

Optional:

### OpenUTAU G2p
- OpenUTAU G2p CHECKPOINT (usually called g2p-best.ptsd, renamed to model.ptsd)
- OpenUTAU G2p training config (called cfg.yaml)

Change the `_target_` in all 3 locations in cfg.yaml to this:
```
_target_: models.g2p_model.G2p
Decoder:
_target_: models.g2p_model.Decoder
...
Encoder:
_target_: models.g2p_model.Encoder
...
```

This is what your folder structure will look like when you have it set up with a G2p. Let's assume your model is called "custom_sofa_en".
You need to be sure that all of the g2p items are saved in a folder called "g2p". LabelMakr will automatically determine if your SOFA Model has a G2p available to use.
```
LabelMakr
| assets
| corpus
| models
| | custom_sofa_en
| | | g2p
| | | | cfg.yaml
| | | | model.ptsd
| | | dict.txt
| | | model.ckpt
| strings
| labelmakr.py
...
```
File renamed without changes.
35 changes: 11 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,40 +1,27 @@
# LabelMakr 🛋️
A GUI Toolkit for generation of Singing Voice Synthesizer Phoneme-level labels, heavily utilizing SOFA & Whisper.

Follow development on trello [here](https://trello.com/b/ybVNYcmA/labelmakr)!
<p align="center">
<img src="https://github.com/spicytigermeat/LabelMakr/blob/v030/assets/labelmakr.png" alt="LabelMakr 🛋️">
</p>

<p align="center">
<img src="https://github.com/spicytigermeat/LabelMakr/assets/103609620/3b482e7e-3f7c-42cf-a562-3ca0fdca2de0">
<img src="https://github.com/spicytigermeat/LabelMakr/blob/v030/.github/labelmakr_sc.png", alt="Screenshot of LabelMakr and the transcription editor.">
</p>

LabelMakr is a GUI tool to help users easily generate SVS phoneme-level labels. It is intended for use with DiffSinger, but is easily adaptable for other systems. Currently, LabelMakr has full support for English, Japanese, Chinese, French and Korean singing!

Please use the portable version for Windows found [here](https://github.com/spicytigermeat/LabelMakr/releases/tag/v020)!!

## Community Contributions 🧑‍🤝‍🧑

- French Usage Guide can be found [here](https://utaufrance.com/comment-utiliser-labelmakr/)! (Written by [Mim](https://twitter.com/mimsynth))

# Credits 📰

- SOFA & v1.0.0_mandarin_song.ckpt SOFA model developed by [suco/qiuqiao](https://github.com/qiuqiao/SOFA).
- [tgm_sofa](https://github.com/spicytigermeat/SOFA-Models/releases/tag/v0.0.4) is developed by me, tigermeat (used ver: v005)
- Japanese SOFA model trained by [colstone](https://github.com/colstone/SOFA_Models/releases/tag/JPN-V0.0.2b). The installed version is trimmed to save space. (used ver: v0.0.2)
- Japanese G2p Compiled Version by [CjangCjengh](https://github.com/CjangCjengh/japanese_g2p).
- Millefeuille SOFA model & fr_g2p model trained by [imsupposedto](https://github.com/imsupposedto).
- G2P models used are trained with [OpenUTAU's G2P system](https://github.com/stakira/OpenUtau/tree/master/py).
- Beta testers: nobodyP, Asteriski, Guillotama, imsupposedto
## Custom SOFA Model Implementation

## GUI Translations 🗣️
- English/Japanese: tigermeat
- Traditional Chinese: ArchiVoice
- Indonesian: Koji
- French: Hibya & Mim
Please check out the guide on how to implement custom SOFA models [here!](https://github.com/spicytigermeat/LabelMakr/blob/v030/DOCS/implement_custom_sofa_model.md)

# Plans 📝
## Credits

- Implement automatic label cleanup (using labbu library)
- Continued GUI refinement and improvements!
- Clean up code and fix up localization method (i don't like i18n)
Please check out credits [here!](https://github.com/spicytigermeat/LabelMakr/blob/v030/DOCS/credits.md)

## Manual Installation 🧰

Read the guide on how to manually install LabelMakr [here](https://github.com/spicytigermeat/LabelMakr/blob/main/manual_install_guide.md)!
Read the guide on how to manually install LabelMakr [here!](https://github.com/spicytigermeat/LabelMakr/blob/v030/DOCS/manual_install_guide.md)
3 changes: 3 additions & 0 deletions assets/CREDIT_README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
All small icons downloaded from Google Fonts.

"Rainy Hearts" font by Camellina ([email protected])
121 changes: 121 additions & 0 deletions assets/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
Creative Commons Legal Code

CC0 1.0 Universal

CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE
LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN
ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS
INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES
REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS
PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM
THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED
HEREUNDER.

Statement of Purpose

The laws of most jurisdictions throughout the world automatically confer
exclusive Copyright and Related Rights (defined below) upon the creator
and subsequent owner(s) (each and all, an "owner") of an original work of
authorship and/or a database (each, a "Work").

Certain owners wish to permanently relinquish those rights to a Work for
the purpose of contributing to a commons of creative, cultural and
scientific works ("Commons") that the public can reliably and without fear
of later claims of infringement build upon, modify, incorporate in other
works, reuse and redistribute as freely as possible in any form whatsoever
and for any purposes, including without limitation commercial purposes.
These owners may contribute to the Commons to promote the ideal of a free
culture and the further production of creative, cultural and scientific
works, or to gain reputation or greater distribution for their Work in
part through the use and efforts of others.

For these and/or other purposes and motivations, and without any
expectation of additional consideration or compensation, the person
associating CC0 with a Work (the "Affirmer"), to the extent that he or she
is an owner of Copyright and Related Rights in the Work, voluntarily
elects to apply CC0 to the Work and publicly distribute the Work under its
terms, with knowledge of his or her Copyright and Related Rights in the
Work and the meaning and intended legal effect of CC0 on those rights.

1. Copyright and Related Rights. A Work made available under CC0 may be
protected by copyright and related or neighboring rights ("Copyright and
Related Rights"). Copyright and Related Rights include, but are not
limited to, the following:

i. the right to reproduce, adapt, distribute, perform, display,
communicate, and translate a Work;
ii. moral rights retained by the original author(s) and/or performer(s);
iii. publicity and privacy rights pertaining to a person's image or
likeness depicted in a Work;
iv. rights protecting against unfair competition in regards to a Work,
subject to the limitations in paragraph 4(a), below;
v. rights protecting the extraction, dissemination, use and reuse of data
in a Work;
vi. database rights (such as those arising under Directive 96/9/EC of the
European Parliament and of the Council of 11 March 1996 on the legal
protection of databases, and under any national implementation
thereof, including any amended or successor version of such
directive); and
vii. other similar, equivalent or corresponding rights throughout the
world based on applicable law or treaty, and any national
implementations thereof.

2. Waiver. To the greatest extent permitted by, but not in contravention
of, applicable law, Affirmer hereby overtly, fully, permanently,
irrevocably and unconditionally waives, abandons, and surrenders all of
Affirmer's Copyright and Related Rights and associated claims and causes
of action, whether now known or unknown (including existing as well as
future claims and causes of action), in the Work (i) in all territories
worldwide, (ii) for the maximum duration provided by applicable law or
treaty (including future time extensions), (iii) in any current or future
medium and for any number of copies, and (iv) for any purpose whatsoever,
including without limitation commercial, advertising or promotional
purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each
member of the public at large and to the detriment of Affirmer's heirs and
successors, fully intending that such Waiver shall not be subject to
revocation, rescission, cancellation, termination, or any other legal or
equitable action to disrupt the quiet enjoyment of the Work by the public
as contemplated by Affirmer's express Statement of Purpose.

3. Public License Fallback. Should any part of the Waiver for any reason
be judged legally invalid or ineffective under applicable law, then the
Waiver shall be preserved to the maximum extent permitted taking into
account Affirmer's express Statement of Purpose. In addition, to the
extent the Waiver is so judged Affirmer hereby grants to each affected
person a royalty-free, non transferable, non sublicensable, non exclusive,
irrevocable and unconditional license to exercise Affirmer's Copyright and
Related Rights in the Work (i) in all territories worldwide, (ii) for the
maximum duration provided by applicable law or treaty (including future
time extensions), (iii) in any current or future medium and for any number
of copies, and (iv) for any purpose whatsoever, including without
limitation commercial, advertising or promotional purposes (the
"License"). The License shall be deemed effective as of the date CC0 was
applied by Affirmer to the Work. Should any part of the License for any
reason be judged legally invalid or ineffective under applicable law, such
partial invalidity or ineffectiveness shall not invalidate the remainder
of the License, and in such case Affirmer hereby affirms that he or she
will not (i) exercise any of his or her remaining Copyright and Related
Rights in the Work or (ii) assert any associated claims and causes of
action with respect to the Work, in either case contrary to Affirmer's
express Statement of Purpose.

4. Limitations and Disclaimers.

a. No trademark or patent rights held by Affirmer are waived, abandoned,
surrendered, licensed or otherwise affected by this document.
b. Affirmer offers the Work as-is and makes no representations or
warranties of any kind concerning the Work, express, implied,
statutory or otherwise, including without limitation warranties of
title, merchantability, fitness for a particular purpose, non
infringement, or the absence of latent or other defects, accuracy, or
the present or absence of errors, whether or not discoverable, all to
the greatest extent permissible under applicable law.
c. Affirmer disclaims responsibility for clearing rights of other persons
that may apply to the Work or any use thereof, including without
limitation any person's Copyright and Related Rights in the Work.
Further, Affirmer disclaims responsibility for obtaining any necessary
consents, permissions or other rights required for any use of the
Work.
d. Affirmer understands and acknowledges that Creative Commons is not a
party to this document and has no duty or obligation with respect to
this CC0 or use of the Work.
Binary file added assets/PixelMplus10-Regular.ttf
Binary file not shown.
Binary file added assets/PixelOperator.ttf
Binary file not shown.
Binary file added assets/WenQuanYi.Bitmap.Song.16px.ttf
Binary file not shown.
Binary file added assets/align.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions assets/cfg.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
dark_mode: true
disp_lang: en_US
force_cpu: false
matmul: true
whisper_model: large
6 changes: 3 additions & 3 deletions assets/ctk_tgm_theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,9 @@
},
"CTkOptionMenu": {
"corner_radius": 6,
"fg_color": ["#3a7ebf", "#1f538d"],
"button_color": ["#325882", "#14375e"],
"button_hover_color": ["#234567", "#1e2c40"],
"fg_color": ["DarkGoldenrod3", "DarkGoldenrod3"],
"button_color": ["DarkGoldenrod3", "DarkGoldenrod3"],
"button_hover_color": ["DarkGoldenrod4", "DarkGoldenrod4"],
"text_color": ["#DCE4EE", "#DCE4EE"],
"text_color_disabled": ["gray74", "gray60"]
},
Expand Down
Binary file added assets/fastfw.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/fix.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/folder.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/labelmakr.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/neodgm.ttf
Binary file not shown.
Binary file added assets/pause.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/play.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 98715d0

Please sign in to comment.