Skip to content

Commit 890cb7e

Browse files
Merge pull request #35 from tomas-gajarsky/hotfix/test_detector_downloader
Hotfix/test detector downloader
2 parents b8fc7a2 + 82c7bb1 commit 890cb7e

File tree

6 files changed

+17
-5
lines changed

6 files changed

+17
-5
lines changed

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
notebooks/** linguist-vendored
2+
*.mako linguist-vendored

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
# Change Log
22

3+
4+
## 0.2.3
5+
6+
Released on February 2, 2023.
7+
8+
### Fixed
9+
* error in detector test
10+
11+
### Removed
12+
* deletion of detector model in tests
13+
14+
315
## 0.2.2
416

517
Released on January 28, 2023.

conf/analyzer/detector/retinaface.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ _target_: facetorch.analyzer.detector.FaceDetector
33

44
downloader:
55
_target_: facetorch.downloader.DownloaderGDrive
6-
file_id: 154x2VjmTQVqmowB0yZw4Uck7uQs2vVBs # str
6+
file_id: 1eMuOdGkiNCOUTiEbKKoPCHGCuDgiKeNC # str
77
path_local: /opt/facetorch/models/torchscript/detector/1/model.pt # str
88

99
device:

tests/test_detector.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
@pytest.mark.detector
1010
@pytest.mark.downloader
1111
def test_downloader_run(analyzer):
12-
if os.path.exists(analyzer.detector.downloader.path_local):
13-
os.remove(analyzer.detector.downloader.path_local)
1412
analyzer.detector.downloader.run()
1513
assert os.path.exists(analyzer.detector.downloader.path_local)
1614

tests/test_predictors.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ def test_downloaders_run(analyzer):
1212
for predictor in analyzer.predictors.values():
1313
# if os.path.exists(predictor.downloader.path_local):
1414
# os.remove(predictor.downloader.path_local)
15-
predictor.downloader.run()
15+
if not os.path.exists(predictor.downloader.path_local):
16+
predictor.downloader.run()
1617
assert os.path.exists(predictor.downloader.path_local)
1718

1819

version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.2.2
1+
0.2.3

0 commit comments

Comments
 (0)