r9y9 / pysinsy

Python wrapper for Sinsy
https://r9y9.github.io/pysinsy/
MIT License
51 stars 11 forks source link

ImportError: /usr/local/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_get_nsamples #5

Closed Aniana0 closed 3 years ago

Aniana0 commented 3 years ago

My English is bad. So I used a translator. I'm sorry.

I installed wsl2 and Ubuntu(version: 2004.2021.222.0) to use nnsvs. Then I tried to install nnsvs using setup-nsvs-on-wsl (https://github.com/oatsu-gh/setup-nnsvs-on-wsl)), but it didn't install properly because of an error. So I copied the commands in 'setup_nnsvs_on_wsl.sh' and entered them directly into Windows Terminal to install the necessary packages and nnsvs. But nnsvs didn't work, and I checked and found an error when import pysinsy.

This is the result of import pysinsy: .>>> import pysinsy Traceback (most recent call last): File "", line 1, in File "/usr/local/lib/python3.8/dist-packages/pysinsy/init.py", line 5, in from .sinsy import Sinsy ImportError: /usr/local/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_get_nsamples

I tried reinstalling Ubuntu and nnsvs several times to resolve the error, but the problem was not resolved. Please help me to resolve this error...๐Ÿ˜ข Thank you for reading!

Original Message(Korean): ์ €๋Š” nnsvs๋ฅผ ์‚ฌ์šฉํ•˜๊ธฐ ์œ„ํ•ด wsl2์™€ Ubuntu(๋ฒ„์ „: 2004.2021.222.0)์„ ์„ค์น˜ํ–ˆ์Šต๋‹ˆ๋‹ค. ๊ทธ ๋‹ค์Œ setup-nnsvs-on-wsl(https://github.com/oatsu-gh/setup-nnsvs-on-wsl)์„ ์‚ฌ์šฉํ•ด nnsvs ์„ค์น˜ํ•˜๋ ค๊ณ  ํ–ˆ์ง€๋งŒ, ์˜ค๋ฅ˜๊ฐ€ ๋‚ฌ๊ณ  ์ œ๋Œ€๋กœ ์„ค์น˜๊ฐ€ ๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค. ๊ทธ๋ž˜์„œ setup_nnsvs_on_wsl.sh ์•ˆ์˜ ๋ช…๋ น์–ด๋ฅผ ํ•œ ์ค„ ์”ฉ ๋ณต์‚ฌํ•ด์„œ Windows Terminal์— ์ง์ ‘ ์ž…๋ ฅํ•˜์—ฌ ํ•„์š”ํ•œ ํŒจํ‚ค์ง€๋“ค๊ณผ nnsvs๋ฅผ ์„ค์น˜ํ–ˆ์Šต๋‹ˆ๋‹ค. ํ•˜์ง€๋งŒ nnsvs๊ฐ€ ์ž‘๋™ํ•˜์ง€ ์•Š์•˜๊ณ , ํ™•์ธํ•ด๋ณด๋‹ˆ pysinsy๋ฅผ importํ•  ๋•Œ ์˜ค๋ฅ˜๊ฐ€ ์žˆ์—ˆ์Šต๋‹ˆ๋‹ค.

์•„๋ž˜๋Š” pysinsy๋ฅผ importํ•œ ๊ฒฐ๊ณผ์ž…๋‹ˆ๋‹ค: .>>> import pysinsy Traceback (most recent call last): File "", line 1, in File "/usr/local/lib/python3.8/dist-packages/pysinsy/init.py", line 5, in from .sinsy import Sinsy ImportError: /usr/local/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_get_nsamples

์˜ค๋ฅ˜๋ฅผ ํ•ด๊ฒฐํ•˜๊ธฐ ์œ„ํ•ด Ubuntu์™€ nnsvs๋ฅผ ์—ฌ๋Ÿฌ๋ฒˆ ์žฌ์„ค์น˜ ํ•ด๋ณด์•˜์ง€๋งŒ ๋ฌธ์ œ๊ฐ€ ํ•ด๊ฒฐ๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค. ์ œ๊ฐ€ ์ด ์˜ค๋ฅ˜๋ฅผ ํ•ด๊ฒฐํ•  ์ˆ˜ ์žˆ๋„๋ก ๋„์™€์ฃผ์„ธ์š”...๐Ÿ˜ข ์ฝ์–ด์ฃผ์…”์„œ ๊ฐ์‚ฌํ•ฉ๋‹ˆ๋‹ค.

Aniana0 commented 3 years ago

I tried using Google Colab to use nnsvs and found an error in 'import pysinsy' too.

Error message: stage 0: Data preparation Traceback (most recent call last): File "/content/nnsvs/egs/nnsvs_natsume_singing/00-svs-world/utils/gen_lab.py", line 1, in import pysinsy File "/usr/local/lib/python3.7/dist-packages/pysinsy/init.py", line 5, in from .sinsy import Sinsy ImportError: /usr/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_save_riff 0it [00:00, ?it/s] 0it [00:00, ?it/s] 0it [00:00, ?it/s] 0it [00:00, ?it/s] 0it [00:00, ?it/s] Traceback (most recent call last): File "/content/nnsvs/egs/nnsvs_natsume_singing/00-svs-world/utils/perf_segmentation.py", line 85, in np.min(flatten_lengths), np.max(flatten_lengths), np.mean(flatten_lengths))) File "<__array_function__ internals>", line 6, in amin File "/usr/local/lib/python3.7/dist-packages/numpy/core/fromnumeric.py", line 2880, in amin keepdims=keepdims, initial=initial, where=where) File "/usr/local/lib/python3.7/dist-packages/numpy/core/fromnumeric.py", line 86, in _wrapreduction return ufunc.reduce(obj, axis, dtype, out, **passkwargs) ValueError: zero-size array to reduction operation minimum which has no identity Traceback (most recent call last): File "/content/nnsvs/egs/nnsvs_natsume_singing/00-svs-world/utils/finalize_lab.py", line 1, in import pysinsy File "/usr/local/lib/python3.7/dist-packages/pysinsy/init.py", line 5, in from .sinsy import Sinsy ImportError: /usr/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_save_riff

