-
-
Notifications
You must be signed in to change notification settings - Fork 116
Description
When build the docker environment, it reports torch not found. Thus recommend to install detectron2 with --no-build-isolation
RUN uv pip install -e ./src/detectron2 --no-build-isolation
[stage-0 39/44] RUN pip install -e ./src/detectron2 -i https://pypi.tuna.tsinghua.edu.cn/simple:
0.934 Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
0.934 Obtaining file:///app/src/detectron2
0.936 Installing build dependencies: started
2.550 Installing build dependencies: finished with status 'done'
2.552 Checking if build backend supports build_editable: started
2.805 Checking if build backend supports build_editable: finished with status 'done'
2.807 Getting requirements to build editable: started
2.936 Getting requirements to build editable: finished with status 'error'
2.942 error: subprocess-exited-with-error
2.942
2.942 × Getting requirements to build editable did not run successfully.
2.942 │ exit code: 1
2.942 ╰─> [23 lines of output]
2.942 Traceback (most recent call last):
2.942 File "/app/.venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 389, in
2.942 main()
2.942 File "/app/.venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 373, in main
2.942 json_out["return_val"] = hook(**hook_input["kwargs"])
2.942 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2.942 File "/app/.venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 157, in get_requires_for_build_editable
2.942 return hook(config_settings)
2.942 ^^^^^^^^^^^^^^^^^^^^^
2.942 File "/tmp/pip-build-env-n44ss_u4/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 473, in get_requires_for_build_editable
2.942 return self.get_requires_for_build_wheel(config_settings)
2.942 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2.942 File "/tmp/pip-build-env-n44ss_u4/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 331, in get_requires_for_build_wheel
2.942 return self._get_build_requires(config_settings, requirements=[])
2.942 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2.942 File "/tmp/pip-build-env-n44ss_u4/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 301, in _get_build_requires
2.942 self.run_setup()
2.942 File "/tmp/pip-build-env-n44ss_u4/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 512, in run_setup
2.942 super().run_setup(setup_script=setup_script)
2.942 File "/tmp/pip-build-env-n44ss_u4/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 317, in run_setup
2.942 exec(code, locals())
2.942 File "", line 10, in
2.942 ModuleNotFoundError: No module named 'torch'
2.942 [end of output]
2.942
2.942 note: This error originates from a subprocess, and is likely not a problem with pip.
3.577 error: subprocess-exited-with-error
3.577
3.577 × Getting requirements to build editable did not run successfully.
3.577 │ exit code: 1
3.577 ╰─> See above for output.
3.577
3.577 note: This error originates from a subprocess, and is likely not a problem with pip.
Dockerfile:67