mask rcnn实例分割

In this article, I will be creating my own trained model for detecting potholes. For detection, I will be using the instance segmentation technique using the Mask-RCNN with the help of Supervisely.

在本文中,我将创建自己的训练有素的模型来检测坑洼。 为了进行检测,我将在Supervisely的帮助下使用Mask-RCNN使用实例分割技术。

Before creating our model lets get to know what tools and techniques we are using.

在创建模型之前,让我们了解我们正在使用哪些工具和技术。

什么是实例细分? (What is Instance Segmentation?)

Instance segmentation is a technique used for detecting by masking or covering a detected object pixel to pixel. Instance segmentation is very useful in Automatic car as we get pixel to pixel result which increases the accuracy of less accidents

实例分割是一种用于通过掩蔽或覆盖检测到的对象像素到像素来进行检测的技术。 实例分割在自动驾驶汽车中非常有用,因为我们获得了像素到像素的结果,这增加了较少事故的准确性

面罩-RCNN (Mask-RCNN)

Mask-RCNN is a deep neural network aimed to solve instance segmentation problem in machine learning or computer vision. There are two stages of Mask RCNN. First, it generates proposals about the regions where there might be an object based on the input image. Second, it predicts the class of the object, refines the bounding box and generates a mask in pixel level of the object based on the first stage proposal.

Mask-RCNN是一个深度神经网络,旨在解决机器学习或计算机视觉中的实例分割问题。 Mask RCNN有两个阶段。 首先,它基于输入图像生成有关可能存在对象的区域的建议。 其次,它根据第一阶段的建议,预测对象的类别,优化边界框并在对象的像素级别生成掩码。

Mask-RCNN is actually a trained model but in this article I will be showing you how to fine tune or train the Mask-RCNN model for your own custom objects.

Mask-RCNN实际上是经过训练的模型,但是在本文中,我将向您展示如何为自己的自定义对象微调或训练Mask-RCNN模型。

Mask-RCNN structure
Mask-RCNN结构

什么是监督以及如何使用? (What is Supervisely and how to use it ?)

Supervisely is a web platform used for solving computer vision problem. With the help of supervisely we can annotate our images very easily and after annotating our image we can easily train our data on any deep learning model without coding.

Supervisely是用于解决计算机视觉问题的Web平台。 在监督的帮助下,我们可以非常轻松地对图像进行注释,并且在对图像进行注释之后,我们可以轻松地在任何深度学习模型上训练数据而无需进行编码

Yes you read it write we can do any object detection task in supervisely without coding.

是的,您读到它是写的,我们无需编码即可监督任何对象检测任务。

Supervisely Workflow
监督工作流程

So we have discussed about all the tools and techniques. Let’s directly jump to the practical part.

因此,我们已经讨论了所有工具和技术。 让我们直接跳到实际部分。

如何监督使用Mask R-CNN进行目标检测? (How to Use Mask R-CNN in Supervisely for Object Detection ?)

In this practical, I will be detecting road potholes by masking the detected area.

在本练习中,我将通过遮盖检测到的区域来检测道路坑洼。

收集和注释数据集 (Collecting and Annotating the Dataset)

I have collected the datasset from Kaggle’s Pothole image dataset. You can collect the dataset from here.

我已经从Kaggle的Pothole图片数据集中收集了数据集。 您可以从此处收集数据集。

Now let’s use supervisely for annotating the images. Before annotating let’s import the data in supervisely.

现在,让我们监督使用图像批注。 在注释之前,让我们监督导入数据。

First create a workspace in supervisely

首先在监督下创建工作区

creating a workspace
创建工作区

Then import the data from your pc. For importing click on the import and then click the start import button.

然后从您的电脑导入数据。 对于导入,请单击导入,然后单击开始导入按钮。

For annotating the images , click on projects >> Pothole dataset >>From the drop down menu click on Start annotation.