Original Message(Korean): ์ €๋Š” Google Colab์„ ์ด์šฉํ•ด nnsvs ์‚ฌ์šฉ์„ ๋‹ค์‹œ ์‹œ๋„ํ•ด๋ณด์•˜๊ณ , Colab์—์„œ๋„ 'import pysinsy'์—์„œ ์˜ค๋ฅ˜๊ฐ€ ๋‚˜๋Š” ๊ฒƒ์„ ๋ฐœ๊ฒฌํ–ˆ์Šต๋‹ˆ๋‹ค.

์˜ค๋ฅ˜ ๋ฉ”์‹œ์ง€: stage 0: Data preparation Traceback (most recent call last): File "/content/nnsvs/egs/nnsvs_natsume_singing/00-svs-world/utils/gen_lab.py", line 1, in import pysinsy File "/usr/local/lib/python3.7/dist-packages/pysinsy/init.py", line 5, in from .sinsy import Sinsy ImportError: /usr/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_save_riff 0it [00:00, ?it/s] 0it [00:00, ?it/s] 0it [00:00, ?it/s] 0it [00:00, ?it/s] 0it [00:00, ?it/s] Traceback (most recent call last): File "/content/nnsvs/egs/nnsvs_natsume_singing/00-svs-world/utils/perf_segmentation.py", line 85, in np.min(flatten_lengths), np.max(flatten_lengths), np.mean(flatten_lengths))) File "<__array_function__ internals>", line 6, in amin File "/usr/local/lib/python3.7/dist-packages/numpy/core/fromnumeric.py", line 2880, in amin keepdims=keepdims, initial=initial, where=where) File "/usr/local/lib/python3.7/dist-packages/numpy/core/fromnumeric.py", line 86, in _wrapreduction return ufunc.reduce(obj, axis, dtype, out, **passkwargs) ValueError: zero-size array to reduction operation minimum which has no identity Traceback (most recent call last): File "/content/nnsvs/egs/nnsvs_natsume_singing/00-svs-world/utils/finalize_lab.py", line 1, in import pysinsy File "/usr/local/lib/python3.7/dist-packages/pysinsy/init.py", line 5, in from .sinsy import Sinsy ImportError: /usr/lib/libsinsy.so.0.9: undefined symbol: HTS_Engine_save_riff

r9y9 commented 3 years ago

Could you ask the author of https://github.com/oatsu-gh/setup-nnsvs-on-wsl? I may look into the problem when I have some time but cannot guarantee when I get some time to do it as I have been busy at work recently.

Aniana0 commented 3 years ago

Thank you for your reply! I got it. I'll ask the author of setup-nnsvs-on-wsl, too. Please check when you have time so that it won't be a burden to you. I can wait forever.๐Ÿ˜†

This is just my opinion, I don't think it's a matter of setup-nsvs-on-wsl. My friend advised me to change the version of wsl to 1, and I reinstalled everything after changing the version of wsl to 1. When reinstalling everything, I tried installing nnsvs without 'setup-nsvs-on-wsl' and still got the same error. I saved the command and execution results that I entered to install 'nnsvs' in a txt file: log.txt

