TACO数据集下载

TACO是一个用于垃圾检测的大型图像数据集,包含1500张图片和4784个box2D标注,涵盖28类和60种子类别的垃圾。数据集被分成15个batch,每个包含100张左右的图片及对应标注。使用该数据集需要引用相关论文。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Samples

图片

Overview

TACO是一个用于垃圾检测的图像数据集,包含从热带海滩到伦敦街头在不同环境下拍摄的垃圾的照片,共有1500张图像,4784个box2Db标注。其中垃圾大类可以分为28类,分别是

'Aluminium foil', 'Battery', 'Blister pack', 'Bottle', 'Bottle cap', 'Broken glass', 'Can', 'Carton', 'Cup', 'Food waste', 'Glass jar', 'Lid', 'Other plastic', 'Paper', 'Paper bag', 'Plastic bag & wrapper', 'Plastic container', 'Plastic glooves', 'Plastic utensils', 'Pop tab', 'Rope & strings', 'Scrap metal', 'Shoe', 'Squeezable tube', 'Straw', 'Styrofoam piece', 'Unlabeled litter', 'Cigarette'

子类可以分为60种,分别是

'Aluminium foil', 'Battery', 'Aluminium blister pack', 'Carded blister pack', 'Other plastic bottle', 'Clear plastic bottle', 'Glass bottle', 'Plastic bottle cap', 'Metal bottle cap', 'Broken glass', 'Food Can', 'Aerosol', 'Drink can', 'Toilet tube', 'Other carton', 'Egg carton', 'Drink carton', 'Corrugated carton', 'Meal carton', 'Pizza box', 'Paper cup', 'Disposable plastic cup', 'Foam cup', 'Glass cup', 'Other plastic cup', 'Food waste', 'Glass jar', 'Plastic lid', 'Metal lid', 'Other plastic', 'Magazine paper', 'Tissues', 'Wrapping paper', 'Normal paper', 'Paper bag', 'Plastified paper bag', 'Plastic film', 'Six pack rings', 'Garbage bag', 'Other plastic wrapper', 'Single-use carrier bag', 'Polypropylene bag', 'Crisp packet', 'Spread tub', 'Tupperware', 'Disposable food container', 'Foam food container', 'Other plastic container', 'Plastic glooves', 'Plastic utensils', 'Pop tab', 'Rope & strings', 'Scrap metal', 'Shoe', 'Squeezable tube', 'Plastic straw', 'Paper straw', 'Styrofoam piece', 'Unlabeled litter', 'Cigarette'

Data Explore

图片

数据集分为15个batch文件夹,每一个文件夹内含有100左右的垃圾图像以及一个annotation.json文件,文件读取后是一个字典,其键如下

dict_keys(['info', 'images', 'annotations', 'scene_annotations', 'licenses', 'categories', 'scene_categories'])

数据初始化

修改annotation.json所在的file_path路径,即可获得图片的box2D标签字典,其键、值分别为图片id,图片标签(可能含有多个标签)。键值为列表格式,其元素格式为[xmin,ymin,w,h,category]

import json

with open(file_path, encoding='utf-8') as f:    line = f.readline()    all = json.loads(line)
# 获取图片对应的idimg_id = {}for i in all["images"]:    if i["file_name"] not in img_id.keys():        img_id[i["file_name"]] = i["id"]# 获取标签id对应的类别category_id = {}for i in all["categories"]:    if i["id"] not in category_id.keys():        category_id[i["id"]] = i["name"]# 获取图片id对应的标签labels_dict = {}for i in all["annotations"]:    if i["image_id"] not in labels_dict.keys():        labels_dict[i["image_id"]] = []    bbox = i["bbox"]    cate_id = i["category_id"]    label = bbox + [category_id[cate_id]]    labels_dict[i["image_id"]].append(label)

Citation

If you use this dataset and API in a publication, please cite us using:  

@article{taco2020,
    title={TACO: Trash Annotations in Context for Litter Detection},
    author={Pedro F Proença and Pedro Simões},
    journal={arXiv preprint arXiv:2003.06975},
    year={2020}
}

关注公众号,后台回复 taco 即可获得数据集

图片

TACO(Trash Annotations in Context)数据集是一个用于垃圾物体检测和分类的数据集。它包含了超过15000张图像,其中包含了40个不同类别的垃圾物体。使用TACO数据集可以帮助我们训练模型来自动检测和分类垃圾物体。 要使用TACO数据集,你可以按照以下步骤进行: 1. 下载数据集:你可以从TACO数据集的官方网站(https://github.com/pedropro/TACO)上下载数据集数据集包括图像和相应的标注文件。 2. 数据预处理:下载完成后,你需要对数据进行预处理。这包括将图像和标注文件放置在正确的文件夹中,并确保文件名和标注文件中的图像路径匹配。 3. 数据探索:在开始训练之前,你可以先对数据进行探索,了解图像和标注的内容。可以使用图像处理库(如OpenCV)加载图像,并根据标注文件中的坐标信息绘制边界框。 4. 数据划分:为了训练和评估模型,你需要将数据集划分为训练集、验证集和测试集。通常,你可以将数据集按照一定比例划分,例如80%用于训练,10%用于验证,10%用于测试。 5. 模型训练:使用划分好的训练集进行模型训练。你可以选择使用深度学习框架(如TensorFlow、PyTorch)来实现垃圾物体检测和分类模型。可以使用已有的模型架构(如Faster R-CNN、YOLO)或自定义模型。 6. 模型评估:使用验证集对训练好的模型进行评估。通过计算准确率、召回率、F1分数等指标来评估模型的性能。 7. 模型应用:在模型训练和评估完成后,你可以使用测试集来测试模型的泛化能力。将模型应用于新的图像数据,检测和分类垃圾物体。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

田土豆

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值