DexiNed

DexiNed(Dense Extreme Inception Network)는 하나의 RGB 이미지에서 밀집 엣지 확률 맵을 예측하는 컨볼루션 네트워크입니다. LibreYOLO는 엣지 검출 전용 아키텍처를 래핑하며 라이브러리에 체크포인트는 포함되지 않습니다.

작업
edge
크기
b at 352 px
설치
pip install libreyolo
지원 티어
추론 전용, v부터 지원. 예측, 검증, 내보내기만 지원합니다. 학습 기능은 적용되지 않습니다.
업스트림
Xavier Soria의 DexiNed, MIT. 논문, 소스
라이선스
코드 MIT, 가중치 MIT. 상업적 사용

설치

DexiNed에는 선택적 extra가 필요하지 않습니다. 가져오는 모든 항목이 기본 설치에 포함됩니다.

bash
pip install libreyolo

예측

LibreYOLO는 DexiNed 체크포인트를 제공하지 않습니다. 공식 공개 가중치는 BIPED로 학습했으며 공개된 데이터셋 약관이 비상업적 용도로 제한하므로 LibreYOLO는 이를 미러링하지 않습니다. 라이선스를 보유한 체크포인트를 weights/convert_dexined_weights.py로 변환합니다. 이 스크립트는 LibreYOLO가 직접 불러올 수 있는 파일을 쓰기 전에 런타임 아키텍처를 기준으로 텐서 키를 검사합니다.

bash
python weights/convert_dexined_weights.py upstream.pth weights/LibreDexiNedb-edge.pt --verify

Python
from libreyolo import LibreYOLO, SAMPLE_IMAGE model = LibreYOLO("weights/LibreDexiNedb-edge.pt")result = model(SAMPLE_IMAGE, save=True) edges = result.edgesprint(edges.array.shape)        # [0, 1] 범위의 (H, W) float32print(edges.binary(0.5).sum())  # 임계값을 적용한 엣지 픽셀 수
CLI
libreyolo predict model=weights/LibreDexiNedb-edge.pt source=https://raw.githubusercontent.com/LibreYOLO/libreyolo/release/libreyolo/assets/parkour.jpg save=True

result.edges에는 [0, 1] 범위의 (H, W) float32 배열인 결과가 들어 있으며, .binary(threshold)는 불리언 엣지 마스크를 반환합니다. 바운딩 박스가 없으므로 conf, iou, max_det는 효과가 없습니다. 소스, 스트리밍, 결과 처리는 예측을 참조합니다.

변형

LibreYOLO의 DexiNed 크기는 하나입니다. LibreYOLO 벤치마크 하네스는 이 계열을 측정하지 않았으므로 비교할 공개 수치는 없습니다.

검증

val()은 짝을 이룬 엣지 데이터셋을 기준으로 BSDS 방식 ODS 및 OIS F-measure를 보고합니다. 이미지는 파일 이름이 같은 엣지 맵과 나란히 있으며 선택적 유효성 마스크를 사용하여 패딩된 픽셀을 계산에서 제외할 수 있습니다. imgsz는 네트워크 다운샘플 스트라이드로 나누어떨어져야 하며, 그렇지 않으면 LibreYOLO가 명확한 오류를 발생시킵니다.

Python
from libreyolo import LibreYOLO model = LibreYOLO("weights/LibreDexiNedb-edge.pt")metrics = model.val(data="my-dataset.yaml", imgsz=352) print(metrics["metrics/ODS"])   # 최적 데이터셋 스케일 F-measureprint(metrics["metrics/OIS"])   # 최적 이미지 스케일 F-measure
CLI
libreyolo val model=weights/LibreDexiNedb-edge.pt data=my-dataset.yaml imgsz=352

내보내기

작업ONNXTorchScriptExecuTorchTensorRTOpenVINOPaddleMNNRKNNncnnTFLiteCoreMLCore AI
edgeedge to ONNX: 지원함edge to TorchScript: 지원함edge to ExecuTorch: 지원함edge to TensorRT: 지원함edge to OpenVINO: 지원함edge to Paddle: 지원하지 않음edge to MNN: 지원하지 않음edge to RKNN: 지원하지 않음edge to ncnn: 지원하지 않음edge to TFLite: 지원함edge to CoreML: 지원하지 않음edge to Core AI: 지원하지 않음

