Open-Sora
Open-Sora copied to clipboard
ModuleNotFoundError: No module named 'opensora'
我的程序报如下错误,请教各位大佬如何解决?
Traceback (most recent call last):
File "/workspace/Open-Sora/scripts/inference.py", line 9, in
from opensora.datasets import save_sample
ModuleNotFoundError: No module named 'opensora'
[2024-03-19 10:19:49,735] torch.distributed.elastic.multiprocessing.api: [ERROR] failed (exitcode: 1) local_rank: 0 (pid: 12125) of binary: /opt/conda/envs/Python3.10/bin/python
Traceback (most recent call last):
File "/opt/conda/envs/Python3.10/bin/torchrun", line 8, in
sys.exit(main())
File "/opt/conda/envs/Python3.10/lib/python3.10/site-packages/torch/distributed/elastic/multiprocessing/errors/init.py", line 347, in wrapper
return f(*args, **kwargs)
File "/opt/conda/envs/Python3.10/lib/python3.10/site-packages/torch/distributed/run.py", line 812, in main
run(args)
File "/opt/conda/envs/Python3.10/lib/python3.10/site-packages/torch/distributed/run.py", line 803, in run
elastic_launch(
File "/opt/conda/envs/Python3.10/lib/python3.10/site-packages/torch/distributed/launcher/api.py", line 135, in call
return launch_agent(self._config, self._entrypoint, list(args))
File "/opt/conda/envs/Python3.10/lib/python3.10/site-packages/torch/distributed/launcher/api.py", line 268, in launch_agent
raise ChildFailedError(
torch.distributed.elastic.multiprocessing.errors.ChildFailedError:
scripts/inference.py FAILED
Failures: <NO_OTHER_FAILURES>
Root Cause (first observed failure): [0]: time : 2024-03-19_10:19:49 host : job-3923-1709116005-wz7cc rank : 0 (local_rank: 0) exitcode : 1 (pid: 12125) error_file: <N/A> traceback : To enable traceback see: https://pytorch.org/docs/stable/elastic/errors.html
before run the inference code , you need compile opensora firstly.
This issue is stale because it has been open for 7 days with no activity.
Please refer to the https://github.com/hpcaitech/Open-Sora?tab=readme-ov-file#installation. I think you did not do pip install -e . in opensora repo.