language: cn
model_unique_abbr: SSD_Pytorch
version: 1.0
identification:
  docker_image_name: ssd_gpu:1.0
  model_name: 单步多框检测器（SSD）
  semantic: Single Shot MultiBox Detector
  description: 以监督学习方式进行目标检测，实现对图像中对象的识别与定位
  category_application: 预测型
  category_data:
  - 图像数据
  - 遥感影像数据
  keywords:
  - 目标检测
  - 对象识别
  - 边界框预测
parameter_info:
  parameters:

  - arg_name: dataset_root
    param_type: input_data
    name: 训练数据集
    description: 训练使用的数据集文件路径
    data_type: str
    data_semantic: This field defines the root directory for the datasets used in training and testing
    is_single_en_dash: false
    specification:
      default: "datasets"



  - arg_name: local_rank
    param_type: param
    name: 本地进程编号
    description: 分布式训练时的本地进程编号，取默认值
    data_type: int
    data_semantic: Local rank
    is_single_en_dash: false
    specification:
      default: 0

  - arg_name: log_step
    param_type: param
    name: 日志打印步数
    description: 每隔多少步打印一次日志，取值范围[1,),建议选择默认值
    data_type: int
    data_semantic: Log step interval
    is_single_en_dash: false
    specification:
      default: 10

  - arg_name: save_step
    param_type: param
    name: 检查点保存步数
    description: 每隔多少步保存一次检查点，取值范围[1,)，建议取默认值
    data_type: int
    data_semantic: Save step interval
    is_single_en_dash: false
    specification:
      default: 2500

  - arg_name: eval_step
    param_type: param
    name: 评估步数
    description: 每隔多少步评估一次数据集，当 eval_step < 0 时禁用评估
    data_type: int
    data_semantic: Evaluation step interval
    is_single_en_dash: false
    specification:
      default: 2500

  - arg_name: use_tensorboard
    param_type: param
    name: 使用 TensorBoard
    description: 是否使用 TensorBoard
    data_type: bool
    data_semantic: Use TensorBoard
    is_single_en_dash: false
    specification:
      default: true

  - arg_name: num_classes
    param_type: param
    name: 类别数量
    description: 目标检测的类别数量
    data_type: int
    data_semantic: Number of classes
    is_single_en_dash: false
    specification:
      default: 81

  - arg_name: backbone_out_channels
    param_type: param
    name: 主干输出通道
    description: 主干网络的输出通道
    data_type: str
    data_semantic: Backbone output channels
    is_single_en_dash: false
    specification:
      default: "512,1024,512,256,256,256,256"

  - arg_name: priors_feature_maps
    param_type: param
    name: 先验框特征图
    description: 先验框的特征图尺寸
    data_type: str
    data_semantic: Priors feature maps
    is_single_en_dash: false
    specification:
      default: "64,32,16,8,4,2,1"

  - arg_name: priors_strides
    param_type: param
    name: 先验框步长
    description: 先验框的步长
    data_type: str
    data_semantic: Priors strides
    is_single_en_dash: false
    specification:
      default: "8,16,32,64,128,256,512"

  - arg_name: priors_min_sizes
    param_type: param
    name: 先验框最小尺寸
    description: 先验框的最小尺寸
    data_type: str
    data_semantic: Priors min sizes
    is_single_en_dash: false
    specification:
      default: "20.48,51.2,133.12,215.04,296.96,378.88,460.8"

  - arg_name: priors_max_sizes
    param_type: param
    name: 先验框最大尺寸
    description: 先验框的最大尺寸
    data_type: str
    data_semantic: Priors max sizes
    is_single_en_dash: false
    specification:
      default: "51.2,133.12,215.04,296.96,378.88,460.8,542.72"

  - arg_name: priors_aspect_ratios
    param_type: param
    name: 先验框长宽比
    description: 先验框的长宽比
    data_type: str
    data_semantic: Priors aspect ratios
    is_single_en_dash: false
    specification:
      default: "2;2,3;2,3;2,3;2,3;2;2"

  - arg_name: priors_boxes_per_location
    param_type: param
    name: 每个位置的先验框数量
    description: 每个位置的先验框数量
    data_type: str
    data_semantic: Priors boxes per location
    is_single_en_dash: false
    specification:
      default: "4,6,6,6,6,4,4"

  - arg_name: image_size
    param_type: param
    name: 图像尺寸
    description: 输入图像的尺寸
    data_type: int
    data_semantic: Input image size
    is_single_en_dash: false
    specification:
      default: 512


  - arg_name: max_iter
    param_type: param
    name: 最大迭代次数
    description: 训练的最大迭代次数，迭代次数不同可能影响模型精度，可根据需求选择，取值范围[1,)
    data_type: int
    data_semantic: Maximum iterations
    is_single_en_dash: false
    specification:
      default: 300

  - arg_name: lr_steps
    param_type: param
    name: 学习率步长
    description: 学习率调整的步长
    data_type: str
    data_semantic: Learning rate steps
    is_single_en_dash: false
    specification:
      default: "360000,480000"

  - arg_name: gamma
    param_type: param
    name: 学习率衰减系数
    description: 学习率衰减的乘法因子，建议取默认值
    data_type: float
    data_semantic: Learning rate decay
    is_single_en_dash: false
    specification:
      default: 0.1

  - arg_name: batch_size
    param_type: param
    name: 批量大小
    description: 每批训练样本数量，一般取值为2的幂次方，取值范围[1,)
    data_type: int
    data_semantic: Batch size
    is_single_en_dash: false
    specification:
      default: 1

  - arg_name: lr
    param_type: param
    name: 初始学习率
    description: 模型训练的初始学习率，取值范围(0,1)
    data_type: float
    data_semantic: Initial learning rate
    is_single_en_dash: false
    specification:
      default: 0.001

  - arg_name: output_dir
    param_type: output_data
    name: 输出目录
    description: 模型和日志的输出目录
    data_type: str
    data_semantic: Output directory
    is_single_en_dash: false
    specification:
      default: "outputs/cocoout"


application:
  domain: 目标检测
  objective: 依据先验信息对图像数据进行检测，识别并定位图像中的对象。
  link_models:
    alternative:
    - SSD_GPU_pytorch
  mechanism: 对输入图像数据使用编码器进行特征提取，再使用检测器从特征中识别并定位对象。
operation:
  usage: 在命令行中用代码指定最大步数, 图像路径，标签路径, 测试数据路径, 训练结果路径路径, 完成算法运行。
  exec_example:
  - docker run --gpu all  -v $(pwd):/data ssd_gpu:1.0 --dataset_root E:\datasets --train_dataset "coco_2014_train" --test_dataset "coco_2014_minival" --output_dir outputs/cocoout   --local_rank 0 --num_classes 81
  output_display:
  - 将预测得到的图像文件显示在前端页面中
license:
  -MIT License

technique:
  language:
  - Python
  os:
  - Linux
  - Windows

  hardware:
  - GPU
  dependencies:
  - name: python
    version: 3.7
  - name: numpy
    version: 1.21.6
  - name: opencv-python
    version: 4.9.0.80
  - name: tqdm
    version: 4.66.2
  - name: yacs
    version: 0.1.6
  - name: torch
    version: 1.5.0+cu101
  - name: torchvision
    version: 0.6.0+cu101
source:
  maintainer: XuanDi Liu
  organization: Beijing University of Civil Engineering and Architecture
  contact: lxd386469007@163.com
  references:
  - https://github.com/lufficc/SSD
