File size: 1,979 Bytes
dae9b2f
 
 
 
 
 
 
 
e972242
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
a891910
e972242
 
 
 
 
 
 
 
 
 
 
 
a891910
e972242
 
 
 
 
 
 
 
 
 
 
dae9b2f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
---
license: mit
title: PetroSeg
sdk: streamlit
emoji: πŸ‘€
colorFrom: red
colorTo: yellow
---
# Unsupervised Segmentation App with Streamlit and PyTorch

## Table of Contents
1. [Introduction](#introduction)
2. [Acknowledgments](#acknowledgments)
3. [Requirements](#requirements)
4. [Installation](#installation)
5. [How to Run](#how-to-run)
6. [Code Explanation](#code-explanation)
7. [Contributing](#contributing)
8. [License](#license)

---

## Introduction 🌟
This project is a web application built using Streamlit and PyTorch. It performs unsupervised segmentation on uploaded images. The segmented image can be downloaded, and the colors of the segments can be customized.

---

## Acknowledgments πŸ™
This code is inspired from the project [pytorch-unsupervised-segmentation](https://github.com/kanezaki/pytorch-unsupervised-segmentation) by kanezaki. The original project is based on the paper "Unsupervised Image Segmentation by Backpropagation" presented at IEEE ICASSP 2018. The code is optimized for thin section images and microscopy analysis.

---

## Requirements πŸ“‹
- Python 3.x
- Streamlit
- PyTorch
- OpenCV
- NumPy
- scikit-image
- PIL
- base64

---

## Installation πŸ› οΈ

1. **Clone the repository**
    ```bash
    git clone https://github.com/your-repo/unsupervised-segmentation.git
    ```
2. **Navigate to the project directory**
    ```bash
    cd unsupervised-segmentation
    ```
3. **Install the required packages**
    ```bash
    pip install -r requirements.txt
    ```

---

## How to Run πŸš€

1. **Navigate to the project directory**
    ```bash
    cd unsupervised-segmentation
    ```
2. **Run the Streamlit app**
    ```bash
    streamlit run app.py
    ```

---
![Streamlit App Screenshot](https://github.com/fazzam12345/Unsupervised-Segmentation-App/blob/master/Streamlit_app.png?raw=true)


---

## Contributing 🀝
Feel free to open issues and pull requests!

---

## License πŸ“œ
This project is licensed under the MIT License.