Flickr API - 自动标记未显示在flickr.tags.getListPhoto返回的列表中

时间:2015-07-07 16:40:40

标签: tags flickr

Flickr的代码API似乎无法返回给定照片的所有代码。

Flickr开始在一两个月前自动标记照片。因此,现在可以使用由用户添加的零个或多个用户标记标记给定照片,并通过Flickr算法添加零个或多个计算机标记。

Flickr的API提供了用于检索标签的flickr.tags.getListPhoto方法。但它似乎只返回用户标签。 https://www.flickr.com/services/api/explore/flickr.tags.getListPhoto

返回的标签(用户标签)都包含machine_tag =" 0"对,所以我假设有一种获取机器标签的方法,至少计划如果没有实现。这是getListPhoto输出的JSON示例:

{ "photo": { "id": "18791800953", 
    "tags": { 
      "tag": [
        { "id": "126228644-18791800953-3318", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "downtown", "_content": "downtown", "machine_tag": 0 },
        { "id": "126228644-18791800953-1306", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "skyscraper", "_content": "skyscraper", "machine_tag": 0 },
        { "id": "126228644-18791800953-553", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "building", "_content": "building", "machine_tag": 0 },
        { "id": "126228644-18791800953-16588", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "high-rise", "_content": "highrise", "machine_tag": 0 },
        { "id": "126228644-18791800953-4603", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "Las Vegas", "_content": "lasvegas", "machine_tag": 0 },
        { "id": "126228644-18791800953-6215", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "Nevada", "_content": "nevada", "machine_tag": 0 },
        { "id": "126228644-18791800953-291", "author": "126251698@N03", "authorname": "jorgemolina37", "raw": "urban", "_content": "urban", "machine_tag": 0 }
      ] } }, "stat": "ok" }

除了上述用户标签之外,该图像还具有机器标签,例如" blackandwhite","户外"和"单色" JSON中未返回的内容:https://www.flickr.com/photos/miamiboy/18791800953/

我还没有在文档中看到任何讨论机器标签的内容(甚至提到它们),大概是因为它们是新的。

我错过了什么吗?我错过了某个参数或其他方法吗?或者机器标签是不可用的(但是?)?

1 个答案:

答案 0 :(得分:0)

getPhotos服务允许您指定要返回的“额外内容”。您可以将'machine_tags'指定为其中一个附加内容:https://www.flickr.com/services/api/explore/flickr.photosets.getPhotos