mirror of
https://github.com/THU-MIG/yolov10.git
synced 2025-05-23 05:24:22 +08:00
Update ci.yaml (#37)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
parent
a733e41bcc
commit
523eff99e2
45
.github/workflows/ci.yaml
vendored
45
.github/workflows/ci.yaml
vendored
@ -1,4 +1,5 @@
|
||||
# Ultralytics Continuous Integration (CI) GitHub Actions tests
|
||||
# YOLO 🚀 by Ultralytics, GPL-3.0 license
|
||||
# YOLO Continuous Integration (CI) GitHub Actions tests
|
||||
|
||||
name: Ultralytics CI
|
||||
|
||||
@ -12,13 +13,28 @@ on:
|
||||
|
||||
jobs:
|
||||
Tests:
|
||||
timeout-minutes: 60
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ ubuntu-latest ]
|
||||
python-version: [ 3.9 ]
|
||||
timeout-minutes: 60
|
||||
python-version: [ '3.10' ]
|
||||
model: [ yolov5n ]
|
||||
include:
|
||||
# - os: ubuntu-latest
|
||||
# python-version: '3.7' # '3.6.8' min
|
||||
# model: yolov5n
|
||||
# - os: ubuntu-latest
|
||||
# python-version: '3.8'
|
||||
# model: yolov5n
|
||||
# - os: ubuntu-latest
|
||||
# python-version: '3.9'
|
||||
# model: yolov5n
|
||||
- os: ubuntu-latest
|
||||
python-version: '3.8' # torch 1.7.0 requires python >=3.6, <=3.8
|
||||
model: yolov5n
|
||||
torch: '1.7.0' # min torch version CI https://pypi.org/project/torchvision/
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/setup-python@v4
|
||||
@ -37,11 +53,17 @@ jobs:
|
||||
- name: Install requirements
|
||||
run: |
|
||||
python -m pip install --upgrade pip wheel
|
||||
pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/cpu
|
||||
if [ "${{ matrix.torch }}" == "1.7.0" ]; then
|
||||
pip install -r requirements.txt torch==1.7.0 torchvision==0.8.1 --extra-index-url https://download.pytorch.org/whl/cpu
|
||||
else
|
||||
pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cpu
|
||||
fi
|
||||
# pip install ultralytics (production)
|
||||
pip install .
|
||||
shell: bash # for Windows compatibility
|
||||
- name: Check environment
|
||||
run: |
|
||||
# python -c "import utils; utils.notebook_init()"
|
||||
echo "RUNNER_OS is ${{ runner.os }}"
|
||||
echo "GITHUB_EVENT_NAME is ${{ github.event_name }}"
|
||||
echo "GITHUB_WORKFLOW is ${{ github.workflow }}"
|
||||
@ -51,7 +73,7 @@ jobs:
|
||||
python --version
|
||||
pip --version
|
||||
pip list
|
||||
- name: Test HUB training
|
||||
- name: Test pip package
|
||||
shell: python
|
||||
env:
|
||||
APIKEY: ${{ secrets.ULTRALYTICS_HUB_APIKEY }}
|
||||
@ -64,3 +86,16 @@ jobs:
|
||||
# ultralytics.checks()
|
||||
# ultralytics.reset_model(key) # reset trained model
|
||||
# ultralytics.start(key) # train model
|
||||
- name: Test detection
|
||||
shell: bash # for Windows compatibility
|
||||
run: |
|
||||
echo "TODO"
|
||||
- name: Test segmentation
|
||||
shell: bash # for Windows compatibility
|
||||
run: |
|
||||
echo "TODO"
|
||||
- name: Test classification
|
||||
shell: bash # for Windows compatibility
|
||||
run: |
|
||||
echo "TODO"
|
||||
# python ultralytics/yolo/v8/classify/train.py model=resnet18 data=mnist2560 epochs=1 img_size=64
|
||||
|
@ -58,7 +58,7 @@ def train(cfg):
|
||||
if __name__ == "__main__":
|
||||
"""
|
||||
CLI usage:
|
||||
python path/to/train.py epochs=10 project=PROJECT lr0=0.1
|
||||
python ultralytics/yolo/v8/classify/train.py model=resnet18 data=imagenette160 epochs=1 img_size=224
|
||||
|
||||
TODO:
|
||||
Direct cli support, i.e, yolov8 classify_train args.epochs 10
|
||||
|
Loading…
x
Reference in New Issue
Block a user