Spaces:
Sleeping
Sleeping
Commit
·
171905d
1
Parent(s):
cef6c49
readme
Browse files- README.md +31 -0
- README1.md +0 -30
README.md
CHANGED
@@ -11,3 +11,34 @@ license: mit
|
|
11 |
---
|
12 |
|
13 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
---
|
12 |
|
13 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
14 |
+
|
15 |
+
# CIFAR10 demo with GradCAM
|
16 |
+
## How to Use the App
|
17 |
+
1. The app has two tabs:
|
18 |
+
- **Examples**: In this tab, you can upload your own 32x32 pixel image or choose an example image provided to classify and visualize the class activation maps using GradCAM. You can adjust the number of top predicted classes, show/hide the GradCAM overlay, select a target layer, and control the transparency of the overlay.
|
19 |
+
- **Misclassified Examples**: In this tab, the app displays a gallery of misclassified images from CIFAR10 test dataset. You can control the number of examples shown, show/hide the GradCAM overlay, select a target layer, and control the transparency of the overlay.
|
20 |
+
|
21 |
+
2. **Examples Tab**:
|
22 |
+
- **Input Image**: Upload your own 32x32 pixel image or select one of the example images from the dropdown list.
|
23 |
+
- **Number of Top Classes**: Choose the number of top predicted classes to display along with their respective confidence scores.
|
24 |
+
- **Show GradCAM?**: Check this box to display the GradCAM overlay on the input image. Uncheck it to view only the original image.
|
25 |
+
- **Which Layer?**: Adjust the target layer for GradCAM visualization. The default value is -2.
|
26 |
+
- **Transparency**: Control the transparency of the GradCAM overlay. The default value is 0.7.
|
27 |
+
|
28 |
+
3. **Misclassified Examples Tab**:
|
29 |
+
- **No. of Missclassified Examples**: Control the number of misclassified examples displayed in the gallery. The default value is 20.
|
30 |
+
- **Show GradCAM?**: Check this box to display the GradCAM overlay on the misclassified images. Uncheck it to view only the original images.
|
31 |
+
- **Which Layer?**: Adjust the target layer for GradCAM visualization. The default value is -2.
|
32 |
+
- **Transparency**: Control the transparency of the GradCAM overlay. The default value is 0.7.
|
33 |
+
|
34 |
+
4. After adjusting the settings, click the "Submit" button to see the results.
|
35 |
+
|
36 |
+
## Credits
|
37 |
+
|
38 |
+
- This app is built using the Gradio library ([https://www.gradio.app/](https://www.gradio.app/)) for interactive model interfaces.
|
39 |
+
- The PyTorch library ([https://pytorch.org/](https://pytorch.org/)) is used for the deep learning model and GradCAM visualization.
|
40 |
+
- The CIFAR-10 dataset ([https://www.cs.toronto.edu/~kriz/cifar.html](https://www.cs.toronto.edu/~kriz/cifar.html)) is used for training and evaluation.
|
41 |
+
|
42 |
+
## License
|
43 |
+
|
44 |
+
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
README1.md
DELETED
@@ -1,30 +0,0 @@
|
|
1 |
-
# CIFAR10 demo with GradCAM
|
2 |
-
## How to Use the App
|
3 |
-
1. The app has two tabs:
|
4 |
-
- **Examples**: In this tab, you can upload your own 32x32 pixel image or choose an example image provided to classify and visualize the class activation maps using GradCAM. You can adjust the number of top predicted classes, show/hide the GradCAM overlay, select a target layer, and control the transparency of the overlay.
|
5 |
-
- **Misclassified Examples**: In this tab, the app displays a gallery of misclassified images from CIFAR10 test dataset. You can control the number of examples shown, show/hide the GradCAM overlay, select a target layer, and control the transparency of the overlay.
|
6 |
-
|
7 |
-
2. **Examples Tab**:
|
8 |
-
- **Input Image**: Upload your own 32x32 pixel image or select one of the example images from the dropdown list.
|
9 |
-
- **Number of Top Classes**: Choose the number of top predicted classes to display along with their respective confidence scores.
|
10 |
-
- **Show GradCAM?**: Check this box to display the GradCAM overlay on the input image. Uncheck it to view only the original image.
|
11 |
-
- **Which Layer?**: Adjust the target layer for GradCAM visualization. The default value is -2.
|
12 |
-
- **Transparency**: Control the transparency of the GradCAM overlay. The default value is 0.7.
|
13 |
-
|
14 |
-
3. **Misclassified Examples Tab**:
|
15 |
-
- **No. of Missclassified Examples**: Control the number of misclassified examples displayed in the gallery. The default value is 20.
|
16 |
-
- **Show GradCAM?**: Check this box to display the GradCAM overlay on the misclassified images. Uncheck it to view only the original images.
|
17 |
-
- **Which Layer?**: Adjust the target layer for GradCAM visualization. The default value is -2.
|
18 |
-
- **Transparency**: Control the transparency of the GradCAM overlay. The default value is 0.7.
|
19 |
-
|
20 |
-
4. After adjusting the settings, click the "Submit" button to see the results.
|
21 |
-
|
22 |
-
## Credits
|
23 |
-
|
24 |
-
- This app is built using the Gradio library ([https://www.gradio.app/](https://www.gradio.app/)) for interactive model interfaces.
|
25 |
-
- The PyTorch library ([https://pytorch.org/](https://pytorch.org/)) is used for the deep learning model and GradCAM visualization.
|
26 |
-
- The CIFAR-10 dataset ([https://www.cs.toronto.edu/~kriz/cifar.html](https://www.cs.toronto.edu/~kriz/cifar.html)) is used for training and evaluation.
|
27 |
-
|
28 |
-
## License
|
29 |
-
|
30 |
-
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|