개요
Supervision은 모델에 독립적인 컴퓨터 비전 도구 라이브러리로, 데이터 로딩, 이미지 주석 및 객체 추적을 지원합니다. COCO, Pascal VOC, YOLO 등의 형식을 호환하며 Ultralytics, Transformers 등의 라이브러리와 통합됩니다. 빠른 프로토타입 개발 및 배포에 적합합니다.
README 미리보기
\n \n \n \n \n \n\n\n\n[notebooks](https://github.com/roboflow/notebooks) | [inference](https://github.com/roboflow/inference) | [autodistill](https://github.com/autodistill/autodistill) | [maestro](https://github.com/roboflow/multimodal-maestro)\n\n\n\n[](https://badge.fury.io/py/supervision)\n[](https://pypistats.org/packages/supervision)\n[](LICENSE.md)\n[](https://badge.fury.io/py/supervision)\n[](https://codecov.io/gh/roboflow/supervision)\n\n[](https://snyk.io/advisor/python/supervision)\n[](https://colab.research.google.com/github/roboflow/supervision/blob/main/demo.ipynb)\n[](https://huggingface.co/spaces/Roboflow/Annotators)\n[](https://discord.gg/GbfgXGJ8Bk)\n\n\n \n \n\n\n\n## 👋 hello\n\n**We are your essential toolkit for computer vision.** From data loading to real-time zone counting, we provide the building blocks so you can focus on building applications around your models. 🤝\n\n## 💻 install\n\nPip install the supervision package in a\n[**Python>=3.9**](https://www.python.org/) environment.\n\n```bash\npip install supervision\n```\n\nRead more about conda, mamba, and installing from source in our [guide](https://roboflow.github.io/supervision/).\n\n## 🔥 quickstart\n\n### models\n\nSupervision was designed to be model agnostic. Just plug in any classification, detection, or segmentation model. For your convenience, we have created [connectors](https://supervision.roboflow.com/latest/detection/core/#detections) for the most popular libraries like Ultralytics, Transformers, MMDetection, or Inference. Other integrations, like `rfdetr`, already return `sv.Detections` directly.\n\nInstall the optional dependencies for this example with `pip install pillow rfdetr`.\n\n```python\nimport supervision as sv\nfrom PIL import Image\nfrom rfdetr import RFDETRSmall\n\nimage = Image.open(...)\nmodel = RFDETRSmall()\ndetections = model.predict(image, threshold=0.5)\n\nlen(detections)\n# 5\n```\n\n\n👉 more model connectors\n\n- inference\n\n Ru
FAQ (5)
문제 해결객체 탐지에서 Average Precision (AP)이 단일 IoU 임계값에서의 Precision과 다른 이유는 무엇인가요?
평균 정밀도(AP)와 고정된 IoU 임계값에서의 정밀도는 서로 다릅니다. AP는 정밀도-재현율 곡선 아래 면적으로, IoU 임계값을 고정한 상태(예: IoU=0.5)에서 신뢰도 점수 임계값을 변화시키며 계산됩니다. 단일 IoU 임계값에서의 정밀도는 해당 곡선 위의 한 점으로, 선택된 신뢰도와 IoU에서의 TP/(TP+FP)입니다. AP는 모든 재현율 수준에 걸쳐 정밀도를 집계하여 검출기의 성능을 요약하는 반면, 단일 임계값 정밀도는 하나의 작동 지점에서의 성능을 반영합니다. 이것이 단일 클래스 문제에서도 두 값이 다를 수 있는 이유입니다.
문제 해결왜 제 ultralytics 모델이 Supervision InferenceSlicer에 정의된 512x512 슬라이스 대신 전체 이미지에서 추론을 수행하나요?
Ultralytics는 학습 시 사용된 imgsz로 입력을 리사이즈합니다. 모델이 imgsz=2048로 학습된 경우, 추론 전에 512x512 슬라이스를 2048x2048로 업스케일합니다. 해결하려면 원하는 슬라이스 크기를 모델에 전달하세요: result = model(image, device='cuda', imgsz=512)[0]. imgsz가 InferenceSlicer에 설정된 slice_wh와 일치하는지 확인하십시오.
문제 해결동일한 클래스에 대해 여러 segmentation masks가 있는 COCO dataset을 로드할 때 supervision에서 'ValueError: setting an array element with a sequence'를 수정하는 방법?
이 오류는 supervision 0.20.0에서 COCO 주석에 단일 객체에 대한 여러 분할 항목이 있을 때 발생합니다. 임시 해결 방법으로 Ultralytics의 general_json2yolo.py에 있는 merge_multi_segment() 함수를 수정하여 로드하기 전에 여러 분할 마스크를 병합하세요. 영구적인 수정을 위해 이슈 #1209를 추적하세요.
문제 해결YOLO 데이터셋을 supervision의 as_coco로 COCO로 변환할 때 주석에 중복 ID가 생기는 이유는 무엇인가요?
이는 각 분할(train, valid, test)이 고유한 주석 ID 시퀀스를 생성하여 충돌을 일으키는 알려진 문제입니다. 해결 방법: 모든 분할을 하나의 YOLO 데이터셋으로 병합하고, as_coco를 사용하여 병합된 데이터셋을 COCO로 변환한 후, 연속적인 주석 ID를 유지하면서 COCO 데이터셋을 하위 집합으로 다시 분할합니다.
방법conda를 통해 supervision 0.26.0을 어떻게 설치하나요?
supervision 0.26.0이(가) 이제 conda-forge에서 사용 가능합니다. 다음 명령어로 설치하세요: conda install -c conda-forge supervision=0.26.0