nateraw/auto-exp-2
收藏Hugging Face2021-07-13 更新2024-03-04 收录
下载链接:
https://hf-mirror.com/datasets/nateraw/auto-exp-2
下载链接
链接失效反馈官方服务:
资源简介:
这是一个用于图像分类任务的数据集,用户可以通过HuggingFace的`datasets`库加载该数据集,并对图像进行预处理。
---
任务类别:
- 其他
任务子类型:
- 其他图像分类
- 图像分类
标签:
- 自动生成
- 图像分类
---
# nateraw/auto-exp-2 图像分类数据集
## 使用方法
python
from PIL import Image
from datasets import load_dataset
def pil_loader(path: str):
with open(path, 'rb') as f:
im = Image.open(f)
return im.convert('RGB')
def image_loader(example_batch):
example_batch['image'] = [
pil_loader(f) for f in example_batch['file']
]
return example_batch
ds = load_dataset('nateraw/auto-exp-2')
ds = ds.with_transform(image_loader)
提供机构:
nateraw
原始信息汇总
数据集概述
数据集名称
nateraw/auto-exp-2
数据集类型
Image Classification Dataset
任务类别
- other
- image-classification
任务ID
- other-image-classification
- image-classification
标签
- auto-generated
- image-classification
使用示例
python from PIL import Image from datasets import load_dataset
def pil_loader(path: str): with open(path, rb) as f: im = Image.open(f) return im.convert(RGB)
def image_loader(example_batch): example_batch[image] = [ pil_loader(f) for f in example_batch[file] ] return example_batch
ds = load_dataset(nateraw/auto-exp-2) ds = ds.with_transform(image_loader)