Original Message(Korean): ๋‹ต๋ณ€๊ฐ์‚ฌํ•ฉ๋‹ˆ๋‹ค! ์•Œ๊ฒ ์Šต๋‹ˆ๋‹ค. setup-nnsvs-on-wsl์˜ ์ œ์ž‘์ž์—๊ฒŒ๋„ ๋ฌผ์–ด๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค. ๋ถ€๋‹ด์ด ๋˜์ง€ ์•Š๋„๋ก ์—ฌ์œ ๊ฐ€ ์žˆ์„ ๋•Œ ์ฒœ์ฒœํžˆ ํ™•์ธํ•ด์ฃผ์„ธ์š”. ์ €๋Š” ์–ธ์ œ๊นŒ์ง€๋‚˜ ๊ธฐ๋‹ค๋ฆด ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.๐Ÿ˜†

์ด๊ฒƒ์€ ๊ทธ์ € ์ œ ์˜๊ฒฌ์ž…๋‹ˆ๋‹ค๋งŒ, setup-nsvs-on-wsl์˜ ๋ฌธ์ œ๊ฐ€ ์•„๋‹Œ ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค. ์ง€์ธ์ด ์ œ๊ฒŒ wsl์˜ ๋ฒ„์ „์„ 1๋กœ ๋ฐ”๊พธ์–ด ๋ณด๋ผ๊ณ  ์•Œ๋ ค์ฃผ์—ˆ๊ณ , ์ €๋Š” wsl์˜ ๋ฒ„์ „์„ 1๋กœ ๋ฐ”๊พธ๋ฉด์„œ ๋ชจ๋“  ๊ฒƒ์„ ๋‹ค์‹œ ์„ค์น˜ํ•ด๋ณด์•˜์Šต๋‹ˆ๋‹ค. ๊ทธ๋ฆฌ๊ณ  ๋‹ค์‹œ ๋ชจ๋“  ๊ฒƒ์„ ์„ค์น˜ํ•  ๋•Œ, ์ €๋Š” setup-nnsvs-on-wsl ์—†์ด nnsvs๋ฅผ ์„ค์น˜ํ•ด๋ณด์•˜๊ณ , ์—ฌ์ „ํžˆ ๊ฐ™์€ ์˜ค๋ฅ˜๊ฐ€ ๋‚ฌ์Šต๋‹ˆ๋‹ค. ์ €๋Š” nnsvs๋ฅผ ์„ค์น˜ํ•˜๊ธฐ ์œ„ํ•ด ์ž…๋ ฅํ•œ ๋ช…๋ น์–ด์™€ ์‹คํ–‰ ๊ฒฐ๊ณผ๋ฅผ txt ํŒŒ์ผ์— ์ €์žฅํ•ด๋‘์—ˆ์Šต๋‹ˆ๋‹ค: log.txt

So-Fann commented 3 years ago

I have the same question too. Do you fix it?

Aniana0 commented 3 years ago

I have the same question too. Do you fix it?

A few hours ago, I deleted everything and reinstalled nnsvs, and the error was fixed. I don't know why the error was fixed even though it was installed in the same process as before.๐Ÿค” This is a log of all the commands I entered in Ubuntu during the installation of nnsvs : command_logs.txt So you delete everything and try installing nnsvs again.

Original Message(Korean): ๋ช‡ ์‹œ๊ฐ„ ์ „, ๋ชจ๋“  ๊ฒƒ์„ ์‚ญ์ œํ•˜๊ณ  ๋‹ค์‹œ nnsvs๋ฅผ ์„ค์น˜ํ•˜๋‹ˆ ์˜ค๋ฅ˜๊ฐ€ ์‚ฌ๋ผ์กŒ์Šต๋‹ˆ๋‹ค. ์ €๋Š” ์ด์ „๊ณผ ๊ฐ™์€ ๊ณผ์ •์œผ๋กœ ์„ค์น˜ํ–ˆ์Œ์—๋„ ์˜ค๋ฅ˜๊ฐ€ ์‚ฌ๋ผ์ง„ ์ด์œ ๋ฅผ ์•Œ ์ˆ˜๊ฐ€ ์—†์—ˆ์Šต๋‹ˆ๋‹ค. ์ด๊ฒƒ์€ ์ œ๊ฐ€ NNSVS๋ฅผ ์„ค์น˜ํ•˜๋Š” ๋™์•ˆ ์šฐ๋ถ„ํˆฌ์— ์ž…๋ ฅํ•œ ๋ช…๋ น์–ด๋ฅผ ๊ธฐ๋กํ•œ ๊ฒƒ์ž…๋‹ˆ๋‹ค: command_logs.txt So-Fann๋‹˜๋„ ๋ชจ๋“  ๊ฒƒ์„ ์ง€์šด ๋’ค ๋‹ค์‹œ nnsvs๋ฅผ ์„ค์น˜ํ•ด๋ณด์‹œ๊ธธ ๋ฐ”๋ž๋‹ˆ๋‹ค