COCO 2014 データセットのダウンロード(Windows 上)

Windows での COCO 2014 データセット のダウンロードと展開の手順を説明する.

COCO (Common Object in Context) データセット

COCO(Common Object in Context)データセットは,物体検出やセグメンテーション,キーポイント検出,姿勢推定,画像分類,キャプショニング等の多様なタスクに対応可能な画像データセットとして,2014年にMicrosoftにより公開された.これは,人間や自動車,家具,食品等,多岐にわたるカテゴリのオブジェクトを含む数十万枚以上の画像から構成され,それぞれの画像は,80種類のカテゴリに対応する形でアノテーションが施されている. COCO は次の URL で公開されているデータセット(オープンデータ)である.

URL: https://cocodataset.org/

COCO は,以下の特徴がある.

COCO の 80 のクラスのラベルは次の通りである.

['person', 'bicycle', 'car', 'motorcycle', 'airplane', 'bus', 'train', 'truck', 'boat', 'traffic light', 'fire hydrant', 'stop sign', 'parking meter', 'bench', 'bird', 'cat', 'dog', 'horse', 'sheep', 'cow', 'elephant', 'bear', 'zebra', 'giraffe', 'backpack', 'umbrella', 'handbag', 'tie', 'suitcase', 'frisbee', 'skis', 'snowboard', 'sports ball', 'kite', 'baseball bat', 'baseball glove', 'skateboard', 'surfboard', 'tennis racket', 'bottle', 'wine glass', 'cup', 'fork', 'knife', 'spoon', 'bowl', 'banana', 'apple', 'sandwich', 'orange', 'broccoli', 'carrot', 'hot dog', 'pizza', 'donut', 'cake', 'chair', 'couch', 'potted plant', 'bed', 'dining table', 'toilet', 'tv', 'laptop', 'mouse', 'remote', 'keyboard', 'cell phone', 'microwave', 'oven', 'toaster', 'sink', 'refrigerator', 'book', 'clock', 'vase', 'scissors', 'teddy bear', 'hair drier', 'toothbrush']

文献

Tsung-Yi Lin, Michael Maire, Serge Belongie, Lubomir Bourdev, Ross Girshick, James Hays, Pietro Perona, Deva Ramanan, C. Lawrence Zitnick, Piotr Dollr, Microsoft COCO: Common Objects in Context, CoRR, abs/1405.0312, 2014.

https://arxiv.org/pdf/1405.0312v3.pdf

サイト内の関連ページ

COCO 2017 データセットのダウンロードとカテゴリ情報や画像情報の確認(Windows 上): 別ページ »で説明

関連する外部ページ

ダウンロード手順

  1. 7-Zip のインストール(Windows 上)

    7-Zipは,ファイル圧縮・展開(解凍)ツール

    1. Windows で,コマンドプロンプト管理者権限で起動する(例:Windowsキーを押し,「cmd」と入力し,「管理者として実行」を選択)
    2. 次のコマンドを実行

      次のコマンドは,7-Zip圧縮・展開(解凍)ツールをインストールするものである.

      winget install --scope machine 7zip.7zip
      powershell -command "$oldpath = [System.Environment]::GetEnvironmentVariable(\"Path\", \"Machine\"); $oldpath += \";c:\Program Files\7-Zip\"; [System.Environment]::SetEnvironmentVariable(\"Path\", $oldpath, \"Machine\")"
      

    関連する外部ページ

  2. COCO データセットの公式ページから, 2014 Train images, 2014 Val images, 2014 Train/Val annotations をダウンロード

    コマンドプロンプトを管理者として開き ダウンロードと展開のため,次のコマンドを実行

    cd /d c:%HOMEPATH%
    mkdir coco2014
    mkdir coco2014\coco
    cd /d c:%HOMEPATH%\coco2014
    ECHO アノテーションファイルのダウンロード
    curl -O http://images.cocodataset.org/annotations/annotations_trainval2014.zip
    ECHO 学習用画像データのダウンロード
    curl -O http://images.cocodataset.org/zips/train2014.zip
    ECHO 検証用画像データのダウンロード
    curl -O http://images.cocodataset.org/zips/val2014.zip
    #
    cd /d c:%HOMEPATH%\coco2014\coco
    "c:\Program Files\7-Zip\7z.exe" x ..\annotations_trainval2014.zip
    #
    cd /d c:%HOMEPATH%\coco2014\coco\images
    "c:\Program Files\7-Zip\7z.exe" x ..\..\train2014.zip
    "c:\Program Files\7-Zip\7z.exe" x ..\..\val2014.zip
    
  3. ファイルの配置は次のようになる.(確認中)
    ├── images
    │   └── ...
    ├── annotations
    │   └── ...
    └── imageLists
        ├── all.txt
        ├── test.txt
        └── train.txt