feat: reorganizar modelos em categorias e adicionar novos classificadores
Browse files- Reorganizada lista de modelos em 20 categorias por tipo de classificação
- Adicionados 22 modelos novos do Hugging Face com sufxo " << new >>"
- Atualizada função classify para remover sufxo antes de usar modelo
- Adicionado texto explicativo a destacar 22 novos modelos adicionados
---
feat: reorganize models into categories and add new classifiers
- Reorganized model list into 20 categories by classification type
- Added 22 new Hugging Face models with " << new >>" suffix
- Updated classify function to remove suffix before using model
- Added explanatory text highlighting 22 new models added
app.py
CHANGED
|
@@ -25,8 +25,8 @@ MODELS = [
|
|
| 25 |
"timm/tf_efficientnetv2_s.in21k",
|
| 26 |
"timm/convnext_tiny.fb_in22k",
|
| 27 |
"vit-base-patch16-224-in21k",
|
| 28 |
-
"facebook/deit-base-distilled-patch16-224 new
|
| 29 |
-
"WinKawaks/vit-tiny-patch16-224 new
|
| 30 |
|
| 31 |
"-- Age Classification --",
|
| 32 |
"nateraw/vit-age-classifier",
|
|
@@ -35,12 +35,12 @@ MODELS = [
|
|
| 35 |
"Falconsai/nsfw_image_detection",
|
| 36 |
"LukeJacob2023/nsfw-image-detector",
|
| 37 |
"carbon225/vit-base-patch16-224-hentai",
|
| 38 |
-
"Marqo/nsfw-image-detection-384 new",
|
| 39 |
|
| 40 |
"-- Aesthetic/Art Classification --",
|
| 41 |
"cafeai/cafe_aesthetic",
|
| 42 |
"shadowlilac/aesthetic-shadow",
|
| 43 |
-
"pixai-labs/pixai-tagger-v0.9 new",
|
| 44 |
|
| 45 |
"-- Face/Emotion Classification --",
|
| 46 |
"trpakov/vit-face-expression",
|
|
@@ -49,22 +49,22 @@ MODELS = [
|
|
| 49 |
|
| 50 |
"-- Food Classification --",
|
| 51 |
"nateraw/food",
|
| 52 |
-
"BinhQuocNguyen/food-recognition-model new",
|
| 53 |
|
| 54 |
"-- Medical/Dermatology --",
|
| 55 |
-
"google/derm-foundation new",
|
| 56 |
-
"google/cxr-foundation new",
|
| 57 |
-
"Anwarkh1/Skin_Cancer-Image_Classification new",
|
| 58 |
|
| 59 |
"-- AI vs Human Detection --",
|
| 60 |
-
"Ateeqq/ai-vs-human-image-detector new",
|
| 61 |
-
"umm-maybe/AI-image-detector new",
|
| 62 |
|
| 63 |
"-- Deepfake Detection --",
|
| 64 |
"not-lain/deepfake",
|
| 65 |
|
| 66 |
"-- Anime/Manga Classification --",
|
| 67 |
-
"Readidno/anime.mili new",
|
| 68 |
|
| 69 |
"-- Human Activity Recognition --",
|
| 70 |
"DunnBC22/vit-base-patch16-224-in21k_Human_Activity_Recognition",
|
|
@@ -79,22 +79,22 @@ MODELS = [
|
|
| 79 |
"FatihC/swin-tiny-patch4-window7-224-finetuned-eurosat-watermark",
|
| 80 |
|
| 81 |
"-- Car Classification --",
|
| 82 |
-
"lamnt2008/car_brands_classification new",
|
| 83 |
|
| 84 |
"-- Document Classification --",
|
| 85 |
-
"docling-project/DocumentFigureClassifier-v2.5 new",
|
| 86 |
|
| 87 |
"-- EfficientNet (timm) --",
|
| 88 |
-
"timm/efficientnet_b0.ra_in1k new",
|
| 89 |
"timm/mobilenetv3_large_100.ra_in1k",
|
| 90 |
-
"timm/mobilenetv3_small_100.lamb_in1k new",
|
| 91 |
|
| 92 |
"-- Experimental/Future --",
|
| 93 |
"#q-future/one-align",
|
| 94 |
]
|
| 95 |
|
| 96 |
def classify(image, model):
|
| 97 |
-
model_name = model.replace(" new", "")
|
| 98 |
classifier = pipeline("image-classification", model=model_name)
|
| 99 |
result= classifier(image)
|
| 100 |
return result
|
|
@@ -122,6 +122,7 @@ def print_result(result):
|
|
| 122 |
def main():
|
| 123 |
st.title("Image Classification")
|
| 124 |
st.write("This is a simple web app to test and compare different image classifier models using Hugging Face's image-classification pipeline.")
|
|
|
|
| 125 |
st.write("From time to time more models will be added to the list. If you want to add a model, please open an issue on the GitHub repository.")
|
| 126 |
st.write("If you like this project, please consider liking it or buying me a coffee. It will help me to keep working on this and other projects. Thank you!")
|
| 127 |
|
|
|
|
| 25 |
"timm/tf_efficientnetv2_s.in21k",
|
| 26 |
"timm/convnext_tiny.fb_in22k",
|
| 27 |
"vit-base-patch16-224-in21k",
|
| 28 |
+
"facebook/deit-base-distilled-patch16-224 << new >>,
|
| 29 |
+
"WinKawaks/vit-tiny-patch16-224 << new >>,
|
| 30 |
|
| 31 |
"-- Age Classification --",
|
| 32 |
"nateraw/vit-age-classifier",
|
|
|
|
| 35 |
"Falconsai/nsfw_image_detection",
|
| 36 |
"LukeJacob2023/nsfw-image-detector",
|
| 37 |
"carbon225/vit-base-patch16-224-hentai",
|
| 38 |
+
"Marqo/nsfw-image-detection-384 << new >>",
|
| 39 |
|
| 40 |
"-- Aesthetic/Art Classification --",
|
| 41 |
"cafeai/cafe_aesthetic",
|
| 42 |
"shadowlilac/aesthetic-shadow",
|
| 43 |
+
"pixai-labs/pixai-tagger-v0.9 << new >>",
|
| 44 |
|
| 45 |
"-- Face/Emotion Classification --",
|
| 46 |
"trpakov/vit-face-expression",
|
|
|
|
| 49 |
|
| 50 |
"-- Food Classification --",
|
| 51 |
"nateraw/food",
|
| 52 |
+
"BinhQuocNguyen/food-recognition-model << new >>",
|
| 53 |
|
| 54 |
"-- Medical/Dermatology --",
|
| 55 |
+
"google/derm-foundation << new >>",
|
| 56 |
+
"google/cxr-foundation << new >>",
|
| 57 |
+
"Anwarkh1/Skin_Cancer-Image_Classification << new >>",
|
| 58 |
|
| 59 |
"-- AI vs Human Detection --",
|
| 60 |
+
"Ateeqq/ai-vs-human-image-detector << new >>",
|
| 61 |
+
"umm-maybe/AI-image-detector << new >>",
|
| 62 |
|
| 63 |
"-- Deepfake Detection --",
|
| 64 |
"not-lain/deepfake",
|
| 65 |
|
| 66 |
"-- Anime/Manga Classification --",
|
| 67 |
+
"Readidno/anime.mili << new >>",
|
| 68 |
|
| 69 |
"-- Human Activity Recognition --",
|
| 70 |
"DunnBC22/vit-base-patch16-224-in21k_Human_Activity_Recognition",
|
|
|
|
| 79 |
"FatihC/swin-tiny-patch4-window7-224-finetuned-eurosat-watermark",
|
| 80 |
|
| 81 |
"-- Car Classification --",
|
| 82 |
+
"lamnt2008/car_brands_classification << new >>",
|
| 83 |
|
| 84 |
"-- Document Classification --",
|
| 85 |
+
"docling-project/DocumentFigureClassifier-v2.5 << new >>",
|
| 86 |
|
| 87 |
"-- EfficientNet (timm) --",
|
| 88 |
+
"timm/efficientnet_b0.ra_in1k << new >>",
|
| 89 |
"timm/mobilenetv3_large_100.ra_in1k",
|
| 90 |
+
"timm/mobilenetv3_small_100.lamb_in1k << new >>",
|
| 91 |
|
| 92 |
"-- Experimental/Future --",
|
| 93 |
"#q-future/one-align",
|
| 94 |
]
|
| 95 |
|
| 96 |
def classify(image, model):
|
| 97 |
+
model_name = model.replace(" << new >>", "")
|
| 98 |
classifier = pipeline("image-classification", model=model_name)
|
| 99 |
result= classifier(image)
|
| 100 |
return result
|
|
|
|
| 122 |
def main():
|
| 123 |
st.title("Image Classification")
|
| 124 |
st.write("This is a simple web app to test and compare different image classifier models using Hugging Face's image-classification pipeline.")
|
| 125 |
+
st.markdown(":white_check_mark: **:green[22 new models added!]** - Including Medical, AI vs Human detection, Anime classification and more.")
|
| 126 |
st.write("From time to time more models will be added to the list. If you want to add a model, please open an issue on the GitHub repository.")
|
| 127 |
st.write("If you like this project, please consider liking it or buying me a coffee. It will help me to keep working on this and other projects. Thank you!")
|
| 128 |
|