要为图像添加注释,请单击项目>> Pothole数据集>>从下拉菜单中单击开始注释。

I will be using the Bitmap annotation. Now annotate only that area which you want to detect.

我将使用位图注释。 现在仅注释要检测的区域。

Bitmap annotation
位图注释

使用DTL进行数据扩充 (Data augmentation with DTL)

After annotating all the images it’s time to augment our data. Augmentation is a technique used for increasing the data samples by doing some small changes like horizontal flipping , vertical flipping , rotating , mirroring , shearing etc to the collected dataset.

在注释完所有图像之后,该增加数据了。 增强是一种通过对收集的数据集进行一些小的更改(如水平翻转,垂直翻转,旋转,镜像,剪切等)来增加数据样本的技术。

In supervisely , I will take help of dtl(Data transformation language) for augmenting the data. You can refer the below json code as a dtl.

在监督下,我将借助dtl(数据转换语言)来增强数据。 您可以将以下json代码称为dtl。

select the run DTL option
选择运行DTL选项
DTL workflow
DTL工作流程

Now click the start button. After clicking we can see that a new images folder is created. So our Data augmentation part is done . Let’s move to the next part.

现在单击开始按钮。 单击后,我们可以看到创建了一个新的图像文件夹。 这样我们的数据扩充部分就完成了。 让我们进入下一部分。

带有增强数据的训练蒙版-RCNN (Training Mask-RCNN with Augmented data)

I will be using the Mask-RCNN model for training the pothole images.

我将使用Mask-RCNN模型训练坑洼图像。

So click on the neural network option , you will see the list of neural network models . Then Add the Mask-RCNN(keras+TF)(COCO) model.

因此,单击神经网络选项,您将看到神经网络模型的列表。 然后添加Mask-RCNN(keras + TF)(COCO)模型。

clone the neural network
克隆神经网络

Now train the neural network by clicking on Train button

现在,通过单击“训练”按钮来训练神经网络

But training our NN gives us error. It gives error because we haven’t given the required agents or the resources. I will be using the aws cloud to give proper agents

但是训练我们的神经网络会给我们带来错误。 由于我们没有提供所需的代理或资源,因此产生错误。 我将使用AWS云提供适当的代理

Now click on the Cluster page link for creating a cluster

现在单击“群集”页面链接以创建群集

new cluster is created
创建新集群
Requirements for our agent
对我们代理商的要求

使用AWS云实例来训练我们的模型 (Using Aws cloud instance for training our model)

For using aws services you must have an aws account.

要使用aws服务,您必须具有aws帐户。

For running an EC2 instance follow the below steps:

要运行EC2实例,请执行以下步骤:

  1. First go to AWS EC2 service then click on Launch Instance.After that we are going to select a instance which has Linux , Docker , GPU , Nvidia-Docker.首先进入AWS EC2服务,然后点击Launch Instance,然后选择一个具有Linux,Docker,GPU和Nvidia-Docker的实例。
  2. Select the Deep Learning AMI (Ubuntu 18.04)选择深度学习AMI(Ubuntu 18.04)

3. We are going to select the GPU instance named as p2.xlarge

3.我们将选择名为p2.xlarge的GPU实例。

4. Now go the configure instance and do the following configurations

4.现在转到configure实例并执行以下配置

5. Give a minimum of 90Gib storage.

5.至少提供90Gib的存储空间。

6. Now after creating a key launch the instance. For logging into your instance use ssh command

6.现在,在创建密钥后启动实例。 要登录到您的实例,请使用ssh命令

instance is launched
实例启动

For training copy and paste the curl command from supervisely on our ec2 instance.

为了进行训练,请在ec2实例上监督复制并粘贴curl命令。

Running the bash command
运行bash命令

Wait for the complete setup to install

等待完整的安装程序安装

Now go to the supervisely train the Mask -RCNN model

现在去监督训练Mask -RCNN模型

First all the images will be downloaded in our instance

