Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running path problem #41

Closed
unparalleled-ysj opened this issue Jun 10, 2020 · 7 comments
Closed

Running path problem #41

unparalleled-ysj opened this issue Jun 10, 2020 · 7 comments
Assignees
Labels
bug 🐛 Something isn't working stat:awaiting response ☏ Waiting Response

Comments

@unparalleled-ysj
Copy link

[root@localhost TensorflowTTS]# CUDA_VISIBLE_DEVICES=0 python examples/tacotron2/train_tacotron2.py --train-dir ./dump/train/ --dev-dir ./dump/valid/ --outdir ./examples/tacotron2/exp/train.tacotron2.v1/ --config ./examples/tacotron2/conf/tacotron2.v1.yaml --use-norm 1 --mix_precision 0 --resume ""
Traceback (most recent call last):
File "examples/tacotron2/train_tacotron2.py", line 31, in
from examples.tacotron2.tacotron_dataset import CharactorMelDataset
ModuleNotFoundError: No module named 'examples'

Why do I get this error when running in the root directory ?

@ZDisket
Copy link
Collaborator

ZDisket commented Jun 10, 2020

Do you have a folder or other modules that go by 'examples'? That issue is common in Google Colaboratory. Or maybe the folder TensorflowTTS isn't in your sys.path

@dathudeptrai dathudeptrai self-assigned this Jun 10, 2020
@dathudeptrai dathudeptrai added bug 🐛 Something isn't working Cann't reproduce 🐶 The error may come from other library stat:awaiting response ☏ Waiting Response labels Jun 10, 2020
@dathudeptrai
Copy link
Collaborator

I don't know why it happened, in my case, i use anaconda and virtualen, everything work fine :)

@jun-danieloh
Copy link

jun-danieloh commented Jun 23, 2020

This is happening to me as well. I am using Docker environment...

root@deepbasegpu148:/home/jun1.oh/daniel_workspace/tacotron2_dathudeptrai_tf2# CUDA_VISIBLE_DEVICES=2 python3 ./examples/tacotron2/train_tacotron2.py --train-dir ./dump/train/ --dev-dir ./dump/valid/ --outdir ./examples/tacotron2/exp/train.tacotron2.v1/ --config ./examples/tacotron2/conf/tacotron2.v1.yaml --use-norm 1
Traceback (most recent call last):
  File "./examples/tacotron2/train_tacotron2.py", line 31, in <module>
    from examples.tacotron2.tacotron_dataset import CharactorMelDataset
ModuleNotFoundError: No module named 'examples.tacotron2'

@MokkeMeguru
Copy link
Collaborator

MokkeMeguru commented Jun 30, 2020

We should use

from tensorflow_tts.examples ...

instead of

from examples ...

in whole example script.

Because we use tensorflow-tts package, not example package.

@MokkeMeguru MokkeMeguru reopened this Jun 30, 2020
@MokkeMeguru
Copy link
Collaborator

Sorry, my mistake. We should use

import sys
sys.path.append(".")

import ...

@MokkeMeguru MokkeMeguru removed the Cann't reproduce 🐶 The error may come from other library label Jun 30, 2020
MokkeMeguru added a commit that referenced this issue Jun 30, 2020
reference
- #41

other update
- update some dockerfile for easy training
@MokkeMeguru
Copy link
Collaborator

MokkeMeguru commented Jul 2, 2020

We now solved the problem I think.
Can you try below code?

git clone https://github.com/TensorSpeech/TensorflowTTS TTTS
cd TTTS
docker-compose build
docker-compose up -d
docker-compose exec tensoflowtts /bin/bash
python examples/tacotron2/train_tacotron2.py 
# ...

@dathudeptrai
Copy link
Collaborator

i closed since it solved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working stat:awaiting response ☏ Waiting Response
Projects
None yet
Development

No branches or pull requests

5 participants