環境
- Windows11
- python 3.12.8
uv add labelimg でエラーが出る
(my-project) C:\Users\USER\my-project > uv add labelimg
Resolved 6 packages in 382ms
error: Distribution `pyqt5-qt5==5.15.16 @ registry+https://pypi.org/simple` can't be installed because it doesn't have a source distribution or wheel for the current platform
hint: You're on Windows (`win_amd64`), but `pyqt5-qt5` (v5.15.16) only has wheels for the following platforms: `manylinux2014_x86_64`, `macosx_10_13_x86_64`, `macosx_11_0_arm64`
解決策
pyqt5-qt5のバージョンがダメらしいので,先に以下を実行
uv add pyqt5-qt5==5.15.2
その後,labelimgをインストール
uv add labelimg
無事インストールできました
Resolved 61 packages in 320ms
Audited 46 packages in 0.04ms
追記
uv add torch
ができない方は,プロジェクト作成時にpythonのバージョンを指定すると解決します
uv init my-project -p 3.12