엣지 내보내기는 고정 해상도, 배치 1 런타임 계약을 사용합니다. dynamic과 1이 아닌 batch는 거부되며 내보낸 그래프는 하나의 결합 확률 맵을 출력합니다. 내보낸 아티팩트는 파일 접미사에 따라 LibreYOLO()로 다시 불러오므로 .onnx 파일이 체크포인트처럼 동작하며 동일한 Results를 반환합니다.

Python
from libreyolo import LibreYOLO model = LibreYOLO("weights/LibreDexiNedb-edge.pt")model.export(format="onnx", imgsz=352)model.export(format="tensorrt", imgsz=352, half=True)
CLI
libreyolo export model=weights/LibreDexiNedb-edge.pt format=onnx imgsz=352libreyolo export model=weights/LibreDexiNedb-edge.pt format=tensorrt imgsz=352 half=True
내보낸 파일 사용하기
from libreyolo import LibreYOLO, SAMPLE_IMAGE model = LibreYOLO("weights/LibreDexiNedb-edge.onnx")result = model(SAMPLE_IMAGE) print(result.edges.array.shape)

라이선스

내려받는 특정 가중치의 Hugging Face 저장소에서 라이선스를 확인하십시오. LibreYOLO 조직의 모든 체크포인트에는 라이선스가 있으며 한 계열 안에서도 항상 같지는 않습니다. 해당 저장소가 신뢰할 수 있는 기준입니다. 아래 요약은 이 페이지를 마지막으로 검증했을 때 적용된 내용을 설명합니다.

관련 라이선스에 관한 설명이며 법률 자문이 아닙니다. 상업적으로 중요한 사안이라면 라이선스를 직접 읽고 별도의 법률 자문을 받으십시오.

원작
DexiNed, Xavier Soria
업스트림 라이선스
MIT
업스트림 소스
github.com/xavysp/DexiNed
LibreYOLO 코드
MIT
가중치
MIT, 저자가 배포합니다. LibreYOLO는 이를 호스팅하거나 미러링하지 않습니다.
해석
MIT is a permissive license, so the DexiNed architecture LibreYOLO ports can be used in commercial and closed-source products, with the license text and copyright notice kept alongside any copy you redistribute. LibreYOLO ships no checkpoint for this family: the officially released weights are trained on BIPED, whose published dataset terms restrict use to non-commercial purposes, and mirroring them would carry that restriction into a nominally MIT-licensed download. Convert a checkpoint you hold a license for with `weights/convert_dexined_weights.py`; the MIT code license does not change the terms attached to whatever checkpoint you convert.

LibreYOLO는 DexiNed 체크포인트를 게시하지 않습니다. LibreYOLO 조직 아래에는 아무것도 미러링되지 않습니다. 대신 weights/convert_dexined_weights.py로 라이선스를 보유한 체크포인트를 변환합니다.

인용

@INPROCEEDINGS {xsoria2020dexined,
author = {X. Soria and E. Riba and A. Sappa},
booktitle = {2020 IEEE Winter Conference on Applications of Computer Vision (WACV)},
title = {Dense Extreme Inception Network: Towards a Robust CNN Model for Edge Detection},
year = {2020},
volume = {},
issn = {},
pages = {1912-1921},
keywords = {image edge detection;convolution;training;feeds;machine learning;task analysis;kernel},
doi = {10.1109/WACV45572.2020.9093290},
url = {https://doi.ieeecomputersociety.org/10.1109/WACV45572.2020.9093290},
publisher = {IEEE Computer Society},
address = {Los Alamitos, CA, USA},
month = {mar}
}

@article{soria2023dexined_ext,
title = {Dense extreme inception network for edge detection},
journal = {Pattern Recognition},
volume = {139},
pages = {109461},
year = {2023},
issn = {0031-3203},
doi = {https://doi.org/10.1016/j.patcog.2023.109461},
url = {https://www.sciencedirect.com/science/article/pii/S0031320323001619},
author = {Xavier Soria and Angel Sappa and Patricio Humanante and Arash Akbarinia},
keywords = {Edge detection, Deep learning, CNN, Contour detection, Boundary detection, Segmentation}
}

github.com/xavysp/DexiNed#citation에 있는 저자의 인용 블록에서 복사했습니다.

LibreYOLO v1.5.0에서 검증되었습니다. 이 페이지의 지원 표, 체크포인트, 벤치마크 수치는 출시된 라이브러리와 공개된 가중치에서 생성되며 수동으로 작성되지 않습니다.