docs: publish illustrated blog docx #35
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ci | |
| on: | |
| push: | |
| pull_request: | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.11" | |
| cache: pip | |
| - name: Install | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install -e ".[inference,dev]" | |
| - name: Compile and test | |
| run: | | |
| python -m compileall -q autolabel_with_single_class_models.py yolo_label_recovery tests platform/tools | |
| ruff check autolabel_with_single_class_models.py yolo_label_recovery tests examples platform/tools | |
| python tests/run_smoke_tests.py | |
| pytest | |
| - name: Generate public demo report | |
| run: yolo-label-recovery report examples/demo_output | |
| - name: Run model-free audit demo | |
| run: | | |
| python examples/create_synthetic_dataset.py --output /tmp/ylr-demo | |
| yolo-label-recovery audit /tmp/ylr-demo --output-dir /tmp/ylr-audit --hash-images --check-images | |
| python -c "import json; d=json.load(open('/tmp/ylr-audit/dataset_audit.json')); assert d['critical_issues']==2 and d['cross_split_duplicate_groups']==1" | |
| - name: Run threshold calibration demo | |
| run: | | |
| python examples/create_calibration_fixture.py --output /tmp/ylr-reviewed.csv | |
| yolo-label-recovery calibrate /tmp/ylr-reviewed.csv --output-dir /tmp/ylr-calibration --target-auto-precision 0.95 --auto-confidence-level 0.95 --target-review-recall 0.90 --min-auto-samples 20 --redact-paths | |
| python -c "import json; d=json.load(open('/tmp/ylr-calibration/calibration.json')); assert len(d['classes'])==6 and all(v['status']=='calibrated' and v['auto_precision_lower_bound']>=0.95 for v in d['classes'].values())" | |
| - name: Run cross-Teacher consensus demo | |
| run: | | |
| python examples/create_consensus_fixture.py --output-dir /tmp/ylr-consensus-fixture | |
| yolo-label-recovery consensus /tmp/ylr-consensus-fixture/primary_candidates.csv /tmp/ylr-consensus-fixture/verifier_candidates.csv --output-dir /tmp/ylr-consensus --agreement-iou 0.50 --verifier-min-confidence 0.50 --redact-paths | |
| python -c "import json; d=json.load(open('/tmp/ylr-consensus/consensus.json')); assert d['totals']['primary_auto']==72 and d['totals']['agreed_auto']==48 and d['totals']['downgraded_to_review']==24" | |
| - name: Run perceptual near-duplicate demo | |
| run: | | |
| python examples/create_near_duplicate_fixture.py --output /tmp/ylr-near-duplicates | |
| yolo-label-recovery cluster /tmp/ylr-near-duplicates --output-dir /tmp/ylr-near-duplicate-output --redact-paths | |
| python -c "import json; d=json.load(open('/tmp/ylr-near-duplicate-output/near_duplicate_summary.json')); assert d['totals']['images_discovered']==11 and d['totals']['fingerprint_failures']==1 and d['totals']['clusters']==3 and d['totals']['clustered_images']==7 and d['totals']['cross_split_clusters']==2" | |
| - name: Run active review prioritization demo | |
| run: | | |
| python examples/create_prioritization_fixture.py --output-dir /tmp/ylr-priority-fixture | |
| yolo-label-recovery prioritize /tmp/ylr-priority-fixture/candidates_review.csv /tmp/ylr-priority-fixture/dataset --output-dir /tmp/ylr-priority-output --budget 12 --redact-paths | |
| python -c "import json; d=json.load(open('/tmp/ylr-priority-output/prioritization_summary.json')); assert d['totals']['candidate_rows']==36 and d['totals']['selected_images']==12 and d['totals']['selected_classes']==6 and len({r['candidate_classes'] for r in d['queue'][:6]})==6" | |
| - name: Run exhaustive GT/AUTO review demo | |
| run: | | |
| python examples/create_review_fixture.py --output-dir /tmp/ylr-review-fixture | |
| yolo-label-recovery review-build /tmp/ylr-review-fixture/dataset /tmp/ylr-review-fixture/candidates.csv --output-dir /tmp/ylr-review-output --render --redact-paths | |
| python -c "import json; d=json.load(open('/tmp/ylr-review-output/summary.json')); assert d['prediction_rows']==5 and d['review_rows']==5 and d['render_failures']==0 and set(d['image_class_cases'])=={'GT0_AUTO0','GT0_AUTO1','GT1_AUTO0','GT1_AUTO1'}" | |
| - name: Build wheel | |
| run: python -m pip wheel --no-deps --wheel-dir dist . | |
| - name: Reject private artifacts | |
| shell: bash | |
| run: | | |
| forbidden=$(find . -type f \( -name '*.pt' -o -name '*.pth' -o -name '*.onnx' -o -name '*.engine' \) -print) | |
| if [ -n "$forbidden" ]; then | |
| printf '%s\n' "$forbidden" | |
| exit 1 | |
| fi | |
| - name: Reject common machine-specific paths | |
| shell: bash | |
| run: | | |
| if grep -RInE --exclude-dir=.git --exclude-dir=build --exclude-dir=dist --exclude-dir='*.egg-info' --exclude='ci.yml' --exclude='*.png' --exclude='*.svg' \ | |
| '([A-Za-z]:\\Users\\|[A-Za-z]:\\project|[A-Za-z]:\\yolo|/home/[^/]+/|/Users/[^/]+/)' .; then | |
| echo "Machine-specific path found. Replace it with a portable example." | |
| exit 1 | |
| fi | |
| collaboration-backend: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: platform/backend | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-java@v5 | |
| with: | |
| distribution: temurin | |
| java-version: "21" | |
| cache: maven | |
| - name: Test Spring Boot collaboration API | |
| run: mvn --batch-mode test | |
| collaboration-frontend: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: platform/frontend | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: "24" | |
| cache: npm | |
| cache-dependency-path: platform/frontend/package-lock.json | |
| - name: Build Vue collaboration workspace | |
| run: | | |
| npm ci | |
| npm run build |