首先,所有图片将在我们的实例中下载

Model starts training
模型开始训练

We can also see the training graph and logs of our model

我们还可以看到我们模型的训练图和日志

So after training your model don’t forget to stop your instance as aws charges on per hourly basis.

因此,在训练完模型之后,别忘了停止实例,因为AWS每小时都会收费。

Finally after training we can test our model by uploading some testing images. Here is the result of our model , I think it works pretty well.

最后,经过训练,我们可以通过上传一些测试图像来测试模型。 这是我们模型的结果,我认为它运行良好。

Pothole image segmentation
坑洼图像分割

感谢您的阅读! (Thank you for reading!)

I hop you liked my article . Please clap , share and comment.

我希望你喜欢我的文章。 请鼓掌,分享和评论。

翻译自: https://medium.com/swlh/instance-segmentation-using-mask-rcnn-f499bd4ed564

mask rcnn实例分割


http://www.taodudu.cc/news/show-863608.html

相关文章:

  • 使用FgSegNet进行前景图像分割
  • 完美下巴标准_平行下颚抓
  • api 规则定义_API有规则,而且功能强大
  • r语言模型评估:_情感分析评估:对自然语言处理的过去和未来的反思
  • 机器学习偏差方差_机器学习101 —偏差方差难题
  • 机器学习 多变量回归算法_如何为机器学习监督算法识别正确的自变量?
  • python 验证模型_Python中的模型验证
  • python文本结构化处理_在Python中标记非结构化文本数据
  • 图像分类数据库_图像分类器-使用僧侣库对房屋房间类型进行分类
  • 利用PyCaret的力量
  • ai伪造论文实验数据_5篇有关AI培训数据的基本论文
  • 机器学习经典算法实践_服务机器学习算法的系统设计-不同环境下管道的最佳实践
  • css餐厅_餐厅的评分预测
  • 机器学习结构化学习模型_生产化机器学习模型
  • 人工智能已经迫在眉睫_创意计算机已经迫在眉睫
  • 合奏:机器学习中唯一(几乎)免费的午餐
  • 在Ubuntu 18.04上安装和使用Tesseract 4
  • pytorch机器学习_机器学习— PyTorch
  • 检测和语义分割_分割和对象检测-第1部分
  • ai人工智能编程_从人工智能动态编程:Q学习
  • 架构垂直伸缩和水平伸缩区别_简单的可伸缩图神经网络
  • yolo opencv_如何使用Yolo,SORT和Opencv跟踪足球运动员。
  • 人工智能的搭便车指南
  • 机器学习 对回归的评估_在机器学习回归问题中应使用哪种评估指标?
  • 可持久化数据结构加扫描线_结构化光扫描
  • 信号处理深度学习机器学习_机器学习和信号处理如何融合?
  • python 数组合并排重_并排深度学习:Julia vs Python
  • 强化学习 求解迷宫问题_使用天真强化学习的迷宫求解器
  • 朴素贝叶斯 半朴素贝叶斯_使用朴素贝叶斯和N-Gram的Twitter情绪分析
  • 自动填充数据新增测试数据_用测试数据填充员工数据库

