CoolFace
Modelpublic

SanderGi/PCB-OBB

sourceHugging Facemitupdated 1y agoView on Hugging Face
0likes43downloads
README.md53 linesDownload Raw Back to root
1---2license: mit3base_model:4- Ultralytics/YOLO115tags:6- printed-circuit-boards7library_name: ultralytics8model-index:9- name: ultralytics/yolo1110  results:11  - task:12      type: object-detection13    metrics:14    - type: f115      value: 93.8%16      name: F1 Score17    - type: mAP5018      value: 93.0%19      name: mAP5020metrics:21- f1 - 93.8%22- mAP50 - 93.0%23---24 25# PCB Detection26 27There are [a lot of models](https://universe.roboflow.com/roboflow-100/printed-circuit-board/model/3) for detecting components within a Printed Circuit Board (PCB), but not as many for detecting which pixels (if any) in an image contain the PCB itself. Being able to determine if and where a PCB is in an image is useful for [calculating its size to estimate carbon footprint]((https://github.com/SanderGi/LCA)), as a preprocessing step for detecting components, to limit the amount of image more expensive PCB defect detection models have to process, and more.28 29Read more [here](https://github.com/SanderGi/PCB-Detection).30 31## Usage32 331. Download [`the model weights`](https://huggingface.co/SanderGi/PCB-OBB/resolve/main/best.pt?download=true)342. `pip install ultralytics`353. Run the model with `yolo task=obb mode=predict model=[path to model weights] source=[path to test image]` from the terminal or with Python:36 37```python38from ultralytics import YOLO39 40model = YOLO('[path to model weights]')41results = model.predict('[path/to/test/image.jpg]')42```43 44## Results45 46Dataset    | Precision | Recall | F1 Score | mAP50  | mAP50-9547-----------|-----------|--------|----------|--------|---------48Training   | 100.0%    | 100.0% | 100.0%   | 100.0% | 100.0%49Validation | 100.0%    | 100.0% | 100.0%   | 99.5%  | 97.0%50Test       | 100.0%    | 88.4%  | 93.8%    | 93.0%  | 91.2%51 52Sample predictions:53![sample predictions](https://github.com/SanderGi/PCB-Detection/raw/refs/heads/main/data/augmented_obb/runs/no_perspective3/val_batch1_pred.jpg)