改进项目结构

This commit is contained in:
2025-03-14 15:44:41 +08:00
parent 8478b4a102
commit 9e79fb6a6d
95 changed files with 13745 additions and 64 deletions

View File

@ -413,7 +413,7 @@ def run(
# Save JSON
if save_json and len(jdict):
w = Path(weights[0] if isinstance(weights, list) else weights).stem if weights is not None else "" # weights
anno_json = str(Path("../../datasets/coco/annotations/instances_val2017.json")) # annotations
anno_json = str(Path("../datasets/coco/annotations/instances_val2017.json")) # annotations
pred_json = str(save_dir / f"{w}_predictions.json") # predictions
LOGGER.info(f"\nEvaluating pycocotools mAP... saving {pred_json}...")
with open(pred_json, "w") as f: