CoolFace
Datasetpublic

SafeVixAI/SafeVixAI-Dataset-Hub

SafeVixAI Dataset Hub πŸ›‘οΈ The Intelligence Layer for the SafeVixAI platform β€” IIT Madras Road Safety Hackathon 2026 This repository hosts all datasets, pre-trained models, notebooks, and reproducible data acquisition scripts that power the SafeVixAI application. It is designed to be cloned directly into Google Colab or any research environment. Main Application Repo: SafeVixAI/SafeVixAI ⚑ Quickstart (Google Colab) # Clone the entire intelligence layer !git… See the full description on the dataset page: https://huggingface.co/datasets/SafeVixAI/SafeVixAI-Dataset-Hub.

sourceHugging Faceapache-2.0updated 4mo agoView on Hugging Face
1likes147downloads
sync_pdfs.py73 linesDownload Raw Back to data
1"""Move WHO PDF from Downloads and sync all 3 PDFs to both repos."""2import sys, io, shutil3from pathlib import Path4 5sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding="utf-8", errors="replace")6 7DOWNLOADS  = Path(r"C:\Users\Dell\Downloads")8LEGAL_HUB  = Path(r"C:\Hackathons\IITM\SafeVixAI-Dataset-Hub\scripts\scripts\chatbot_service\data\legal")9MED_HUB    = Path(r"C:\Hackathons\IITM\SafeVixAI-Dataset-Hub\scripts\scripts\chatbot_service\data\medical")10LEGAL_MAIN = Path(r"C:\Hackathons\IITM\SafeVixAI\backend\chatbot_service\data\legal")11MED_MAIN   = Path(r"C:\Hackathons\IITM\SafeVixAI\backend\chatbot_service\data\medical")12 13for d in [LEGAL_HUB, MED_HUB, LEGAL_MAIN, MED_MAIN]:14    d.mkdir(parents=True, exist_ok=True)15 16# ── Find WHO PDF in Downloads ────────────────────────────────────────────────17print("Scanning Downloads for WHO PDF...")18all_pdfs = sorted(DOWNLOADS.glob("*.pdf"), key=lambda p: p.stat().st_mtime, reverse=True)19print(f"  Found {len(all_pdfs)} PDF(s) in Downloads (newest first):")20for p in all_pdfs[:8]:21    print(f"    {p.name:60s} {p.stat().st_size//1024}KB")22 23# Pick the most likely WHO PDF (largest recent PDF that isn't one of our legal acts)24who_src = None25for p in all_pdfs:26    name_lower = p.name.lower()27    if p.stat().st_size > 100_000:28        # Exclude the ones we already have29        if "motor" not in name_lower and "amendment" not in name_lower and "1988" not in name_lower:30            who_src = p31            break32 33if who_src:34    print(f"\nWHO PDF found: {who_src.name} ({who_src.stat().st_size//1024}KB)")35    for dest in [MED_HUB / "who_trauma_care_guidelines.pdf", MED_MAIN / "who_trauma_care_guidelines.pdf"]:36        shutil.copy2(who_src, dest)37        print(f"  Copied -> {dest.parent.name}/{dest.name}")38else:39    print("  WHO PDF not found in Downloads β€” will need manual download")40 41# ── Sync legal PDFs from Hub to Main ────────────────────────────────────────42print("\nSyncing legal PDFs Hub -> Main...")43for fname in ["mv_act_1988_full.pdf", "mv_amendment_act_2019.pdf"]:44    src = LEGAL_HUB / fname45    dst = LEGAL_MAIN / fname46    if src.exists() and src.stat().st_size > 50000:47        shutil.copy2(src, dst)48        print(f"  OK  {fname} ({src.stat().st_size//1024}KB)")49    else:50        print(f"  XX  {fname} not found in Hub legal dir")51 52# ── Final Status ─────────────────────────────────────────────────────────────53print("\n" + "=" * 65)54print("  FINAL PDF STATUS β€” ALL LOCATIONS")55print("=" * 65)56for label, folder in [57    ("Hub Legal",   LEGAL_HUB),58    ("Hub Medical", MED_HUB),59    ("Main Legal",  LEGAL_MAIN),60    ("Main Medical",MED_MAIN),61]:62    pdfs = sorted(folder.glob("*.pdf"))63    print(f"\n  [{label}] β€” {folder}")64    if pdfs:65        for p in pdfs:66            magic = open(p, "rb").read(4)67            valid = "VALID PDF" if magic == b"%PDF" else "INVALID"68            print(f"    {p.name:45s} {p.stat().st_size//1024:>6}KB  {valid}")69    else:70        print("    (empty)")71 72print("\n" + "=" * 65)73