mask rcnn实例分割_使用Mask-RCNN的实例分割相关推荐

  1. 语义分割和实例分割_一文读懂语义分割与实例分割

    以人工智能为导向的现代计算机视觉技术,在过去的十年中发生了巨大的变化.今天,它被广泛用于图像分类.人脸识别.物体检测.视频分析以及机器人及自动驾驶汽车中的图像处理等领域.图像分割技术是目前预测图像领域 ...

  2. mask rcnn算法原理图_基于MASK RCNN算法实现瑕疵图像识别(训练模型及应用)

    数据的准备其实是最花功夫和时间的,度过了上一个阶段后,就进入激动的模型训练阶段了,首先简要聊聊我对Mask RCNN算法的理解: MaskRCNN是何凯明大神基于FastRCNN的改进,2018年初在 ...

  3. python实现语义分割_如何用PyTorch进行语义分割?一文搞定

    很久没给大家带来教程资源啦. 正值PyTorch 1.7更新,那么我们这次便给大家带来一个PyTorch简单实用的教程资源:用PyTorch进行语义分割. 图源:stanford 该教程是基于2020 ...

  4. enet分割_论文阅读 | CVPR 2016 | 语义分割论文: ENet

    论文源址:https://arxiv.org/abs/1606.02147 tensorflow github: https://github.com/kwotsin/TensorFlow-ENet ...

  5. halcon粘连字符分割_机器视觉—字符识别之粘连字符分割识别

    粘连字符的分割有很多种方法: 第一种方法:利用阈值法提取联通区域,再利用形态学分离字符: 第二种方法:每个字符定义一个感兴趣区域: 第三种方法: 计算区域每列像素数目,由于不同字符之间连接部分非常狭窄 ...

  6. python人像精细分割_人像抠图 - 发丝级人像分割 - 照片人物特效 - 极链科技

    利用人工智能深度网络技术训练出的模型,可以模拟 Photoshop 一键完成人像抠图.可应用于证件照合成,人像照片虚化背景,照片背景替换,特效制作,弹幕隐身等多重功能. 请求参数(Body): { & ...

  7. 实例分割向:Mask R-CNN

    Abstract 我们展现了一个思想上很简单的.灵活的.一般的目标实例分割框架.我们的方法有效地实现了在一幅图上同时生成高质量的分割掩膜并检测目标的目的.这一方法称为,Mask R-CNN,它在Fas ...

  8. 【深度学习】Mask-RCNN 计算机视觉实例分割模型介绍 Mask分支

    论文:https://arxiv.org/pdf/1703.06870.pdf 视频:https://www.bilibili.com/video/BV1ZY411774T?spm_id_from=3 ...

  9. gan pytorch 实例_重新思考一阶段实例分割(Rethinking Single Shot Instance Segmentation)

    点击上方"CVer",选择加"星标"或"置顶" 重磅干货,第一时间送达 作者:谢恩泽 https://zhuanlan.zhihu.com/ ...

最新文章

  1. ctypealpha php_php ctype函数中文翻译和示例
  2. LeetCode 96不同的二叉搜索树95不同的二叉搜索树Ⅱ
  3. SpringBoot项目在Eclipse中实现打包发布
  4. 1.2 torch_数据预处理
  5. 机器视觉-halcon学习笔记1
  6. 【jQuery】手机验证码倒计时效果
  7. 3650m5设置u盘启动_系统重装必备神器,U盘如何制作启动盘?
  8. Java 10新特性
  9. select下拉框带模糊查询_如何实现参数级联查询
  10. Activiti5工作流实战-4
  11. Stream流的使用函数式接口
  12. ugmented reality(AR) equipment
  13. unity webPlayer
  14. 实用技巧 teamviewer高清显示
  15. Android上传图片的方式
  16. 好听的歌曲~~~推荐
  17. 【Windows 7中的凭据管理器的功能】
  18. Linux 学习资料
  19. java redis expire 1_redis 下key的过期时间详解 :expire
  20. 关于Office 365开发者订阅无法注册的说明

热门文章

  1. eclipse中如何将中文乱码的class文件改为可读
  2. SpringCloud的微服务网关:zuul(理论)
  3. ceph常用命令-pool相关命令
  4. Oracle索引或这类索引的分区处于不可用状态 查询
  5. 为什么从1970年1月1日开始
  6. MongoDB的数据逻辑结构
  7. Microsoft System Center Configuration Manager 2007 工作流中文版
  8. android落下动画,Android应用开发android 购物车小球掉落动画
  9. mysql 设置时区,【MySQL】修改时区设置
  10. Composer 本地路径加载 laravel-admin 扩展包