Skip to content

gitlid/Vehicle-component-defect-detection-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 

Repository files navigation

车辆零部件缺陷检测API

简介

基于YOLO模型的车辆零部件缺陷检测API服务,支持实时检测零部件表面缺陷(裂纹、划痕、凹痕等)。提供RESTful接口,可快速集成到工业质检系统中。

系统要求

推荐环境

  • CUDA 工具包: 11.8+
  • cuDNN: 8.9.6+
  • NVIDIA 驱动: >= 515.65.01
  • 操作系统:
    • Windows 10/11 (x64)
    • Ubuntu 18.04/20.04/22.04 LTS (x64)

安装步骤

  1. Releases页面下载最新压缩包
  2. 解压到任意目录(建议路径不含中文或空格)

使用方法

cd fastapi_gpu_CTRS2 # 进入项目目录

fastapi_gpu_CTRS2.exe -h # 查看使用帮助
usage: fastapi_gpu_CTRS2.exe [-h] [--workers WORKERS] port model

positional arguments:
  port               端口号
  model              YOLO模型文件路径

options:
  -h, --help         show this help message and exit
  --workers WORKERS  工作进程数

基本启动(默认工作进程=1)

fastapi_gpu_CTRS2.exe <端口号> <模型路径>

示例:在10195端口加载NEU-DET模型

fastapi_gpu_CTRS2.exe 10195 NEU-DET.pt

目录结构

主要目录结构:

fastapi_gpu_CTRS2/
├── _internal/  # 各类依赖库
├── uploads/    # 存放检测结果的目录,首次检测时创建
├── NEU-DET.pt  # 默认提供的检测模型
└── fastapi_gpu_CTRS2.exe  # 执行文件

验证服务

成功启动服务后,访问 http://localhost:端口号/docs 获取交互式API文档

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published