{"id":1704,"date":"2025-05-10T22:46:48","date_gmt":"2025-05-10T13:46:48","guid":{"rendered":"http:\/\/www.ecobioinfo.com\/?p=1704"},"modified":"2025-05-10T22:51:26","modified_gmt":"2025-05-10T13:51:26","slug":"%e6%b7%b1%e5%b1%a4%e5%ad%a6%e7%bf%92%e3%80%80tensorflow-object-detection-api-%e8%bb%a2%e7%a7%bb%e5%ad%a6%e7%bf%92","status":"publish","type":"post","link":"https:\/\/www.ecobioinfo.com\/?p=1704","title":{"rendered":"\u6df1\u5c64\u5b66\u7fd2\u3000TensorFlow Object Detection API \u8ee2\u79fb\u5b66\u7fd2"},"content":{"rendered":"<p>Object Detection API \u3092\u4f7f\u7528\u3057\u3066\u65e2\u5b58\u306e\u30e2\u30c7\u30eb\u3092\u5229\u7528\u3057\u3066\u81ea\u524d\u306e\u30c7\u30fc\u30bf\u3092\u8ee2\u79fb\u5b66\u7fd2\u3057\u3066\u307f\u307e\u3057\u305f\u3002<br \/>\n\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u306f\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30ebVoTT\u3067\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059\u304c\u3001\u30d7\u30ed\u30b0\u30e9\u30e0\u3067JSON\u30d5\u30a1\u30a4\u30eb\u3068\u753b\u50cf\u3092\u76f4\u63a5\u8aad\u307f\u8fbc\u307fAPI\u306b\u30d1\u30e9\u30e1\u30fc\u30bf\u3068\u3057\u3066\u6e21\u3059\u65b9\u5f0f\u306b\u3057\u307e\u3057\u305f\u3002\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30eb\u306b\u5fdc\u3058\u305f\u30d1\u30c3\u30b1\u30fc\u30b8\u3082\u3042\u308a\u307e\u3059\u304c\u4eca\u56de\u306f\u52c9\u5f37\u7528\u306e\u30b5\u30f3\u30d7\u30eb\u306a\u306e\u3067\u57fa\u672c\u7684\u306aAPI\u3067\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>(1)\u6982\u8981<\/p>\n<p>\u2460\u5b66\u7fd2\u7528\u30d7\u30ed\u30b0\u30e9\u30e0<br \/>\n\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30eb Vott \u3067\u4f5c\u6210\u3055\u308c\u305f\u30c7\u30fc\u30bf\u306e\u3046\u3061\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u5b9a\u7fa9\u3055\u308c\u305f\u3082\u306e\u3092\u5bfe\u8c61\u3068\u3057\u3001\u5bfe\u8c61\u3068\u306a\u308b\u30bf\u30b0\u30fb\u30e9\u30d9\u30eb\u306f\u30d7\u30ed\u30b0\u30e9\u30e0\u4e2d\u3067\u5b9a\u7fa9\u3057\u307e\u3059\u3002<br \/>\n\u6700\u521d\u306b\u5b66\u7fd2\u7528\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u306e\u5165\u3063\u305f\u4f5c\u696d\u7528\u30d5\u30a9\u30eb\u30c0\u9078\u629e\u3059\u308b\u30a6\u30a4\u30f3\u30c9\u30a6\u3092\u958b\u304d\u307e\u3059\u3002<br \/>\n\u4eca\u56de\u306f\u307e\u305a\u30cd\u30b3(\u30e9\u30d9\u30eb\u306f\u30ed\u30fc\u30de\u5b57\u3067&#8221;neko&#8221;)\u3068\u30a6\u30b5\u30ae(&#8220;usagi&#8221;)\u3092\u5b66\u7fd2\u3055\u305b\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<p>\u30d5\u30a9\u30eb\u30c0\u5185\u306b\u306f\u4ee5\u4e0b\u306e\u30b5\u30d6\u30d5\u30a9\u30eb\u30c0\u304c\u5b58\u5728\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<br \/>\ntrain  \u5b66\u7fd2\u7528\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\uff08\u4eca\u56de\u306fVoTT\u3067\u4f5c\u6210\uff09<br \/>\nwork   \u4f5c\u696d\u7528\u3001\u78ba\u8a8d\u7528\u753b\u50cf\u304c\u51fa\u529b\u3055\u308c\u308b<\/p>\n<p>\u5143\u3068\u306a\u308b\u5b66\u7fd2\u6e08\u307f\u30e2\u30c7\u30eb\u306f\u3001ssd_resnet50_v1_fpn_640x640_coco17_tpu-8\u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\nhttp:\/\/download.tensorflow.org\/models\/object_detection\/tf2\/20200711\/ssd_resnet50_v1_fpn_640x640_coco17_tpu-8.tar.gz<\/p>\n<p>\u2461\u30c6\u30b9\u30c8\u30d7\u30ed\u30b0\u30e9\u30e0<br \/>\n\u5b66\u7fd2\u7d50\u679c\u3092\u30c6\u30b9\u30c8\u3059\u308b\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u3059\u3002<br \/>\n\u5bfe\u8c61\u3068\u306a\u308b\u30bf\u30b0\u30fb\u30e9\u30d9\u30eb\u306f\u5b66\u7fd2\u7528\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u540c\u3058\uff08\u4eca\u56de\u306f&#8221;neko&#8221;\u3068&#8221;usagi&#8221;\uff09\u3067\u3042\u308b\u3053\u3068\u3092\u524d\u63d0\u3068\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n\u4fdd\u5b58\u3057\u305f\u5b66\u7fd2\u7d50\u679c\u3068\u30c6\u30b9\u30c8\u7528\u30c7\u30fc\u30bf\u306e\u5165\u3063\u305f\u4f5c\u696d\u7528\u30d5\u30a9\u30eb\u30c0\u9078\u629e\u3059\u308b\u30a6\u30a4\u30f3\u30c9\u30a6\u3092\u958b\u304d\u307e\u3059\u3002<\/p>\n<p>\u30d5\u30a9\u30eb\u30c0\u5185\u306b\u306f\u4ee5\u4e0b\u306e\u30b5\u30d6\u30d5\u30a9\u30eb\u30c0\u304c\u5b58\u5728\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<br \/>\nckpt   \u5b66\u7fd2\u7528\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u4fdd\u5b58\u3055\u308c\u305f\u5b66\u7fd2\u6e08\u307f\u306e\u30c1\u30a7\u30c3\u30af\u30dd\u30a4\u30f3\u30c8\u7b49<br \/>\ntest   \u5b66\u7fd2\u7d50\u679c\u3092\u30c6\u30b9\u30c8\u3059\u308b\u753b\u50cf\u7528<br \/>\nresult \u30c6\u30b9\u30c8\u7d50\u679c\u51fa\u529b<\/p>\n<p>(2)\u5b66\u7fd2\u7528\u30c7\u30fc\u30bf<\/p>\n<p>\u5b66\u7fd2\u7528\u30c7\u30fc\u30bf\u3068\u5b9f\u884c\u7d50\u679c\u3092\u307e\u3068\u3081\u305fzip\u30d5\u30a1\u30a4\u30eb\u3067\u3059\u3002<br \/>\n<a href=\"https:\/\/www.ecobioinfo.com\/usr\/ai\/od\/\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u691c\u51fa_\u8ee2\u79fb\u5b66\u7fd2.zip\">\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u691c\u51fa_\u8ee2\u79fb\u5b66\u7fd2.zip<\/a>(200MB)<br \/>\n\uff08\u5b66\u7fd2\u7528\u306e\u753b\u50cf\u30d5\u30a1\u30a4\u30eb\u3068\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u306f train \u30d5\u30a9\u30eb\u30c0\u306b\u5165\u3063\u3066\u3044\u307e\u3059\u3002\u30e9\u30d9\u30eb\u306f\u65e5\u672c\u8a9e\u30ed\u30fc\u30de\u5b57\u3067\u30cd\u30b3\u306f&#8221;neko&#8221;\u3001\u30a6\u30b5\u30ae\u306f&#8221;usagi&#8221;\u3068\u3057\u3066\u3044\u307e\u3059\u3002\uff09<\/p>\n<p>(3)\u30d7\u30ed\u30b0\u30e9\u30e0<br \/>\n\u300c<a href=\"https:\/\/www.ecobioinfo.com\/?p=1590\">\u6df1\u5c64\u5b66\u7fd2\u3000Ubuntu 20.04 \u306b TensorFlow Object Detection API \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/a>\u300d\u3067\u69cb\u7bc9\u3057\u305f\u958b\u767a\u74b0\u5883\u3068\u52d5\u4f5c\u74b0\u5883\u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>Python\u30d7\u30ed\u30b0\u30e9\u30e0\uff08\u30c6\u30ad\u30b9\u30c8\u30d5\u30a1\u30a4\u30eb UTF-8\uff09<\/p>\n<p>\u2460\u5b66\u7fd2\u7528\u30d7\u30ed\u30b0\u30e9\u30e0<br \/>\n<a href=\"https:\/\/www.ecobioinfo.com\/usr\/ai\/od\/ObjectDetectionLearn.py\">ObjectDetectionLearn.py<\/a><\/p>\n<p>\u2461\u30c6\u30b9\u30c8\u30d7\u30ed\u30b0\u30e9\u30e0<br \/>\n<a href=\"https:\/\/www.ecobioinfo.com\/usr\/ai\/od\/ObjectDetectionTest.py\">ObjectDetectionTest.py<\/a><\/p>\n<p>(4)\u89e3\u8aac<br \/>\n\u5b66\u7fd2\u7528\u30d7\u30ed\u30b0\u30e9\u30e0 ObjectDetectionLearn.py \u3067\u306f\u3001\u95a2\u6570 selectAnnotationFiles, getJsonAnnotation\u3067\u3001<br \/>\n\u30d5\u30a9\u30eb\u30c0\u9078\u629e\u3068\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3JSON\u30d5\u30a1\u30a4\u30eb\u306e\u4e00\u89a7\u8aad\u8fbc\u3092\u884c\u3044\u307e\u3059\u3002<br \/>\n\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u306f\u9078\u629e\u3055\u308c\u305f\u30d5\u30a9\u30eb\u30c0\u914d\u4e0b\u306etrain\u30d5\u30a9\u30eb\u30c0\u3042\u308b\u3053\u3068\u3092\u524d\u63d0\u3068\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\nVott\u306e\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u306e\u3046\u3061JSON\u30d5\u30a1\u30a4\u30eb\u306e\u30bf\u30b0\u3068\u5ea7\u6a19\uff08&#8221;regions&#8221;\u306e&#8221;tags&#8221;,&#8221;boundingBox&#8221;\uff09\u3092\u5229\u7528\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n&#8220;tags&#8221;\u304c\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u5148\u982d\u306b\u3042\u308b labelNames\u914d\u5217\u3067\u5b9a\u7fa9\u3055\u308c\u305f\u540d\u524d\u3068\u4e00\u81f4\u3059\u308b\u30c7\u30fc\u30bf\u306e\u307f\u62bd\u51fa\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n\u8aad\u307f\u8fbc\u3093\u3060\u30c7\u30fc\u30bf\u3092TensorFlow Object Detection API \u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u5f62\u5f0f\u306b\u5909\u63db\u3057\u3066\u5229\u7528\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>(5)\u30c6\u30b9\u30c8\u7d50\u679c<\/p>\n<p>\u30c6\u30b9\u30c8\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u5b9f\u884c\u3057\u305f\u7d50\u679c\u306e\u4e00\u90e8\u3067\u3059\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0001-285x300.jpg\" alt=\"result_test0001\" width=\"285\" height=\"300\" class=\"alignnone size-medium wp-image-1706\" srcset=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0001-285x300.jpg 285w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0001-768x809.jpg 768w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0001-972x1024.jpg 972w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0001.jpg 1014w\" sizes=\"auto, (max-width: 285px) 100vw, 285px\" \/><br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0010-300x258.jpg\" alt=\"result_test0010\" width=\"300\" height=\"258\" class=\"alignnone size-medium wp-image-1707\" srcset=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0010-300x258.jpg 300w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0010-768x659.jpg 768w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0010-1024x879.jpg 1024w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0010.jpg 1916w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_train00091_640_2_B_1000-1-300x300.jpg\" alt=\"result_train00091_640_2_B_1000\" width=\"300\" height=\"300\" class=\"alignnone size-medium wp-image-1711\" srcset=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_train00091_640_2_B_1000-1-300x300.jpg 300w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_train00091_640_2_B_1000-1-150x150.jpg 150w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_train00091_640_2_B_1000-1-200x200.jpg 200w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_train00091_640_2_B_1000-1.jpg 640w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0020-291x300.jpg\" alt=\"result_test0020\" width=\"291\" height=\"300\" class=\"alignnone size-medium wp-image-1708\" srcset=\"https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0020-291x300.jpg 291w, https:\/\/www.ecobioinfo.com\/wordpress\/wp-content\/uploads\/2025\/05\/result_test0020.jpg 589w\" sizes=\"auto, (max-width: 291px) 100vw, 291px\" \/><\/p>\n<p>\u307e\u3060\u5b66\u7fd2\u7528\u306e\u30c7\u30fc\u30bf\u304c\u5c11\u306a\u304f\u7cbe\u5ea6\u306f\u4f4e\u3044\u3067\u3059\u304c\u3042\u308b\u7a0b\u5ea6\u306e\u691c\u51fa\u306f\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f\u3002<br \/>\n\u4eca\u56de\u306f\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30ebVoTT\u3092\u60f3\u5b9a\u3057\u3066\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u4f5c\u308a\u307e\u3057\u305f\u304c\u3001<br \/>\n\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u8aad\u307f\u8fbc\u307f\u90e8\u5206\u5909\u66f4\u3059\u308c\u3070\u5225\u306e\u30c7\u30fc\u30bf\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u306b\u3082\u5bfe\u5fdc\u3059\u308b\u30d7\u30ed\u30b0\u30e9\u30e0\u3082\u4f5c\u6210\u3067\u304d\u308b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\uff082025\/05\/10 Shin Onda\uff09<\/p>\n<p>\u53c2\u8003\uff1a<br \/>\nhttps:\/\/qiita.com\/john-rocky\/items\/6ad6aeed65fa71f92e1b<\/p>\n","protected":false},"excerpt":{"rendered":"Object Detection API \u3092\u4f7f\u7528\u3057\u3066\u65e2\u5b58\u306e\u30e2\u30c7\u30eb\u3092\u5229\u7528\u3057\u3066\u81ea\u524d\u306e\u30c7\u30fc\u30bf\u3092\u8ee2\u79fb\u5b66\u7fd2\u3057\u3066\u307f\u307e\u3057\u305f\u3002 \u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u306f\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30ebVoTT\u3067\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059\u304c\u3001\u30d7\u30ed\u30b0\u30e9\u30e0\u3067JSON\u30d5\u30a1\u30a4\u30eb\u3068\u753b\u50cf\u3092\u76f4 &#8230;","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-1704","post","type-post","status-publish","format-standard","hentry","category-ai_ecobio"],"_links":{"self":[{"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=\/wp\/v2\/posts\/1704","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1704"}],"version-history":[{"count":16,"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=\/wp\/v2\/posts\/1704\/revisions"}],"predecessor-version":[{"id":1726,"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=\/wp\/v2\/posts\/1704\/revisions\/1726"}],"wp:attachment":[{"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1704"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1704"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ecobioinfo.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1704"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}