caffe caffe2_Caffe2-概述

caffe caffe2

Caffe2-概述 (Caffe2 - Overview)



Advertisements
广告

Now, as you have got some insights into deep learning, let us get an overview of what is Caffe.

现在,当您对深度学习有了一些了解时,让我们大致了解一下Caffe。

训练CNN (Training a CNN)

Let us learn the process for training a CNN for classifying images. The process consists of the following steps −

让我们学习训练CNN对图像进行分类的过程。 该过程包括以下步骤-

  • Data Preparation − In this step, we center-crop the images and resize them so that all images for training and testing would be of the same size. This is usually done by running a small Python script on the image data.

    数据准备 -在此步骤中,我们对图像进行中心裁剪并调整其大小,以便用于训练和测试的所有图像都具有相同的大小。 这通常是通过在图像数据上运行一个小的Python脚本来完成的。

  • Model Definition − In this step, we define a CNN architecture. The configuration is stored in .pb (protobuf) file. A typical CNN architecture is shown in figure below.

    模型定义 -在这一步,我们定义一个CNN体系结构。 配置存储在.pb(protobuf)文件中。 下图显示了典型的CNN架构。

  • Solver Definition − We define the solver configuration file. Solver does the model optimization.

    求解器定义 -我们定义求解器配置文件。 求解器进行模型优化。

  • Model Training − We use the built-in Caffe utility to train the model. The training may take a considerable amount of time and CPU usage. After the training is completed, Caffe stores the model in a file, which can later on be used on test data and final deployment for predictions.

    模型训练 -我们使用内置的Caffe实用程序来训练模型。 培训可能会花费大量时间和CPU使用率。 训练完成后,Caffe将模型存储在文件中,以后可用于测试数据和最终部署以进行预测。

caffe caffe2_Caffe2-概述

Caffe2的新增功能 (What’s New in Caffe2)

In Caffe2, you would find many ready-to-use pre-trained models and also leverage the community contributions of new models and algorithms quite frequently. The models that you create can scale up easily using the GPU power in the cloud and also can be brought down to the use of masses on mobile with its cross-platform libraries.

在Caffe2中,您会发现许多现成的预训练模型,并且还经常利用新模型和算法对社区的贡献。 您创建的模型可以使用云中的GPU功能轻松扩展,也可以归因于其跨平台库在移动设备上的大量使用。

The improvements made in Caffe2 over Caffe may be summarized as follows −

与Caffe相比,Caffe2所做的改进可总结如下-

  • Mobile deployment

    移动部署
  • New hardware support

    新硬件支持
  • Support for large-scale distributed training

    支持大规模的分布式培训
  • Quantized computation

    量化计算
  • Stress tested on Facebook

    在Facebook上进行压力测试

预训练模型演示 (Pretrained Model Demo)

The Berkeley Vision and Learning Center (BVLC) site provides demos of their pre- trained networks. One such network for image classification is available on the link stated herewith https://caffe2.ai/docs/learn-more#null__caffe-neural-network-for-image-classification and is depicted in the screenshot below.

伯克利视觉与学习中心(BVLC)站点提供了其预训练网络的演示。 可以在https://caffe2.ai/docs/learn-more#null__caffe-neural-network-for-image-classification所述的链接上找到一种此类图像分类网络,并在下面的屏幕快照中进行了描述。

caffe caffe2_Caffe2-概述

In the screenshot, the image of a dog is classified and labelled with its prediction accuracy. It also says that it took just 0.068 seconds to classify the image. You may try an image of your own choice by specifying the image URL or uploading the image itself in the options given at the bottom of the screen.

在屏幕截图中,对狗的图像进行了分类并以其预测准确性进行了标记。 它还说,仅需0.068秒即可对图像进行分类。 您可以通过指定图像网址或在屏幕底部提供的选项中上传图像本身来尝试自己选择的图像。

Advertisements
广告

翻译自: https://www.tutorialspoint.com/caffe2/caffe2_overview.htm

caffe caffe2

相关文章: