OUTLAW83's picture
Duplicate from gwenxin/pills_inside_bottles
2126aee verified
---
language:
- en
license: cc-by-4.0
license_link: https://creativecommons.org/licenses/by/4.0/
tags:
- image-classification
pretty_name: pills-inside-bottles
size_categories:
- "10K<n<100K"
dataset_info:
features:
- name: image
dtype: image
- name: ndc
dtype: string
- name: id
dtype: string
splits:
- name: train
num_examples: 8393
- name: test
num_examples: 2786
- name: validation
num_examples: 2776
download_size: 13955
dataset_size: 13955
---
# Dataset Card for Pills Inside Bottles
The dataset contains 13,955 imgaes of pills inside medication bottles, their National Drug Code (NDC), and image id.
## Dataset Details
### Dataset Description
The dataset contains 13,955 imgaes of pills inside medication bottles, which are from a top down view. They are labeled with 20 distinct National Drug Code (NDC) and each image is associated with an image id. The dataset is split into train, test, and validation sets.
- **License:** [cc-by-4.0](https://creativecommons.org/licenses/by/4.0/)
### Dataset Sources
- **Homepage:** [Images of pills inside medication bottles dataset](https://deepblue.lib.umich.edu/data/concern/data_sets/6d56zw997#read_me_display)
- **Paper:** [Performance evaluation of a prescription medication image classification model: an observational cohort](https://www.nature.com/articles/s41746-021-00483-8)
## Uses
### Direct Use
The dataset can be used to train image classification models, which might be helpful for identifying pills automatically to increase efficiency and reduce dispensing error of pills in pharmacy.
### Example Use Case
Here is a link to an [example use case](https://colab.research.google.com/drive/1UPaAnVacx3ZpOy_koWFwWIluhVZYOdhT?usp=sharing) of this dataset, which trained supervised models to predict the national drug code for each image. The highest accuracy obtained is about 97% using EfficientNetV2M as the pre-train model and Support Vector Machines as the supervised learning algorithm.
## Dataset Structure
### Data Instances
Each data instance contains the following features: _image_, _ndc_, and _id_.
An example from the train set looks like the following:
```
{'image': <PIL.JpegImagePlugin.JpegImageFile image mode=RGB size=1284x960>,
'ndc': '29159',
'id': '00378-3855'}
```
### Data Fields
- 'image': a image of pills inside a medication bottle
- 'ndc': National Drug Code
- 'id': unique image id
### Data Splits
The dataset has 3 splits: _train_, _validation_, and _test_. The splits contain disjoint sets of images as well as their corresponding NDCs and IDs. The following table contains the number of images in each split and the percentages.
| Dataset Split | Number of Instances in Split | Percent |
| ------------- | ---------------------------- | ------------- |
| Train | 8,393 | 60.1% |
| Validation | 2,786 | 20.0% |
| Test | 2,776 | 19.9% |
## Dataset Creation
### Curation Rationale
The data is collected for training image classification model to facillitate work in pharmacy.
### Source Data
#### Data Collection and Processing
The data is collected by a group of researchers, including Lester, C. A., Al Kontar, R., and Chen, Q., whose paper, "Performance Evaluation of a Prescription Medication Image
Classification Model: An Observational Cohort", is published in 2022.
#### Who are the source data producers?
According to Lester et. al, the dataset is produced by a commercial medication dispensing robot used at a mail-order pharmacy from a top-down view (Lester et. al, 6).
## Bias, Risks, and Limitations
The researchers of the original paper only released part of their data. Therefore, the model performance might be influenced negatively due to insufficient training data.
## Citation
**BibTeX:**
```
@InProceedings{University of Michigan - Deep Blue Data,
title = {Images of pills inside medication bottles dataset},
author={Lester, C. A., Al Kontar, R., Chen, Q.},
year={2022}
}
```
## More Information
This dataset contain all information from the source data. The only change made is to rearrange the structure by extracting the file names, which correspond to NDC and image id, and put them into separated columns.