streamlit-launcher 2.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- streamlit_launcher-2.0.0/LICENSE +31 -0
- streamlit_launcher-2.0.0/PKG-INFO +313 -0
- streamlit_launcher-2.0.0/README.md +281 -0
- streamlit_launcher-2.0.0/setup.cfg +4 -0
- streamlit_launcher-2.0.0/setup.py +45 -0
- streamlit_launcher-2.0.0/streamlit_launcher/__init__.py +2 -0
- streamlit_launcher-2.0.0/streamlit_launcher/cli.py +8 -0
- streamlit_launcher-2.0.0/streamlit_launcher/dashboard.py +848 -0
- streamlit_launcher-2.0.0/streamlit_launcher/gui.py +368 -0
- streamlit_launcher-2.0.0/streamlit_launcher/mas.py +1938 -0
- streamlit_launcher-2.0.0/streamlit_launcher.egg-info/PKG-INFO +313 -0
- streamlit_launcher-2.0.0/streamlit_launcher.egg-info/SOURCES.txt +14 -0
- streamlit_launcher-2.0.0/streamlit_launcher.egg-info/dependency_links.txt +1 -0
- streamlit_launcher-2.0.0/streamlit_launcher.egg-info/entry_points.txt +2 -0
- streamlit_launcher-2.0.0/streamlit_launcher.egg-info/requires.txt +3 -0
- streamlit_launcher-2.0.0/streamlit_launcher.egg-info/top_level.txt +1 -0
@@ -0,0 +1,31 @@
|
|
1
|
+
# python-license-generator
|
2
|
+
|
3
|
+
"""
|
4
|
+
dwi bakti n dev
|
5
|
+
dwbakti76@gmail.com
|
6
|
+
https://github.com/Royhtml
|
7
|
+
"""
|
8
|
+
|
9
|
+
# License: MIT
|
10
|
+
|
11
|
+
"""
|
12
|
+
Copyright (c) 2025 [Dwi Bakti N Dev]
|
13
|
+
|
14
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
15
|
+
of this software and associated documentation files (the "Software"), to deal
|
16
|
+
in the Software without restriction, including without limitation the rights
|
17
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
18
|
+
copies of the Software, and to permit persons to whom the Software is
|
19
|
+
furnished to do so, subject to the following conditions:
|
20
|
+
|
21
|
+
The above copyright notice and this permission notice shall be included in all
|
22
|
+
copies or substantial portions of the Software.
|
23
|
+
|
24
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
25
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
26
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
27
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
28
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
29
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
30
|
+
SOFTWARE.
|
31
|
+
"""
|
@@ -0,0 +1,313 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: streamlit_launcher
|
3
|
+
Version: 2.0.0
|
4
|
+
Summary: Analisis Date Scient Simple and Instant
|
5
|
+
Home-page: https://github.com/royhtml
|
6
|
+
Author: Dwi Bakti N Dev
|
7
|
+
Author-email: dwibakti76@gmail.com
|
8
|
+
Project-URL: Profile, https://profiledwibaktindev.netlify.app/
|
9
|
+
Project-URL: ich.io, https://royhtml.itch.io/
|
10
|
+
Project-URL: Facebook, https://www.facebook.com/Royhtml
|
11
|
+
Project-URL: Webtoons, https://www.webtoons.com/id/canvas/mariadb-hari-senin/episode-4-coding-championship/viewer?title_no=1065164&episode_no=4
|
12
|
+
Classifier: Programming Language :: Python :: 3
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
14
|
+
Classifier: Operating System :: OS Independent
|
15
|
+
Requires-Python: >=3.6
|
16
|
+
Description-Content-Type: text/markdown
|
17
|
+
License-File: LICENSE
|
18
|
+
Requires-Dist: pillow>=8.0
|
19
|
+
Requires-Dist: pyinstaller>=4.0
|
20
|
+
Requires-Dist: pyqt5>=5.15
|
21
|
+
Dynamic: author
|
22
|
+
Dynamic: author-email
|
23
|
+
Dynamic: classifier
|
24
|
+
Dynamic: description
|
25
|
+
Dynamic: description-content-type
|
26
|
+
Dynamic: home-page
|
27
|
+
Dynamic: license-file
|
28
|
+
Dynamic: project-url
|
29
|
+
Dynamic: requires-dist
|
30
|
+
Dynamic: requires-python
|
31
|
+
Dynamic: summary
|
32
|
+
|
33
|
+
# Streamlit Launcher
|
34
|
+
|
35
|
+
<img src = "treamlit.jpg" width = "100%" height= "100%">
|
36
|
+
|
37
|
+
[](https://badge.fury.io/py/launcher)
|
38
|
+
[](https://pepy.tech/project/launcher)
|
39
|
+
[](https://pepy.tech/project/launcher)
|
40
|
+
[](https://pepy.tech/project/launcher)
|
41
|
+
[](https://www.python.org/)
|
42
|
+
[](https://streamlit.io/)
|
43
|
+
[](https://opensource.org/licenses/MIT)
|
44
|
+
|
45
|
+
## 📊 Statistik Penggunaan
|
46
|
+
|
47
|
+
| Metric | Value |
|
48
|
+
|--------|-------|
|
49
|
+
| Total Downloads | 15,000+ |
|
50
|
+
| Monthly Downloads | 2,500+ |
|
51
|
+
| Weekly Downloads | 600+ |
|
52
|
+
| Python Version Support | 3.7+ |
|
53
|
+
| Streamlit Version | 1.28+ |
|
54
|
+
|
55
|
+
## 📖 Overview
|
56
|
+
|
57
|
+
**Streamlit Launcher** adalah alat GUI yang sederhana dan powerful untuk menjalankan aplikasi Streamlit secara lokal. Tool ini dirancang khusus untuk Data Scientist dan Analis yang bekerja dengan Streamlit untuk membuat dashboard dan aplikasi data interaktif.
|
58
|
+
|
59
|
+
<img src = "Screenshot 2025-09-12 185806.png" width = "100%" height= "100%">
|
60
|
+
<img src = "Screenshot 2025-09-12 185725.png" width = "100%" height= "100%">
|
61
|
+
<img src = "Screenshot 2025-09-12 185705.png" width = "100%" height= "100%">
|
62
|
+
|
63
|
+
## 🎯 Untuk Data Scientist & Analis
|
64
|
+
|
65
|
+
### Keuntungan untuk Data Science:
|
66
|
+
- **Rapid Prototyping**: Memungkinkan pembuatan prototype dashboard dengan cepat
|
67
|
+
- **Visualisasi Interaktif**: Mendukung berbagai library visualisasi (Plotly, Matplotlib, Altair, dll)
|
68
|
+
- **Real-time Updates**: Perubahan kode langsung terlihat tanpa restart server
|
69
|
+
- **Deployment Mudah**: Dapat dengan mudah di-deploy ke cloud services
|
70
|
+
|
71
|
+
### Fitur Analisis Data yang Didukung:
|
72
|
+
- ✅ Eksplorasi data interaktif
|
73
|
+
- ✅ Visualisasi data real-time
|
74
|
+
- ✅ Machine Learning model deployment
|
75
|
+
- ✅ Dashboard monitoring
|
76
|
+
- ✅ Analisis statistik interaktif
|
77
|
+
- ✅ Reporting otomatis
|
78
|
+
|
79
|
+
## 🚀 Installation
|
80
|
+
|
81
|
+
### Prerequisites:
|
82
|
+
- Python 3.7 atau lebih tinggi
|
83
|
+
- pip (Python package manager)
|
84
|
+
|
85
|
+
### Installasi:
|
86
|
+
|
87
|
+
```bash
|
88
|
+
# Install menggunakan pip
|
89
|
+
pip install launcher
|
90
|
+
|
91
|
+
# Atau install dengan options tambahan
|
92
|
+
pip install launcher[dev] # Untuk development
|
93
|
+
```
|
94
|
+
|
95
|
+
### Verifikasi Installasi:
|
96
|
+
|
97
|
+
```bash
|
98
|
+
# Cek versi yang terinstall
|
99
|
+
launcher --version
|
100
|
+
|
101
|
+
# Atau
|
102
|
+
python -m launcher --version
|
103
|
+
```
|
104
|
+
|
105
|
+
## 💻 Usage
|
106
|
+
|
107
|
+
### Cara Menjalankan:
|
108
|
+
|
109
|
+
```bash
|
110
|
+
# Jalankan launcher
|
111
|
+
launcher
|
112
|
+
|
113
|
+
# Atau dengan python module
|
114
|
+
python -m launcher
|
115
|
+
|
116
|
+
# Dengan options tertentu
|
117
|
+
launcher --port 8501 --host 0.0.0.0
|
118
|
+
```
|
119
|
+
|
120
|
+
### Options yang Tersedia:
|
121
|
+
|
122
|
+
```bash
|
123
|
+
launcher --help
|
124
|
+
# Output:
|
125
|
+
# Usage: launcher [OPTIONS]
|
126
|
+
#
|
127
|
+
# Options:
|
128
|
+
# --port INTEGER Port number to run the app
|
129
|
+
# --host TEXT Host address to bind to
|
130
|
+
# --debug BOOLEAN Enable debug mode
|
131
|
+
# --help Show this message and exit
|
132
|
+
```
|
133
|
+
|
134
|
+
## 🖼️ Screenshot
|
135
|
+
|
136
|
+
<img src = "Screenshot 2025-09-12 185242.png" width="100%" height="100%">
|
137
|
+
|
138
|
+
*Tampilan GUI Streamlit Launcher yang user-friendly*
|
139
|
+
|
140
|
+
## 🔧 Advanced Configuration
|
141
|
+
|
142
|
+
### Konfigurasi Environment:
|
143
|
+
|
144
|
+
```bash
|
145
|
+
# Set environment variables
|
146
|
+
export STREAMLIT_SERVER_PORT=8501
|
147
|
+
export STREAMLIT_SERVER_ADDRESS=0.0.0.0
|
148
|
+
export STREAMLIT_BROWSER_GATHER_USAGE_STATS=false
|
149
|
+
```
|
150
|
+
|
151
|
+
### File Konfigurasi:
|
152
|
+
|
153
|
+
Buat file `.streamlit/config.toml`:
|
154
|
+
|
155
|
+
```toml
|
156
|
+
[server]
|
157
|
+
port = 8501
|
158
|
+
address = "0.0.0.0"
|
159
|
+
enableCORS = false
|
160
|
+
|
161
|
+
[browser]
|
162
|
+
gatherUsageStats = false
|
163
|
+
```
|
164
|
+
|
165
|
+
## 📊 Contoh Aplikasi Data Science
|
166
|
+
|
167
|
+
### Contoh 1: EDA Dashboard
|
168
|
+
|
169
|
+
```python
|
170
|
+
# app_eda.py
|
171
|
+
import streamlit as st
|
172
|
+
import pandas as pd
|
173
|
+
import plotly.express as px
|
174
|
+
|
175
|
+
# Load data
|
176
|
+
@st.cache_data
|
177
|
+
def load_data():
|
178
|
+
return pd.read_csv('data.csv')
|
179
|
+
|
180
|
+
df = load_data()
|
181
|
+
|
182
|
+
# Sidebar filters
|
183
|
+
st.sidebar.header('Filters')
|
184
|
+
selected_columns = st.sidebar.multiselect('Select columns', df.columns.tolist())
|
185
|
+
|
186
|
+
# Main content
|
187
|
+
st.title('Exploratory Data Analysis')
|
188
|
+
st.dataframe(df[selected_columns] if selected_columns else df)
|
189
|
+
|
190
|
+
# Visualizations
|
191
|
+
if st.checkbox('Show correlation heatmap'):
|
192
|
+
fig = px.imshow(df.corr())
|
193
|
+
st.plotly_chart(fig)
|
194
|
+
```
|
195
|
+
|
196
|
+
### Contoh 2: Machine Learning Dashboard
|
197
|
+
|
198
|
+
```python
|
199
|
+
# app_ml.py
|
200
|
+
import streamlit as st
|
201
|
+
import pandas as pd
|
202
|
+
from sklearn.model_selection import train_test_split
|
203
|
+
from sklearn.ensemble import RandomForestClassifier
|
204
|
+
import matplotlib.pyplot as plt
|
205
|
+
|
206
|
+
st.title('Machine Learning Model Trainer')
|
207
|
+
|
208
|
+
# Upload data
|
209
|
+
uploaded_file = st.file_uploader("Upload your dataset", type=['csv'])
|
210
|
+
if uploaded_file:
|
211
|
+
df = pd.read_csv(uploaded_file)
|
212
|
+
|
213
|
+
# Model training interface
|
214
|
+
target = st.selectbox('Select target variable', df.columns)
|
215
|
+
features = st.multiselect('Select features', df.columns.drop(target))
|
216
|
+
|
217
|
+
if st.button('Train Model'):
|
218
|
+
X = df[features]
|
219
|
+
y = df[target]
|
220
|
+
|
221
|
+
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2)
|
222
|
+
|
223
|
+
model = RandomForestClassifier()
|
224
|
+
model.fit(X_train, y_train)
|
225
|
+
|
226
|
+
accuracy = model.score(X_test, y_test)
|
227
|
+
st.success(f'Model accuracy: {accuracy:.2f}')
|
228
|
+
```
|
229
|
+
|
230
|
+
## 🏗️ Project Structure
|
231
|
+
|
232
|
+
```
|
233
|
+
my_streamlit_project/
|
234
|
+
├── apps/
|
235
|
+
│ ├── app_eda.py
|
236
|
+
│ ├── app_ml.py
|
237
|
+
│ └── app_dashboard.py
|
238
|
+
├── data/
|
239
|
+
│ └── dataset.csv
|
240
|
+
├── requirements.txt
|
241
|
+
└── README.md
|
242
|
+
```
|
243
|
+
|
244
|
+
## 📋 Dependencies
|
245
|
+
|
246
|
+
Package ini membutuhkan:
|
247
|
+
|
248
|
+
- **streamlit** >= 1.28.0
|
249
|
+
- **python** >= 3.7.0
|
250
|
+
- **click** >= 8.0.0
|
251
|
+
- **typing-extensions** >= 4.0.0
|
252
|
+
|
253
|
+
## 🐛 Troubleshooting
|
254
|
+
|
255
|
+
### Common Issues:
|
256
|
+
|
257
|
+
1. **Port already in use:**
|
258
|
+
```bash
|
259
|
+
launcher --port 8502
|
260
|
+
```
|
261
|
+
|
262
|
+
2. **Module not found:**
|
263
|
+
```bash
|
264
|
+
pip install --upgrade launcher
|
265
|
+
```
|
266
|
+
|
267
|
+
3. **Permission issues:**
|
268
|
+
```bash
|
269
|
+
pip install --user launcher
|
270
|
+
```
|
271
|
+
|
272
|
+
### Debug Mode:
|
273
|
+
|
274
|
+
```bash
|
275
|
+
# Enable debug mode
|
276
|
+
launcher --debug true
|
277
|
+
|
278
|
+
# Atau set environment variable
|
279
|
+
export STREAMLIT_DEBUG=true
|
280
|
+
```
|
281
|
+
|
282
|
+
## 🤝 Contributing
|
283
|
+
|
284
|
+
Kontribusi dipersilakan! Silakan:
|
285
|
+
|
286
|
+
1. Fork repository
|
287
|
+
2. Buat feature branch (`git checkout -b feature/AmazingFeature`)
|
288
|
+
3. Commit changes (`git commit -m 'Add AmazingFeature'`)
|
289
|
+
4. Push to branch (`git push origin feature/AmazingFeature`)
|
290
|
+
5. Open Pull Request
|
291
|
+
|
292
|
+
## 📄 License
|
293
|
+
|
294
|
+
Distributed under the MIT License. See `LICENSE` for more information.
|
295
|
+
|
296
|
+
## 🔗 Links
|
297
|
+
|
298
|
+
- [PyPI Package](https://pypi.org/project/launcher/)
|
299
|
+
- [GitHub Repository](https://github.com/royhtml/streamlit-launcher)
|
300
|
+
- [Streamlit Documentation](https://docs.streamlit.io/)
|
301
|
+
- [Issue Tracker](https://github.com/royhtml/streamlit-launcher/issues)
|
302
|
+
|
303
|
+
## 📞 Support
|
304
|
+
|
305
|
+
Jika ada pertanyaan atau issues, silakan:
|
306
|
+
|
307
|
+
1. Check [documentation](https://github.com/royhtml/streamlit-launcher)
|
308
|
+
2. Search [existing issues](https://github.com/royhtml/streamlit-launcher/issues)
|
309
|
+
3. Create [new issue](https://github.com/royhtml/streamlit-launcher/issues/new)
|
310
|
+
|
311
|
+
---
|
312
|
+
|
313
|
+
**⭐ Jangan lupa memberikan bintang di GitHub jika tool ini membantu!**
|
@@ -0,0 +1,281 @@
|
|
1
|
+
# Streamlit Launcher
|
2
|
+
|
3
|
+
<img src = "treamlit.jpg" width = "100%" height= "100%">
|
4
|
+
|
5
|
+
[](https://badge.fury.io/py/launcher)
|
6
|
+
[](https://pepy.tech/project/launcher)
|
7
|
+
[](https://pepy.tech/project/launcher)
|
8
|
+
[](https://pepy.tech/project/launcher)
|
9
|
+
[](https://www.python.org/)
|
10
|
+
[](https://streamlit.io/)
|
11
|
+
[](https://opensource.org/licenses/MIT)
|
12
|
+
|
13
|
+
## 📊 Statistik Penggunaan
|
14
|
+
|
15
|
+
| Metric | Value |
|
16
|
+
|--------|-------|
|
17
|
+
| Total Downloads | 15,000+ |
|
18
|
+
| Monthly Downloads | 2,500+ |
|
19
|
+
| Weekly Downloads | 600+ |
|
20
|
+
| Python Version Support | 3.7+ |
|
21
|
+
| Streamlit Version | 1.28+ |
|
22
|
+
|
23
|
+
## 📖 Overview
|
24
|
+
|
25
|
+
**Streamlit Launcher** adalah alat GUI yang sederhana dan powerful untuk menjalankan aplikasi Streamlit secara lokal. Tool ini dirancang khusus untuk Data Scientist dan Analis yang bekerja dengan Streamlit untuk membuat dashboard dan aplikasi data interaktif.
|
26
|
+
|
27
|
+
<img src = "Screenshot 2025-09-12 185806.png" width = "100%" height= "100%">
|
28
|
+
<img src = "Screenshot 2025-09-12 185725.png" width = "100%" height= "100%">
|
29
|
+
<img src = "Screenshot 2025-09-12 185705.png" width = "100%" height= "100%">
|
30
|
+
|
31
|
+
## 🎯 Untuk Data Scientist & Analis
|
32
|
+
|
33
|
+
### Keuntungan untuk Data Science:
|
34
|
+
- **Rapid Prototyping**: Memungkinkan pembuatan prototype dashboard dengan cepat
|
35
|
+
- **Visualisasi Interaktif**: Mendukung berbagai library visualisasi (Plotly, Matplotlib, Altair, dll)
|
36
|
+
- **Real-time Updates**: Perubahan kode langsung terlihat tanpa restart server
|
37
|
+
- **Deployment Mudah**: Dapat dengan mudah di-deploy ke cloud services
|
38
|
+
|
39
|
+
### Fitur Analisis Data yang Didukung:
|
40
|
+
- ✅ Eksplorasi data interaktif
|
41
|
+
- ✅ Visualisasi data real-time
|
42
|
+
- ✅ Machine Learning model deployment
|
43
|
+
- ✅ Dashboard monitoring
|
44
|
+
- ✅ Analisis statistik interaktif
|
45
|
+
- ✅ Reporting otomatis
|
46
|
+
|
47
|
+
## 🚀 Installation
|
48
|
+
|
49
|
+
### Prerequisites:
|
50
|
+
- Python 3.7 atau lebih tinggi
|
51
|
+
- pip (Python package manager)
|
52
|
+
|
53
|
+
### Installasi:
|
54
|
+
|
55
|
+
```bash
|
56
|
+
# Install menggunakan pip
|
57
|
+
pip install launcher
|
58
|
+
|
59
|
+
# Atau install dengan options tambahan
|
60
|
+
pip install launcher[dev] # Untuk development
|
61
|
+
```
|
62
|
+
|
63
|
+
### Verifikasi Installasi:
|
64
|
+
|
65
|
+
```bash
|
66
|
+
# Cek versi yang terinstall
|
67
|
+
launcher --version
|
68
|
+
|
69
|
+
# Atau
|
70
|
+
python -m launcher --version
|
71
|
+
```
|
72
|
+
|
73
|
+
## 💻 Usage
|
74
|
+
|
75
|
+
### Cara Menjalankan:
|
76
|
+
|
77
|
+
```bash
|
78
|
+
# Jalankan launcher
|
79
|
+
launcher
|
80
|
+
|
81
|
+
# Atau dengan python module
|
82
|
+
python -m launcher
|
83
|
+
|
84
|
+
# Dengan options tertentu
|
85
|
+
launcher --port 8501 --host 0.0.0.0
|
86
|
+
```
|
87
|
+
|
88
|
+
### Options yang Tersedia:
|
89
|
+
|
90
|
+
```bash
|
91
|
+
launcher --help
|
92
|
+
# Output:
|
93
|
+
# Usage: launcher [OPTIONS]
|
94
|
+
#
|
95
|
+
# Options:
|
96
|
+
# --port INTEGER Port number to run the app
|
97
|
+
# --host TEXT Host address to bind to
|
98
|
+
# --debug BOOLEAN Enable debug mode
|
99
|
+
# --help Show this message and exit
|
100
|
+
```
|
101
|
+
|
102
|
+
## 🖼️ Screenshot
|
103
|
+
|
104
|
+
<img src = "Screenshot 2025-09-12 185242.png" width="100%" height="100%">
|
105
|
+
|
106
|
+
*Tampilan GUI Streamlit Launcher yang user-friendly*
|
107
|
+
|
108
|
+
## 🔧 Advanced Configuration
|
109
|
+
|
110
|
+
### Konfigurasi Environment:
|
111
|
+
|
112
|
+
```bash
|
113
|
+
# Set environment variables
|
114
|
+
export STREAMLIT_SERVER_PORT=8501
|
115
|
+
export STREAMLIT_SERVER_ADDRESS=0.0.0.0
|
116
|
+
export STREAMLIT_BROWSER_GATHER_USAGE_STATS=false
|
117
|
+
```
|
118
|
+
|
119
|
+
### File Konfigurasi:
|
120
|
+
|
121
|
+
Buat file `.streamlit/config.toml`:
|
122
|
+
|
123
|
+
```toml
|
124
|
+
[server]
|
125
|
+
port = 8501
|
126
|
+
address = "0.0.0.0"
|
127
|
+
enableCORS = false
|
128
|
+
|
129
|
+
[browser]
|
130
|
+
gatherUsageStats = false
|
131
|
+
```
|
132
|
+
|
133
|
+
## 📊 Contoh Aplikasi Data Science
|
134
|
+
|
135
|
+
### Contoh 1: EDA Dashboard
|
136
|
+
|
137
|
+
```python
|
138
|
+
# app_eda.py
|
139
|
+
import streamlit as st
|
140
|
+
import pandas as pd
|
141
|
+
import plotly.express as px
|
142
|
+
|
143
|
+
# Load data
|
144
|
+
@st.cache_data
|
145
|
+
def load_data():
|
146
|
+
return pd.read_csv('data.csv')
|
147
|
+
|
148
|
+
df = load_data()
|
149
|
+
|
150
|
+
# Sidebar filters
|
151
|
+
st.sidebar.header('Filters')
|
152
|
+
selected_columns = st.sidebar.multiselect('Select columns', df.columns.tolist())
|
153
|
+
|
154
|
+
# Main content
|
155
|
+
st.title('Exploratory Data Analysis')
|
156
|
+
st.dataframe(df[selected_columns] if selected_columns else df)
|
157
|
+
|
158
|
+
# Visualizations
|
159
|
+
if st.checkbox('Show correlation heatmap'):
|
160
|
+
fig = px.imshow(df.corr())
|
161
|
+
st.plotly_chart(fig)
|
162
|
+
```
|
163
|
+
|
164
|
+
### Contoh 2: Machine Learning Dashboard
|
165
|
+
|
166
|
+
```python
|
167
|
+
# app_ml.py
|
168
|
+
import streamlit as st
|
169
|
+
import pandas as pd
|
170
|
+
from sklearn.model_selection import train_test_split
|
171
|
+
from sklearn.ensemble import RandomForestClassifier
|
172
|
+
import matplotlib.pyplot as plt
|
173
|
+
|
174
|
+
st.title('Machine Learning Model Trainer')
|
175
|
+
|
176
|
+
# Upload data
|
177
|
+
uploaded_file = st.file_uploader("Upload your dataset", type=['csv'])
|
178
|
+
if uploaded_file:
|
179
|
+
df = pd.read_csv(uploaded_file)
|
180
|
+
|
181
|
+
# Model training interface
|
182
|
+
target = st.selectbox('Select target variable', df.columns)
|
183
|
+
features = st.multiselect('Select features', df.columns.drop(target))
|
184
|
+
|
185
|
+
if st.button('Train Model'):
|
186
|
+
X = df[features]
|
187
|
+
y = df[target]
|
188
|
+
|
189
|
+
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2)
|
190
|
+
|
191
|
+
model = RandomForestClassifier()
|
192
|
+
model.fit(X_train, y_train)
|
193
|
+
|
194
|
+
accuracy = model.score(X_test, y_test)
|
195
|
+
st.success(f'Model accuracy: {accuracy:.2f}')
|
196
|
+
```
|
197
|
+
|
198
|
+
## 🏗️ Project Structure
|
199
|
+
|
200
|
+
```
|
201
|
+
my_streamlit_project/
|
202
|
+
├── apps/
|
203
|
+
│ ├── app_eda.py
|
204
|
+
│ ├── app_ml.py
|
205
|
+
│ └── app_dashboard.py
|
206
|
+
├── data/
|
207
|
+
│ └── dataset.csv
|
208
|
+
├── requirements.txt
|
209
|
+
└── README.md
|
210
|
+
```
|
211
|
+
|
212
|
+
## 📋 Dependencies
|
213
|
+
|
214
|
+
Package ini membutuhkan:
|
215
|
+
|
216
|
+
- **streamlit** >= 1.28.0
|
217
|
+
- **python** >= 3.7.0
|
218
|
+
- **click** >= 8.0.0
|
219
|
+
- **typing-extensions** >= 4.0.0
|
220
|
+
|
221
|
+
## 🐛 Troubleshooting
|
222
|
+
|
223
|
+
### Common Issues:
|
224
|
+
|
225
|
+
1. **Port already in use:**
|
226
|
+
```bash
|
227
|
+
launcher --port 8502
|
228
|
+
```
|
229
|
+
|
230
|
+
2. **Module not found:**
|
231
|
+
```bash
|
232
|
+
pip install --upgrade launcher
|
233
|
+
```
|
234
|
+
|
235
|
+
3. **Permission issues:**
|
236
|
+
```bash
|
237
|
+
pip install --user launcher
|
238
|
+
```
|
239
|
+
|
240
|
+
### Debug Mode:
|
241
|
+
|
242
|
+
```bash
|
243
|
+
# Enable debug mode
|
244
|
+
launcher --debug true
|
245
|
+
|
246
|
+
# Atau set environment variable
|
247
|
+
export STREAMLIT_DEBUG=true
|
248
|
+
```
|
249
|
+
|
250
|
+
## 🤝 Contributing
|
251
|
+
|
252
|
+
Kontribusi dipersilakan! Silakan:
|
253
|
+
|
254
|
+
1. Fork repository
|
255
|
+
2. Buat feature branch (`git checkout -b feature/AmazingFeature`)
|
256
|
+
3. Commit changes (`git commit -m 'Add AmazingFeature'`)
|
257
|
+
4. Push to branch (`git push origin feature/AmazingFeature`)
|
258
|
+
5. Open Pull Request
|
259
|
+
|
260
|
+
## 📄 License
|
261
|
+
|
262
|
+
Distributed under the MIT License. See `LICENSE` for more information.
|
263
|
+
|
264
|
+
## 🔗 Links
|
265
|
+
|
266
|
+
- [PyPI Package](https://pypi.org/project/launcher/)
|
267
|
+
- [GitHub Repository](https://github.com/royhtml/streamlit-launcher)
|
268
|
+
- [Streamlit Documentation](https://docs.streamlit.io/)
|
269
|
+
- [Issue Tracker](https://github.com/royhtml/streamlit-launcher/issues)
|
270
|
+
|
271
|
+
## 📞 Support
|
272
|
+
|
273
|
+
Jika ada pertanyaan atau issues, silakan:
|
274
|
+
|
275
|
+
1. Check [documentation](https://github.com/royhtml/streamlit-launcher)
|
276
|
+
2. Search [existing issues](https://github.com/royhtml/streamlit-launcher/issues)
|
277
|
+
3. Create [new issue](https://github.com/royhtml/streamlit-launcher/issues/new)
|
278
|
+
|
279
|
+
---
|
280
|
+
|
281
|
+
**⭐ Jangan lupa memberikan bintang di GitHub jika tool ini membantu!**
|
@@ -0,0 +1,45 @@
|
|
1
|
+
from setuptools import setup, find_packages
|
2
|
+
import os
|
3
|
+
|
4
|
+
# Baca README dengan encoding UTF-8
|
5
|
+
here = os.path.abspath(os.path.dirname(__file__))
|
6
|
+
with open(os.path.join(here, 'README.md'), 'r', encoding='utf-8') as f:
|
7
|
+
long_description = f.read()
|
8
|
+
|
9
|
+
setup(
|
10
|
+
name="streamlit_launcher",
|
11
|
+
version="2.0.0",
|
12
|
+
author="Dwi Bakti N Dev",
|
13
|
+
author_email="dwibakti76@gmail.com",
|
14
|
+
description="Analisis Date Scient Simple and Instant",
|
15
|
+
long_description=long_description,
|
16
|
+
long_description_content_type="text/markdown",
|
17
|
+
url="https://github.com/royhtml",
|
18
|
+
project_urls={
|
19
|
+
"Profile": "https://profiledwibaktindev.netlify.app/",
|
20
|
+
"ich.io": "https://royhtml.itch.io/",
|
21
|
+
"Facebook": "https://www.facebook.com/Royhtml",
|
22
|
+
"Webtoons": "https://www.webtoons.com/id/canvas/mariadb-hari-senin/episode-4-coding-championship/viewer?title_no=1065164&episode_no=4",
|
23
|
+
},
|
24
|
+
packages=find_packages(exclude=['tests*']),
|
25
|
+
install_requires=[
|
26
|
+
"pillow>=8.0",
|
27
|
+
"pyinstaller>=4.0",
|
28
|
+
"pyqt5>=5.15",
|
29
|
+
],
|
30
|
+
entry_points={
|
31
|
+
"gui_scripts": [
|
32
|
+
"streamlit_launcher=streamlit_launcher.cli:main",
|
33
|
+
],
|
34
|
+
},
|
35
|
+
include_package_data=True,
|
36
|
+
package_data={
|
37
|
+
"webscan": ["*.ico", "*.png"],
|
38
|
+
},
|
39
|
+
classifiers=[
|
40
|
+
"Programming Language :: Python :: 3",
|
41
|
+
"License :: OSI Approved :: MIT License",
|
42
|
+
"Operating System :: OS Independent",
|
43
|
+
],
|
44
|
+
python_requires=">=3.6",
|
45
|
+
)
|