Skip to content

Commit

Permalink
Run make style & re-enable it in CI (#3127)
Browse files Browse the repository at this point in the history
  • Loading branch information
akx authored Nov 6, 2023
1 parent 6fef4f9 commit 38f6f8f
Show file tree
Hide file tree
Showing 11 changed files with 140 additions and 94 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/style_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,5 @@ jobs:
run: |
python3 -m pip install .[all]
python3 setup.py egg_info
# - name: Lint check
# run: |
# make lint
- name: Style check
run: make style
6 changes: 3 additions & 3 deletions TTS/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ def tts_coqui_studio(
language: str = None,
emotion: str = None,
speed: float = 1.0,
pipe_out = None,
pipe_out=None,
file_path: str = None,
) -> Union[np.ndarray, str]:
"""Convert text to speech using Coqui Studio models. Use `CS_API` class if you are only interested in the API.
Expand Down Expand Up @@ -359,7 +359,7 @@ def tts_to_file(
speaker_wav: str = None,
emotion: str = None,
speed: float = 1.0,
pipe_out = None,
pipe_out=None,
file_path: str = "output.wav",
**kwargs,
):
Expand Down Expand Up @@ -460,7 +460,7 @@ def tts_with_vc(self, text: str, language: str = None, speaker_wav: str = None):
"""
with tempfile.NamedTemporaryFile(suffix=".wav", delete=False) as fp:
# Lazy code... save it to a temp file to resample it while reading it for VC
self.tts_to_file(text=text, speaker=None, language=language, file_path=fp.name,speaker_wav=speaker_wav)
self.tts_to_file(text=text, speaker=None, language=language, file_path=fp.name, speaker_wav=speaker_wav)
if self.voice_converter is None:
self.load_vc_model_by_name("voice_conversion_models/multilingual/vctk/freevc24")
wav = self.voice_converter.voice_conversion(source_wav=fp.name, target_wav=speaker_wav)
Expand Down
4 changes: 3 additions & 1 deletion TTS/bin/synthesize.py
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,9 @@ def main():
tts_path = model_path
tts_config_path = config_path
if "default_vocoder" in model_item:
args.vocoder_name = model_item["default_vocoder"] if args.vocoder_name is None else args.vocoder_name
args.vocoder_name = (
model_item["default_vocoder"] if args.vocoder_name is None else args.vocoder_name
)

# voice conversion model
if model_item["model_type"] == "voice_conversion_models":
Expand Down
Loading

0 comments on commit 38f6f8f

Please sign in to comment.