mirror of
https://github.com/azaion/ai-training.git
synced 2026-04-22 13:26:35 +00:00
Update test results directory structure and enhance Docker configurations
- Modified `.gitignore` to reflect the new path for test results. - Updated `docker-compose.test.yml` to mount the correct test results directory. - Adjusted `Dockerfile.test` to set the `PYTHONPATH` and ensure test results are saved in the updated location. - Added `boto3` and `netron` to `requirements-test.txt` to support new functionalities. - Updated `pytest.ini` to include the new `pythonpath` for test discovery. These changes streamline the testing process and ensure compatibility with the updated directory structure.
This commit is contained in:
@@ -1,24 +1,10 @@
|
||||
import sys
|
||||
import types
|
||||
import importlib
|
||||
import shutil
|
||||
from os import path as osp
|
||||
from os import path
|
||||
from pathlib import Path
|
||||
|
||||
import pytest
|
||||
|
||||
for _n in ("boto3", "netron", "requests"):
|
||||
if _n not in sys.modules:
|
||||
sys.modules[_n] = types.ModuleType(_n)
|
||||
|
||||
for _k in [k for k in sys.modules if k == "ultralytics" or k.startswith("ultralytics.")]:
|
||||
del sys.modules[_k]
|
||||
from ultralytics import YOLO
|
||||
|
||||
for _m in ("exports", "train"):
|
||||
if _m in sys.modules:
|
||||
importlib.reload(sys.modules[_m])
|
||||
|
||||
import constants as c
|
||||
import train as train_mod
|
||||
import exports as exports_mod
|
||||
@@ -56,7 +42,7 @@ def e2e_result(tmp_path_factory):
|
||||
exports_mod.export_onnx(c.config.current_pt_model)
|
||||
exports_mod.export_coreml(c.config.current_pt_model)
|
||||
|
||||
today_ds = osp.join(c.config.datasets_dir, train_mod.today_folder)
|
||||
today_ds = path.join(c.config.datasets_dir, train_mod.today_folder)
|
||||
|
||||
yield {
|
||||
"today_dataset": today_ds,
|
||||
|
||||
Reference in New Issue
Block a user