glenn-jocher
commited on
Commit
•
07a82f4
1
Parent(s):
4102fcc
Update ci-testing.yml (#445)
Browse files* Update ci-testing.yml
* Update ci-testing.yml
* Update requirements.txt
* Update requirements.txt
* Update google_utils.py
* Update test.py
* Update ci-testing.yml
- .github/workflows/ci-testing.yml +2 -3
- requirements.txt +1 -1
- test.py +2 -2
- utils/google_utils.py +1 -1
.github/workflows/ci-testing.yml
CHANGED
@@ -10,9 +10,9 @@ jobs:
|
|
10 |
strategy:
|
11 |
fail-fast: false
|
12 |
matrix:
|
13 |
-
os: [ubuntu-latest
|
14 |
python-version: [3.8]
|
15 |
-
model: ['yolov5s'
|
16 |
|
17 |
# Timeout: https://stackoverflow.com/a/59076067/4521646
|
18 |
timeout-minutes: 50
|
@@ -41,7 +41,6 @@ jobs:
|
|
41 |
- name: Install dependencies
|
42 |
run: |
|
43 |
python -m pip install --upgrade pip
|
44 |
-
pip install -q numpy # for cocoapi proper install
|
45 |
pip install -qr requirements.txt -f https://download.pytorch.org/whl/cpu/torch_stable.html
|
46 |
pip install -q onnx
|
47 |
python --version
|
|
|
10 |
strategy:
|
11 |
fail-fast: false
|
12 |
matrix:
|
13 |
+
os: [ubuntu-latest, macos-latest, windows-latest]
|
14 |
python-version: [3.8]
|
15 |
+
model: ['yolov5s'] # models to test
|
16 |
|
17 |
# Timeout: https://stackoverflow.com/a/59076067/4521646
|
18 |
timeout-minutes: 50
|
|
|
41 |
- name: Install dependencies
|
42 |
run: |
|
43 |
python -m pip install --upgrade pip
|
|
|
44 |
pip install -qr requirements.txt -f https://download.pytorch.org/whl/cpu/torch_stable.html
|
45 |
pip install -q onnx
|
46 |
python --version
|
requirements.txt
CHANGED
@@ -10,7 +10,7 @@ PyYAML>=5.3
|
|
10 |
torchvision>=0.6
|
11 |
scipy
|
12 |
tqdm
|
13 |
-
pycocotools>=2.0
|
14 |
|
15 |
# Nvidia Apex (optional) for mixed precision training --------------------------
|
16 |
# git clone https://github.com/NVIDIA/apex && cd apex && pip install -v --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" . --user && cd .. && rm -rf apex
|
|
|
10 |
torchvision>=0.6
|
11 |
scipy
|
12 |
tqdm
|
13 |
+
# pycocotools>=2.0
|
14 |
|
15 |
# Nvidia Apex (optional) for mixed precision training --------------------------
|
16 |
# git clone https://github.com/NVIDIA/apex && cd apex && pip install -v --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" . --user && cd .. && rm -rf apex
|
test.py
CHANGED
@@ -220,8 +220,8 @@ def test(data,
|
|
220 |
cocoEval.accumulate()
|
221 |
cocoEval.summarize()
|
222 |
map, map50 = cocoEval.stats[:2] # update results (mAP@0.5:0.95, mAP@0.5)
|
223 |
-
except:
|
224 |
-
print('pycocotools
|
225 |
|
226 |
# Return results
|
227 |
model.float() # for training
|
|
|
220 |
cocoEval.accumulate()
|
221 |
cocoEval.summarize()
|
222 |
map, map50 = cocoEval.stats[:2] # update results (mAP@0.5:0.95, mAP@0.5)
|
223 |
+
except Exception as e:
|
224 |
+
print('ERROR: pycocotools unable to run: %s' % e)
|
225 |
|
226 |
# Return results
|
227 |
model.float() # for training
|
utils/google_utils.py
CHANGED
@@ -51,7 +51,7 @@ def gdrive_download(id='1n_oKgR81BJtqk75b00eAjdv03qVCQn2f', name='coco128.zip'):
|
|
51 |
s = "curl -Lb ./cookie \"drive.google.com/uc?export=download&confirm=`awk '/download/ {print $NF}' ./cookie`&id=%s\" -o %s" % (
|
52 |
id, name)
|
53 |
else: # small file
|
54 |
-
s =
|
55 |
r = os.system(s) # execute, capture return values
|
56 |
os.remove('cookie') if os.path.exists('cookie') else None
|
57 |
|
|
|
51 |
s = "curl -Lb ./cookie \"drive.google.com/uc?export=download&confirm=`awk '/download/ {print $NF}' ./cookie`&id=%s\" -o %s" % (
|
52 |
id, name)
|
53 |
else: # small file
|
54 |
+
s = 'curl -s -L -o %s "drive.google.com/uc?export=download&id=%s"' % (name, id)
|
55 |
r = os.system(s) # execute, capture return values
|
56 |
os.remove('cookie') if os.path.exists('cookie') else None
|
57 |
|