1

我正在探索 IBM Watson Visual Recognition 服务,当我使用“ black-dog ”(即 black-dog_positive_example)之类的类名创建分类器时,当我对图像进行分类时,这个类名稍后会返回为“ black_dog ”(用下划线替换dash )使用/v3/classify端点。

但是当我检索分类器详细信息时,/v3/classifiers/{classifier_id}该类被正确列为“黑狗”。

所以,我的结果GET /v3/classifiers/{classifier_id}是:

{
    "classifier_id": "dog_561932172",
    "name": "dog",
    "owner": "xxxxxxxx-xxx-xxx-xxx-xxxxxxxxxxxx",
    "status": "ready",
    "created": "2016-07-30T22:06:39.327Z",
    "classes": [
        {"class": "black-dog"}
    ]
}

虽然我的结果GET /v3/classify

{
  "custom_classes": 1,
  "images": [
    {
      "classifiers": [
        {
          "classes": [
            {
              "class": "black_dog",
              "score": 0.546941
            }
          ],
          "classifier_id": "dog_561932172",
          "name": "dog"
        }
      ],
      "image": "20160620_142113.jpg"
    }
  ],
  "images_processed": 1
}

那么这是预期的还是缺陷?我应该避免在类名中使用“-”吗?类名的值还有其他规则吗?

4

2 回答 2

2

Update:

Updated via Matt's answer.


Talked with the support team, and it is indeed a bug. Here was their response:

Thanks for pointing this out. I reproduced and confirmed with dev team, and we do consider this inconsistency between the listed class name and the class name in results is a bug.

And this is because the class name been altered in result from what is submitted.

I have raised a ticket for tracking on this. According to developer, currently the output can be either a document to list the substitutions or find a way to remove them.

...so they are currently working on it.

于 2016-08-02T16:20:25.123 回答
1

类名的值还有其他规则吗?

我们进行了更新,该服务不应再修改任何类名,例如用下划线替换破折号。相反,它不会接受具有以下任何字符的类名用于自定义学习:\,|,*,{,},$,-,/,',`,

(您会看到破折号包含在其中。)空格是可以接受的。此更新不具有追溯性,因此在培训期间修改的现有类名不受影响。

于 2016-09-06T23:14:36.167 回答