--- license: bsd language: - en metrics: - accuracy tags: - climate - trash - classifier - water - aquatic - pollution - environment datasets: - brsdincer/garbage-collective-data-for-nature-conservation - harshpanwar/aquatrash model-index: - name: Trashnet r = 1 results: - task: type: trash-classification # Required. Example: automatic-speech-recognition dataset: type: aquatic-trash # Required. Example: common_voice. Use dataset id from https://hf.co/datasets name: combined-trash-images # Required. A pretty name for the dataset. Example: Common Voice (French) metrics: - type: accuracy-radius-1 # Required. Example: wer. Use metric id from https://hf.co/metrics value: 27.47 # Required. Example: 20.90 - name: Trashnet r = 2 results: - task: type: trash-classification # Required. Example: automatic-speech-recognition dataset: type: aquatic-trash # Required. Example: common_voice. Use dataset id from https://hf.co/datasets name: combined-trash-images # Required. A pretty name for the dataset. Example: Common Voice (French) metrics: - type: accuracy-radius-2 # Required. Example: wer. Use metric id from https://hf.co/metrics value: 51.53 # Required. Example: 20.90 - name: Trashnet r = 3 results: - task: type: trash-classification # Required. Example: automatic-speech-recognition dataset: type: aquatic-trash # Required. Example: common_voice. Use dataset id from https://hf.co/datasets name: combined-trash-images # Required. A pretty name for the dataset. Example: Common Voice (French) metrics: - type: accuracy-radius-3 # Required. Example: wer. Use metric id from https://hf.co/metrics value: 62.97 # Required. Example: 20.90 --- # Trashnet - Trash Identification model for forensic trash cleanup ## Overview This model takes images or video frames as input, and identifies the most likely types of trash present in the scene. The model has been specifically built for aquatic trash, but performs almost equally well on terrestrial trash. Applications include automatic trash classification, ecological monitoring, and sorting at recycling plants. # Usage The model has been trained on 120 x 120 RGB images. To evaluate the contents of an image, you will need to pass in a tensor of shape (120,120,3).
Output consists of a 10-d tensor of class probabilities. ## Training and Classes Trained for 22 epochs on 3000 data points. Model accuracies are in the sidebar.
Please read the 'Limitations' section for information on how the model was evaluated for accuracy. #### Class labels trash_classes = ['battery','biological','glass','cardboard','clothes','metal','paper','plastic','shoes','trash'] #### Mapping common trash types from training data together class_to_idx = {
'battery':0,
'biological':1,
'glass':2,
'brown_glass':2,
'green_glass':2,
'cardboard':3,
'clothes':4,
'metal':5,
'paper':6,
'plastic':7,
'shoes':8,
'trash':9
}
## Limitations The model has limited training data of trash in the environment. Additionally, the model overrepresents plastic and glass in its predictions due to sampling bias and visual similarities between plastic, glass, and other common types of trash. One concern is that many types of trash look visually similar or identical, even to humans. The model can get confused and rank these classes at similar probabilities. As a solution, the model is marked as 'correct' when the correct label is within the model's top r most predicted trash types. radius = r = 3 gives the most appropriate results.