amazon-products / README.md
ckandemir's picture
Update README.md
e0073c8
|
raw
history blame
No virus
4.07 kB
---
configs:
- config_name: default
data_files:
- split: train
path: data/train-*
- split: test
path: data/test-*
- split: eval
path: data/eval-*
datasets:
- bprateek/amazon_product_description
dataset_info:
features:
- name: Product Name
dtype: string
- name: Category
dtype: string
- name: Description
dtype: string
- name: Selling Price
dtype: string
- name: Product Specification
dtype: string
- name: Image
dtype: string
splits:
- name: train
num_bytes: 12542887
num_examples: 23993
- name: test
num_bytes: 3499375
num_examples: 6665
- name: eval
num_bytes: 1376174
num_examples: 2666
download_size: 6391314
dataset_size: 17418436
license: apache-2.0
task_categories:
- image-classification
- image-to-text
language:
- en
size_categories:
- 10K<n<100K
---
## Dataset Creation and Processing Overview
This dataset underwent a comprehensive process of loading, cleaning, processing, and preparing, incorporating a range of data manipulation and NLP techniques to optimize its utility for machine learning models, particularly in natural language processing.
### Data Loading and Initial Cleaning
- **Source**: Loaded from the Hugging Face dataset repository [bprateek/amazon_product_description](https://huggingface.co/datasets/bprateek/amazon_product_description).
- **Conversion to Pandas DataFrame**: For ease of data manipulation.
- **Null Value Removal**: Rows with null values in the 'About Product' column were discarded.
### Data Cleaning and NLP Processing
- **Sentence Extraction**: 'About Product' descriptions were split into sentences, identifying common phrases.
- **Emoji and Special Character Removal**: A regex function removed these elements from the product descriptions.
- **Common Phrase Elimination**: A function was used to strip common phrases from each product description.
- **Improving Writing Standards**: Adjusted capitalization, punctuation, and replaced '&' with 'and' for better readability and formalization.
### Sentence Similarity Analysis
- **Model Application**: The pre-trained Sentence Transformer model 'all-MiniLM-L6-v2' was used.
- **Sentence Comparison**: Identified the most similar sentence to each product name within the cleaned product descriptions.
- **Integration of Results**: Added the most similar sentences as a new column 'Most_Similar_Sentence'.
### Dataset Refinement
- **Column Selection**: Retained relevant columns for final dataset.
- **Image URL Processing**: Split multiple image URLs into individual URLs, removing specific unwanted URLs.
- **Column Renaming**: Renamed 'Most_Similar_Sentence' to 'Description'.
### Image Validation
- **Image URL Validation**: Implemented a function to verify the validity of each image URL.
- **Filtering Valid Images**: Retained only rows with valid image URLs.
### Dataset Splitting for Machine Learning
- **Creation of Train, Test, and Eval Sets**: Used scikit-learn's `train_test_split` for dataset division.
### Hugging Face Dataset Preparation and Publishing
- **Conversion to Dataset Objects**: Converted each Pandas DataFrame (train, test, eval) into Hugging Face `Dataset` objects.
- **Dataset Dictionary Assembly**: Aggregated all splits into a `DatasetDict`.
- **Publishing to Hugging Face Hub**: The dataset was named "amazon-products" and pushed to the Hub for community access.
## Dataset Card Information
- **Configs**: The dataset is split into train, test, and eval configurations, with paths specified for each.
- **Features**: Includes fields for Product Name, Category, Description, Selling Price, Product Specification, and Image.
- **Splits**: Detailed information on the number of bytes and examples for each dataset split.
- **Sizes**: Download and total dataset size specifications are provided.
For further details or to contribute to enhancing the dataset card, please refer to the [Hugging Face Dataset Card Contribution Guide](https://github.com/huggingface/datasets/blob/main/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards).