Open-Sora icon indicating copy to clipboard operation
Open-Sora copied to clipboard

ModuleNotFoundError: No module named 'opensora'

Open xcssgzs opened this issue 1 year ago • 2 comments

我的程序报如下错误,请教各位大佬如何解决? 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

xcssgzs avatar Mar 19 '24 14:03 xcssgzs

before run the inference code , you need compile opensora firstly.

yjdqk avatar Mar 21 '24 02:03 yjdqk

This issue is stale because it has been open for 7 days with no activity.

github-actions[bot] avatar Mar 29 '24 01:03 github-actions[bot]

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.

zhengzangw avatar May 10 '24 06:05 zhengzangw