Clarifai 2.3.2

Clarifai 2.3.2

测试已测试
语言编程语言 Obj-CObjective C
许可证 自定义
发布最后发布2017年8月

John SloanDalmo Cirne维护。



Clarifai 2.3.2

  • John Sloan 和 Jack Rogers

Clarifai Objective-C 客户端

一个用于 iOS 应用并使用 Clarifai V2 API 的客户端。

入门

  1. 创建一个新的 XCode 项目,或者使用当前的一个。

  2. 将 Clarifai 添加到您的 Podfile 中并生成工作空间。

    pod 'Clarifai'
    
    pod install
    
  3. 导入 ClarifaiApp.h 和您需要的其他类。

    #import ClarifaiApp.h
    
  4. 前往 developer.clarifai.com/applications,点击您的应用程序,然后复制您的应用 API 密钥(如果您还没有帐户或应用程序,您需要先注册)。

  5. 在您的项目中创建您的 Clarifai 应用。

    ClarifaiApp *app = [[ClarifaiApp alloc] initWithApiKey:@""];
    
  6. 就是这样!探索 API 文档和指南

注意-要使用 Swift 中的 Clarifai,请确保在 podfile 中添加 use_frameworks! 并在任意的 swift 文件中使用: import Clarifai

文档

最新文档可以在 Cocoadocs 上找到 这里

示例项目

仓库中包含一个简单的演示,以帮助您入门。要构建此项目,您需要 Xcode 8CocoaPods。要构建和运行:

  1. 在 Example 文件夹中安装依赖项并生成工作空间。

    pod install
    
  2. 在 Xcode 中打开工作空间。

    open Clarifai.xcworkspace
    
  3. 前往 developer.clarifai.com/applications,点击您的应用程序,然后复制您的应用 API 密钥(如果您还没有帐户或应用程序,您需要先注册)。

    将您的 API 密钥添加到 RecognitionViewController.m 中的 recognizeImage 方法。

  4. 在工具栏中按“播放”按钮来构建、安装和运行应用程序。