当前位置: 首页 > news >正文

网站建设的业务好做吗百度可以做网站吗

网站建设的业务好做吗,百度可以做网站吗,wordpress需要登录密码,铜陵seo公司Anomalib支持多种格式的数据集#xff0c;包括MVTec AD和BeanTech等最先进的异常检测基准数据集。对于希望在自定义数据集上使用该库的用户#xff0c;anomalib还提供了一个Folder datamodule#xff0c;可以从文件系统的文件夹中加载数据集。本文的目的是使用Folder datamo…Anomalib支持多种格式的数据集包括MVTec AD和BeanTech等最先进的异常检测基准数据集。对于希望在自定义数据集上使用该库的用户anomalib还提供了一个Folder datamodule可以从文件系统的文件夹中加载数据集。本文的目的是使用Folder datamodule在自定义数据集上训练anomalib模型。这将使用户能够灵活地使用anomalib来处理各种类型的数据并进行异常检测任务。 本文中我们将使用榛果玩具数据集。该数据集包含多个文件夹每个文件夹包含一组图像。colour和crack文件夹代表两种缺陷。本文忽略mask文件夹。anomalib将使用colour文件夹中的所有图像作为验证数据集的一部分然后随机划分good文件夹图像用于训练和验证。 Step 1: 安装Anomalib pip install anomalibStep 2: 搜集自定义数据 Anomalib支持多种图像扩展名如.jpg、“.jpeg”、“.png”、“.ppm”、“.bmp”、“.pgm”、“.tif”、“.tiff和”.webp。可以从具有任何这些扩展名的图像中收集数据集。 Step 3: 格式化数据 根据使用情况和收集方式自定义数据集可以具有不同的格式 包含好的和坏的图像的数据集。包含好的和坏的图像以及用于像素级评估的掩码真值的数据集。包含好的和坏的图像并已经分为训练集和测试集的数据集。 anomalib的Folder datamodule可以处理这些用例。 Step 4: 修改配置文件 要运行Anomalib的训练需要一个YAML配置文件。训练配置参数分为5个部分数据集(dataset)、模型(model)、项目(project)、日志(logging)和训练器(trainer)。Anomalib中使用自定义数据集只需要更改配置文件中的数据集部分即可。 这里选择Padim算法复制示例配置文件并修改数据集部分。 cp anomalib/models/padim/config.yaml custom_padim.yaml4-1 classification 数据目录 Hazelnut_toy ├── colour │ ├── 00.jpg │ ├── 01.jpg │ ... ├── good │ ├── 00.jpg │ ├── 01.jpg │ ...分类数据集没有ground truth的二值化掩膜mask因此需要将task字段设置为classification而不是segmentation。同时将metrics部分的pixel部分注释掉。 # Replace the dataset configs with the following. dataset:name: hazelnutformat: folderpath: ./datasets/hazelnut_toynormal_dir: good # name of the folder containing normal images.abnormal_dir: colour # name of the folder containing abnormal images.mask: null # optionalnormal_test_dir: null # name of the folder containing normal test images.task: classification # classification or segmentationextensions: nullsplit_ratio: 0.2 # ratio of the normal images that will be used to create a test splitimage_size: 256train_batch_size: 32test_batch_size: 32num_workers: 8normalization: imagenet # data distribution to which the images will be normalized: [none, imagenet]test_split_mode: from_dir # options: [from_dir, synthetic]val_split_mode: same_as_test # options: [same_as_test, from_test, sythetic]val_split_ratio: 0.5 # fraction of train/test images held out for validation (usage depends on val_split_mode)transform_config:train: nullval: nullcreate_validation_set: truetiling:apply: falsetile_size: nullstride: nullremove_border_count: 0use_random_tiling: Falserandom_tile_count: 16...metrics:image:- F1Score- AUROC # pixel: # - F1Score # - AUROCthreshold:method: adaptive #options: [adaptive, manual]manual_image: nullmanual_pixel: null注意每个dir值可以以列表的形式输入多个文件夹 4-2 segmentation Anomalib不仅可以对零件进行缺陷分类还可以用于缺陷分割。要实现这一点只需在与good和colour文件夹相同的目录级别上添加一个名为mask的文件夹。该文件夹应包含colour文件夹中缺陷的二进制图像。 数据目录 Hazelnut_toy ├── colour │ ├── 00.jpg │ ├── 01.jpg │ ... ├── good │ ├── 00.jpg │ ├── 01.jpg └── mask ├── 00.jpg ├── 01.jpg ...在配置文件中填充mask字段并将任务更改为segmentation即可使用Anomalib对缺陷进行分割。 # Replace the dataset configs with the following. dataset:name: hazelnutformat: folderpath: ./datasets/hazelnut_toynormal_dir: good # name of the folder containing normal images.abnormal_dir: colour # name of the folder containing abnormal images.mask: mask # optionalnormal_test_dir: null # name of the folder containing normal test images.task: segmentation # classification or segmentationextensions: nullsplit_ratio: 0.2 # ratio of the normal images that will be used to create a test splitimage_size: 256train_batch_size: 32test_batch_size: 32num_workers: 8normalization: imagenet # data distribution to which the images will be normalized: [none, imagenet]test_split_mode: from_dir # options: [from_dir, synthetic]val_split_mode: same_as_test # options: [same_as_test, from_test, sythetic]val_split_ratio: 0.5 # fraction of train/test images held out for validation (usage depends on val_split_mode)transform_config:train: nullval: nullcreate_validation_set: truetiling:apply: falsetile_size: nullstride: nullremove_border_count: 0use_random_tiling: Falserandom_tile_count: 16...metrics:image:- F1Score- AUROCpixel:- F1Score- AUROCthreshold:method: adaptive #options: [adaptive, manual]manual_image: nullmanual_pixel: nullStep 5: 训练 python tools/train.py --config custom_padim.yamlStep 6: 可视化 6-1 Logging and Experiment Management Anomalib提供了几种记录和跟踪实验的方式。这些可以单独或组合使用。 如要选择保存预测图像的结果请将配置文件中可视化部分的log_images参数更改为true。 results └── padim└── Hazelnut_toy├── images│ ├── colour│ │ ├── 00.jpg│ │ ├── 01.jpg│ │ └── ...│ └── good│ ├── 00.jpg│ ├── 01.jpg│ └── ...└── weights└── model.ckpt6-2 Logging to Tensorboard and/or WB 要使用TensorBoard和/或WB记录器和/或Comet记录器请确保在配置文件的日志部分将logger参数设置为comet、tensorboard、wandb或[tensorboardwandb]。下图显示了保存到TensorBoard的示例配置。 visualization:show_images: False # show images on the screensave_images: False # save images to the file systemlog_images: True # log images to the available loggers (if any)image_save_path: null # path to which images will be savedmode: full # options: [full, simple]logging:logger: [comet, tensorboard, wandb] #Choose any combination of these 3log_graph: false
http://www.yutouwan.com/news/328458/

