Use uv for pip installs (#13586)
* Update tests to `pip install -e .` Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com> * Auto-format by https://ultralytics.com/actions * Update pyproject.toml Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com> * Use `setup-uv` and `uv pip` for package management. Replaced `setup-python` with `setup-uv` and updated pip commands to use the `uv` tool for dependency installation and listing. Simplifies package management and integrates * Use `setup-uv` and `uv pip` for package management. Replaced `setup-python` with `setup-uv` and updated pip commands to use the `uv` tool for dependency installation and listing. Simplifies package management and integrates-uv` for improved workflow consistency. * Use `setup-uv` and `uv pip` for package management. Replaced `setup-python` with `setup-uv` and updated pip commands to use the `uv` tool for dependency installation and listing. Simplifies package management and integrates-uv` for improved workflow consistency. * Use `setup-uv` and `uv pip` for package management. Replaced `setup-python` with `setup-uv` and updated pip commands to use the `uv` tool for dependency installation and listing. Simplifies package management and integrates-uv` for improved workflow consistency. --------- Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com> Co-authored-by: UltralyticsAssistant <web@ultralytics.com>
This commit is contained in:
1 parent
fe1d4d9947
commit
2ef886370c
10 files changed
+29
-28
No files matched your search
@@ -27,13 +27,12 @@ jobs:
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
cache: "pip" # cache pip dependencies
|
||||
- uses: astral-sh/setup-uv@v6
|
||||
- name: Install requirements
|
||||
run: |
|
||||
python -m pip install --upgrade pip wheel
|
||||
pip install -r requirements.txt coremltools openvino-dev "tensorflow-cpu<2.15.1" --extra-index-url https://download.pytorch.org/whl/cpu
|
||||
uv pip install --system -r requirements.txt coremltools openvino-dev tensorflow --extra-index-url https://download.pytorch.org/whl/cpu --index-strategy unsafe-best-match
|
||||
yolo checks
|
||||
pip list
|
||||
uv pip list
|
||||
- name: Benchmark DetectionModel
|
||||
run: |
|
||||
python benchmarks.py --data coco128.yaml --weights ${{ matrix.model }}.pt --img 320 --hard-fail 0.29
|
||||
@@ -66,15 +65,14 @@ jobs:
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
cache: "pip" # caching pip dependencies
|
||||
- uses: astral-sh/setup-uv@v6
|
||||
- name: Install requirements
|
||||
run: |
|
||||
python -m pip install --upgrade pip wheel
|
||||
torch=""
|
||||
if [ "${{ matrix.torch }}" == "1.8.0" ]; then
|
||||
torch="torch==1.8.0 torchvision==0.9.0"
|
||||
fi
|
||||
pip install -r requirements.txt $torch --extra-index-url https://download.pytorch.org/whl/cpu
|
||||
uv pip install --system -r requirements.txt $torch --extra-index-url https://download.pytorch.org/whl/cpu --index-strategy unsafe-best-match
|
||||
shell: bash # for Windows compatibility
|
||||
- name: Check environment
|
||||
run: |
|
||||
|
||||
Reference in new issue
Block a user