MontrealCorpusTools / Montreal-Forced-Aligner

Command line utility for forced alignment using Kaldi
https://montrealcorpustools.github.io/Montreal-Forced-Aligner/
MIT License
1.26k stars 242 forks source link

[BUG] There was an error connecting to the global MFA database server #730

Closed lsg1213 closed 4 months ago

lsg1213 commented 6 months ago

Debugging checklist

[ x ] Have you updated to latest MFA version? [ o ] Have you tried rerunning the command with the --clean flag?

Describe the issue I want to convert words to phones by the pre-trained english_us_mfa g2p model. However, I tried to execute the below command than it doesn't work

mfa model download g2p english_us_mf
mkdir test_result
echo "hi" > test
mfa g2p test english_us_mfa test_result

For Reproducing your issue Please fill out the following:

  1. Corpus structure
    • What language is the corpus in? English
    • How many files/speakers? only one => my real sample words are 50 thousands.
    • Are you using lab files or TextGrid files for input? No, only g2p converting.
  2. Dictionary
    • Are you using a dictionary from MFA? If so, which one? No dictionary
    • If it's a custom dictionary, what is the phoneset? No

Log file Please attach the log file for the run that encountered an error (by default these will be stored in ~/Documents/MFA). 2024-01-05 01:28:07,743 - mfa - DEBUG - Beginning run for test 2024-01-05 01:28:07,743 - mfa - DEBUG - Using "global" profile 2024-01-05 01:28:07,743 - mfa - DEBUG - Using multiprocessing with 3 2024-01-05 01:28:07,743 - mfa - DEBUG - Set up logger for MFA version: 0.1.dev5+gfbe345e.d20231207 2024-01-05 01:28:07,743 - mfa - DEBUG - Cleaned previous run 2024-01-05 01:28:07,900 - mfa - DEBUG - Checking the global MFA database server... 2024-01-05 01:28:08,087 - mfa - ERROR - There was an error in the run, please see the log

Desktop (please complete the following information):

Additional context I tried to restart server but it doesn't work Add any other context about the problem here. stderr messages are belows,

File "/group-volume/Montreal_forced_alignment/montreal_forced_aligner/command_line/g2p.py", line 119, in g2p_cli g2p.setup() File "/group-volume/Montreal_forced_alignment/montreal_forced_aligner/g2p/generator.py", line 839, in setup super().setup() File "/group-volume/Montreal_forced_alignment/montreal_forced_aligner/g2p/generator.py", line 651, in setup TopLevelMfaWorker.setup(self) File "/group-volume/Montreal_forced_alignment/montreal_forced_aligner/abc.py", line 544, in setup self.initialize_database() File "/group-volume/Montreal_forced_alignment/montreal_forced_aligner/abc.py", line 256, in initialize_database raise DatabaseError( montreal_forced_aligner.exceptions.DatabaseError: DatabaseError:

There was an error connecting to the global MFA database server. Please ensure the server is initialized (mfa server init) or running (mfa server start)

lsg1213 commented 6 months ago

Plus, I built the mfa v2.2.1 version from your github branch.

mmcauliffe commented 4 months ago

You might be able to get it to with with --no_use_postgres, but I would recommend using a later version via: https://montreal-forced-aligner.readthedocs.io/en/latest/installation.html#general-installation