相关文章:

  • 防城港网站建设天津建网站的公司
  • 网站的信息容量手机网站建站系统
  • 怎么做公司网站需要什么科目白石龙做网站
  • 用什么程序做网站最好优化python流星雨特效代码
  • 网站开发和软件开发有什么区别搭建一个电商网站需要多少费用
  • 服装订单接单网站哪些软件可以做网站
  • win7优化工具东莞市seo网络推广服务机构
  • 建站还有前途么wordpress如何做站群
  • 建设网站需要什么硬件三只松鼠网站怎样做
  • 网络舆情的网站网站界面设计工具
  • 用C语言做网站登录界面系统推广公司
  • 自己的网站怎么做实时监控简易的在线数据库网站模板下载
  • 网站布局结构wordpress半次元主题
  • 网上做公司网站怎么做手机网站营销
  • ant design 做网站图片生成器免费
  • 高唐做网站建设的公司哈尔滨市做网站优化
  • 北京做网站比较有名的公司大型网站建设兴田德润专业
  • o2o网站北京装修公司十大排名
  • 免费网站的app网站响应式技术
  • 泰安做网站公司哪家比较好在门户网站上爆光怎么做
  • 网站建设网站制作有限湖南网络工程职业学院高职扩招
  • 黑龙江建筑职业技术学院招生网站做网站 用 显示器
  • 做甜品网站栏目建设工程标准 免费下载网站
  • 儿童故事网站建设网站建设色系搭配
  • 网站制作代理平台小游戏网站建设
  • iis 网站打不开企业网站页面
  • 东莞市公司网站建设怎么样网页qq登陆保护
  • 计算机网站开发工作证学校校园网站
  • 转转怎么做钓鱼网站施工企业主要负责人包括
  • 简单网站开发实例网页版微信怎么加好友