gutris1 commited on
Commit
5d4efb7
·
verified ·
1 Parent(s): 56d62a1

Delete asd

Browse files
Files changed (1) hide show
  1. asd/setup.py +0 -514
asd/setup.py DELETED
@@ -1,514 +0,0 @@
1
- from IPython.display import display, Image, clear_output
2
- from IPython import get_ipython
3
- from ipywidgets import widgets
4
- from pathlib import Path
5
- import subprocess
6
- import argparse
7
- import shlex
8
- import json
9
- import sys
10
- import os
11
- import re
12
-
13
- CD = os.chdir
14
- iRON = os.environ
15
- SyS = get_ipython().system
16
-
17
- REPO = {
18
- 'A1111': 'https://github.com/gutris1/A1111',
19
- 'Forge': 'https://github.com/lllyasviel/stable-diffusion-webui-forge Forge',
20
- 'ReForge': 'https://github.com/Panchovix/stable-diffusion-webui-reForge ReForge',
21
- 'ReForge-old': '-b main-old https://github.com/Panchovix/stable-diffusion-webui-reForge ReForge-old',
22
- 'Forge-Classic': '-b classic https://github.com/Haoming02/sd-webui-forge-classic Forge-Classic',
23
- 'Forge-Neo': '-b neo https://github.com/Haoming02/sd-webui-forge-classic Forge-Neo',
24
- 'ComfyUI': 'https://github.com/comfyanonymous/ComfyUI',
25
- 'SwarmUI': 'https://github.com/mcmonkeyprojects/SwarmUI'
26
- }
27
-
28
- WEBUI_LIST = ['A1111', 'Forge', 'ReForge', 'ReForge-old', 'Forge-Classic', 'Forge-Neo', 'ComfyUI', 'SwarmUI']
29
-
30
- def getENV():
31
- env = {
32
- 'Colab': ('/content', '/content', 'COLAB_JUPYTER_TOKEN'),
33
- 'Kaggle': ('/kaggle', '/kaggle/working', 'KAGGLE_DATA_PROXY_TOKEN')
34
- }
35
- for name, (base, home, var) in env.items():
36
- if var in iRON: return name, base, home
37
- return None, None, None
38
-
39
- def getArgs():
40
- parser = argparse.ArgumentParser(description='WebUI Installer Script for Kaggle and Google Colab')
41
- parser.add_argument('--webui', required=True, help='available webui: A1111, Forge, ReForge, ReForge-old, Forge-Classic, Forge-Neo, ComfyUI, SwarmUI')
42
- parser.add_argument('--civitai_key', required=True, help='your CivitAI API key')
43
- parser.add_argument('--hf_read_token', default=None, help='your Huggingface READ Token (optional)')
44
-
45
- args, unknown = parser.parse_known_args()
46
-
47
- arg1 = args.webui.lower()
48
- arg2 = args.civitai_key.strip()
49
- arg3 = args.hf_read_token.strip() if args.hf_read_token else ''
50
-
51
- if not any(arg1 == option.lower() for option in WEBUI_LIST):
52
- print(f'{ERROR}: invalid webui option: "{args.webui}"')
53
- print(f'Available webui options: {", ".join(WEBUI_LIST)}')
54
- return None, None, None
55
-
56
- if not arg2:
57
- print(f'{ERROR}: CivitAI API key is missing.')
58
- return None, None, None
59
- if re.search(r'\s+', arg2):
60
- print(f'{ERROR}: CivitAI API key contains spaces "{arg2}" - not allowed.')
61
- return None, None, None
62
- if len(arg2) < 32:
63
- print(f'{ERROR}: CivitAI API key must be at least 32 characters long.')
64
- return None, None, None
65
-
66
- if not arg3: arg3 = ''
67
- if re.search(r'\s+', arg3): arg3 = ''
68
-
69
- selected_ui = next(option for option in WEBUI_LIST if arg1 == option.lower())
70
- return selected_ui, arg2, arg3
71
-
72
- def getPython():
73
- global PYV
74
-
75
- cs = {
76
- 'v': '3.13.12',
77
- 'url': 'https://huggingface.co/gutris1/webui/resolve/main/env/KC-ComfyUI-SwarmUI-Python31312-Torch2100-cu130.tar.lz4'
78
- }
79
-
80
- c = {
81
- 'default': {
82
- 'v': '3.10.15',
83
- 'url': 'https://huggingface.co/gutris1/webui/resolve/main/env/KC-Python310-Torch260-cu124.tar.lz4'
84
- },
85
-
86
- 'ComfyUI': cs,
87
- 'SwarmUI': cs,
88
-
89
- 'ReForge': {
90
- 'v': '3.12.13',
91
- 'url': 'https://huggingface.co/gutris1/webui/resolve/main/env/KC-ReForge-Python31213-Torch2110-cu130.tar.lz4'
92
- },
93
-
94
- 'Forge-Classic': {
95
- 'v': '3.11.13',
96
- 'url': 'https://huggingface.co/gutris1/webui/resolve/main/env/KC-FC-Python311-Torch260-cu124.tar.lz4'
97
- },
98
-
99
- 'Forge-Neo': {
100
- 'v': '3.13.12',
101
- 'url': 'https://huggingface.co/gutris1/webui/resolve/main/env/KC-FN-Python3-13-12-Torch2100-cu130.tar.lz4'
102
- }
103
- }
104
-
105
- cfg = c.get(webui, c['default'])
106
- v = '.'.join(cfg['v'].split('.')[:2])
107
- PYV = v
108
-
109
- BIN = str(PY / 'bin')
110
- PKG = str(PY / f'lib/python{v}/site-packages')
111
- fn = Path(cfg['url']).name
112
-
113
- CD(Path(ENVBASE).parent)
114
- print(f"\n{ARROW} installing Python Portable {cfg['v']}")
115
-
116
- SyS('sudo apt-get -qq -y install aria2 pv lz4 > /dev/null 2>&1')
117
-
118
- aria = f'aria2c --console-log-level=error --stderr=true -c -x16 -s16 -k1M -j5 {cfg["url"]} -o {fn}'
119
- p = subprocess.Popen(shlex.split(aria), stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
120
- p.wait()
121
-
122
- SyS(f'pv {fn} | lz4 -d | tar -xf -')
123
- Path(f'/{fn}').unlink()
124
-
125
- sys.path.insert(0, PKG)
126
- if BIN not in iRON['PATH']:
127
- iRON['PATH'] = BIN + ':' + iRON['PATH']
128
- if PKG not in iRON['PYTHONPATH']:
129
- iRON['PYTHONPATH'] = PKG + ':' + iRON['PYTHONPATH']
130
-
131
- if ENVNAME == 'Kaggle':
132
- for cmd in [
133
- 'pip install ipywidgets jupyterlab_widgets --upgrade',
134
- 'rm -f /usr/lib/python3.10/sitecustomize.py'
135
- ]:
136
- SyS(f'{cmd} > /dev/null 2>&1')
137
-
138
- def marking(p, n, u):
139
- t = p / n
140
- v = {'ui': u, 'launch_args': '', 'tunnel': ''}
141
-
142
- if not t.exists(): t.write_text(json.dumps(v, indent=4))
143
-
144
- d = json.loads(t.read_text())
145
- d.update(v)
146
- t.write_text(json.dumps(d, indent=4))
147
-
148
- def key_inject(C, H):
149
- p = Path(nenen)
150
- v = p.read_text()
151
- v = v.replace("TOKET = ''", f"TOKET = '{C}'")
152
- v = v.replace("TOBRUT = ''", f"TOBRUT = '{H}'")
153
- p.write_text(v)
154
-
155
- def install_tunnel():
156
- SyS(f'wget -qO {USR}/cl https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-amd64')
157
- SyS(f'chmod +x {USR}/cl')
158
-
159
- bins = {
160
- 'zrok': {
161
- 'bin': USR / 'zrok',
162
- 'url': 'https://github.com/openziti/zrok/releases/download/v1.0.6/zrok_1.0.6_linux_amd64.tar.gz'
163
- },
164
- 'ngrok': {
165
- 'bin': USR / 'ngrok',
166
- 'url': 'https://bin.ngrok.com/c/bNyj1mQVY4c/ngrok-v3-stable-linux-amd64.tgz'
167
- }
168
- }
169
-
170
- for n, b in bins.items():
171
- if b['bin'].exists(): b['bin'].unlink()
172
-
173
- url = b['url']
174
- name = Path(url).name
175
-
176
- SyS(f'wget -qO {name} {url}')
177
- SyS(f'tar -xzf {name} -C {USR}')
178
- SyS(f'rm -f {name}')
179
-
180
- def sym_link(U, M):
181
- configs = {
182
- 'A1111': {
183
- 'sym': [
184
- f"rm -rf {M / 'Stable-diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'ControlNet'} {TMP}/*"
185
- ],
186
- 'links': [
187
- (TMP / 'ckpt', M / 'Stable-diffusion/tmp_ckpt'),
188
- (TMP / 'lora', M / 'Lora/tmp_lora'),
189
- (TMP / 'controlnet', M / 'ControlNet')
190
- ]
191
- },
192
-
193
- 'Forge': {
194
- 'sym': [
195
- f"rm -rf {M / 'Stable-diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'ControlNet'}",
196
- f"rm -rf {M / 'svd'} {M / 'z123'} {M / 'clip'} {M / 'clip_vision'} {M / 'diffusers'}",
197
- f"rm -rf {M / 'diffusion_models'} {M / 'text_encoder'} {M / 'unet'} {TMP}/*"
198
- ],
199
- 'links': [
200
- (TMP / 'ckpt', M / 'Stable-diffusion/tmp_ckpt'),
201
- (TMP / 'lora', M / 'Lora/tmp_lora'),
202
- (TMP / 'controlnet', M / 'ControlNet'),
203
- (TMP / 'z123', M / 'z123'),
204
- (TMP / 'svd', M / 'svd'),
205
- (TMP / 'clip', M / 'clip'),
206
- (TMP / 'clip_vision', M / 'clip_vision'),
207
- (TMP / 'diffusers', M / 'diffusers'),
208
- (TMP / 'diffusion_models', M / 'diffusion_models'),
209
- (TMP / 'text_encoders', M / 'text_encoder'),
210
- (TMP / 'unet', M / 'unet')
211
- ]
212
- },
213
-
214
- 'ReForge': {
215
- 'sym': [
216
- f"rm -rf {M / 'Stable-diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'ControlNet'}",
217
- f"rm -rf {M / 'svd'} {M / 'z123'} {TMP}/*"
218
- ],
219
- 'links': [
220
- (TMP / 'ckpt', M / 'Stable-diffusion/tmp_ckpt'),
221
- (TMP / 'lora', M / 'Lora/tmp_lora'),
222
- (TMP / 'controlnet', M / 'ControlNet'),
223
- (TMP / 'z123', M / 'z123'),
224
- (TMP / 'svd', M / 'svd')
225
- ]
226
- },
227
-
228
- 'ReForge-old': {
229
- 'sym': [
230
- f"rm -rf {M / 'Stable-diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'ControlNet'}",
231
- f"rm -rf {M / 'svd'} {M / 'z123'} {TMP}/*"
232
- ],
233
- 'links': [
234
- (TMP / 'ckpt', M / 'Stable-diffusion/tmp_ckpt'),
235
- (TMP / 'lora', M / 'Lora/tmp_lora'),
236
- (TMP / 'controlnet', M / 'ControlNet'),
237
- (TMP / 'z123', M / 'z123'),
238
- (TMP / 'svd', M / 'svd')
239
- ]
240
- },
241
-
242
- 'Forge-Classic': {
243
- 'sym': [
244
- f"rm -rf {M / 'Stable-diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'ControlNet'}"
245
- ],
246
- 'links': [
247
- (TMP / 'ckpt', M / 'Stable-diffusion/tmp_ckpt'),
248
- (TMP / 'lora', M / 'Lora/tmp_lora'),
249
- (TMP / 'controlnet', M / 'ControlNet')
250
- ]
251
- },
252
-
253
- 'Forge-Neo': {
254
- 'sym': [
255
- f"rm -rf {M / 'Stable-diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'ControlNet'}"
256
- ],
257
- 'links': [
258
- (TMP / 'ckpt', M / 'Stable-diffusion/tmp_ckpt'),
259
- (TMP / 'lora', M / 'Lora/tmp_lora'),
260
- (TMP / 'controlnet', M / 'ControlNet')
261
- ]
262
- },
263
-
264
- 'ComfyUI': {
265
- 'sym': [
266
- f"rm -rf {M / 'checkpoints/tmp_ckpt'} {M / 'loras/tmp_lora'} {M / 'controlnet'}",
267
- f"rm -rf {M / 'clip'} {M / 'clip_vision'} {M / 'diffusers'} {M / 'diffusion_models'}",
268
- f"rm -rf {M / 'text_encoders'} {M / 'unet'} {TMP}/*"
269
- ],
270
- 'links': [
271
- (TMP / 'ckpt', M / 'checkpoints/tmp_ckpt'),
272
- (TMP / 'lora', M / 'loras/tmp_lora'),
273
- (TMP / 'controlnet', M / 'controlnet'),
274
- (TMP / 'clip', M / 'clip'),
275
- (TMP / 'clip_vision', M / 'clip_vision'),
276
- (TMP / 'diffusers', M / 'diffusers'),
277
- (TMP / 'diffusion_models', M / 'diffusion_models'),
278
- (TMP / 'text_encoders', M / 'text_encoders'),
279
- (TMP / 'unet', M / 'unet')
280
- ]
281
- },
282
-
283
- 'SwarmUI': {
284
- 'sym': [
285
- f"rm -rf {M / 'Stable-Diffusion/tmp_ckpt'} {M / 'Lora/tmp_lora'} {M / 'controlnet'}",
286
- f"rm -rf {M / 'clip'} {M / 'unet'} {TMP}/*"
287
- ],
288
- 'links': [
289
- (TMP / 'ckpt', M / 'Stable-Diffusion/tmp_ckpt'),
290
- (TMP / 'lora', M / 'Lora/tmp_lora'),
291
- (TMP / 'controlnet', M / 'controlnet'),
292
- (TMP / 'clip', M / 'clip'),
293
- (TMP / 'unet', M / 'unet')
294
- ]
295
- }
296
- }
297
-
298
- cfg = configs.get(U)
299
- [SyS(f'{cmd}') for cmd in cfg['sym']]
300
- if U not in ['ComfyUI', 'SwarmUI']: [(M / d).mkdir(parents=True, exist_ok=True) for d in ['Lora', 'ESRGAN']]
301
- [SyS(f'ln -s {src} {tg}') for src, tg in cfg['links']]
302
-
303
- def webui_req(U, W, M):
304
- CD(W)
305
-
306
- if U != 'SwarmUI':
307
- pull(f'https://github.com/gutris1/segsmaker {U.lower()} {W}')
308
- else:
309
- M.mkdir(parents=True, exist_ok=True)
310
- for sub in ['Stable-Diffusion', 'Lora', 'Embeddings', 'VAE', 'upscale_models']:
311
- (M / sub).mkdir(parents=True, exist_ok=True)
312
-
313
- download(f'https://dot.net/v1/dotnet-install.sh {W}')
314
- dotnet = W / 'dotnet-install.sh'
315
- dotnet.chmod(0o755)
316
- SyS('bash ./dotnet-install.sh --channel 8.0')
317
-
318
- sym_link(U, M)
319
- install_tunnel()
320
-
321
- scripts = [
322
- f'https://github.com/gutris1/segsmaker/raw/main/script/controlnet.py {W}/asd',
323
- f'https://github.com/gutris1/segsmaker/raw/main/script/KC/segsmaker.py {W}'
324
- ]
325
-
326
- u = M / 'upscale_models' if U in ['ComfyUI', 'SwarmUI'] else M / 'ESRGAN'
327
-
328
- upscalers = [
329
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/4x-UltraSharp.pth {u}',
330
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/4x-AnimeSharp.pth {u}',
331
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/4x_NMKD-Superscale-SP_178000_G.pth {u}',
332
- f'https://huggingface.co/uwg/upscaler/resolve/main/ESRGAN/8x_NMKD-Superscale_150000_G.pth {u}',
333
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/4x_RealisticRescaler_100000_G.pth {u}',
334
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/8x_RealESRGAN.pth {u}',
335
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/4x_foolhardy_Remacri.pth {u}',
336
- f'https://huggingface.co/subby2006/NMKD-YandereNeoXL/resolve/main/4x_NMKD-YandereNeoXL_200k.pth {u}',
337
- f'https://huggingface.co/subby2006/NMKD-UltraYandere/resolve/main/4x_NMKD-UltraYandere_300k.pth {u}'
338
- ]
339
-
340
- line = scripts + upscalers
341
- for item in line: download(item)
342
-
343
- if U not in ['SwarmUI', 'ComfyUI']:
344
- e = 'jpg' if U in ['Forge-Classic', 'Forge-Neo'] else 'png'
345
- SyS(f'rm -f {W}/html/card-no-preview.{e}')
346
-
347
- for ass in [
348
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/card-no-preview.png {W}/html card-no-preview.{e}',
349
- f'https://github.com/gutris1/segsmaker/raw/main/config/NoCrypt_miku.json {W}/tmp/gradio_themes',
350
- f'https://github.com/gutris1/segsmaker/raw/main/config/user.css {W} user.css'
351
- ]: download(ass)
352
-
353
- if U not in ['Forge', 'Forge-Neo']: download(f'https://github.com/gutris1/segsmaker/raw/main/config/config.json {W} config.json')
354
-
355
- def webui_extension(U, W, M):
356
- EXT = W / 'custom_nodes' if U == 'ComfyUI' else W / 'extensions'
357
- CD(EXT)
358
-
359
- if U == 'ComfyUI':
360
- say('<br><b>【{red} Installing Custom Nodes{d} 】{red}</b>')
361
- clone(str(W / 'asd/custom_nodes.txt'))
362
- print()
363
-
364
- for faces in [
365
- f'https://github.com/sczhou/CodeFormer/releases/download/v0.1.0/codeformer.pth {M}/facerestore_models',
366
- f'https://github.com/TencentARC/GFPGAN/releases/download/v1.3.4/GFPGANv1.4.pth {M}/facerestore_models'
367
- ]: download(faces)
368
-
369
- else:
370
- say('<br><b>【{red} Installing Extensions{d} 】{red}</b>')
371
- clone(str(W / 'asd/extension.txt'))
372
- if ENVNAME == 'Kaggle': clone('https://github.com/gutris1/sd-image-encryption')
373
-
374
- def webui_installation(U, W):
375
- M = W / 'Models' if U == 'SwarmUI' else W / 'models'
376
- E = M / 'Embeddings' if U == 'SwarmUI' else (M / 'embeddings' if U in ['Forge-Classic', 'Forge-Neo', 'ComfyUI'] else W / 'embeddings')
377
- V = M / 'vae' if U == 'ComfyUI' else M / 'VAE'
378
-
379
- webui_req(U, W, M)
380
-
381
- extras = [
382
- f'https://huggingface.co/gutris1/webui/resolve/main/misc/embeddingsXL.zip {W}',
383
- f'https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/resolve/main/sdxl.vae.safetensors {V} sdxl_vae.safetensors'
384
- ]
385
-
386
- for i in extras: download(i)
387
- SyS(f"unzip -qo {W / 'embeddingsXL.zip'} -d {E} && rm {W / 'embeddingsXL.zip'}")
388
-
389
- if U != 'SwarmUI': webui_extension(U, W, M)
390
-
391
- def webui_selection(ui):
392
- with output:
393
- output.clear_output(wait=True)
394
-
395
- if ui in REPO: (WEBUI, repo) = (HOME / ui, REPO[ui])
396
- say(f'<b>【{{red}} Installing {WEBUI.name}{{d}} 】{{red}}</b>')
397
- clone(repo)
398
-
399
- webui_installation(ui, WEBUI)
400
-
401
- with loading:
402
- loading.clear_output(wait=True)
403
- say('<br><b>【{red} Done{d} 】{red}</b>')
404
- tempe()
405
- CD(HOME)
406
-
407
- def webui_installer():
408
- branchs = {
409
- 'A1111': 'master',
410
- 'ComfyUI': 'master',
411
- 'SwarmUI': 'master',
412
- 'Forge': 'main',
413
- 'ReForge': 'main',
414
- 'ReForge-old': 'main-old',
415
- 'Forge-Classic': 'classic',
416
- 'Forge-Neo': 'neo',
417
- }
418
-
419
- CD(HOME)
420
- ui = (json.load(MARKED.open('r')) if MARKED.exists() else {}).get('ui')
421
- WEBUI = HOME / ui if ui else None
422
-
423
- if WEBUI is not None and WEBUI.exists():
424
- git_dir = WEBUI / '.git'
425
- if git_dir.exists():
426
- CD(WEBUI)
427
- with output:
428
- output.clear_output(wait=True)
429
- if ui in branchs: SyS(f'git pull origin {branchs[ui]}')
430
- with loading: loading.clear_output()
431
- else:
432
- try:
433
- webui_selection(webui)
434
- except KeyboardInterrupt:
435
- with loading: loading.clear_output()
436
- with output: print('\nCanceled.')
437
- except Exception as e:
438
- with loading: loading.clear_output()
439
- with output: print(f'\n{ERROR}: {e}')
440
-
441
- def notebook_scripts():
442
- z = [
443
- (STR / '00-startup.py', f'wget -qO {STR}/00-startup.py https://github.com/gutris1/segsmaker/raw/main/script/KC/00-startup.py'),
444
- (nenen, f'wget -qO {nenen} https://github.com/gutris1/segsmaker/raw/main/script/nenen88.py'),
445
- (melon, f'wget -qO {melon} https://github.com/gutris1/segsmaker/raw/main/script/melon00.py'),
446
- (STR / 'cupang.py', f'wget -qO {STR}/cupang.py https://github.com/gutris1/segsmaker/raw/main/script/cupang.py'),
447
- (MRK, f'wget -qO {MRK} https://github.com/gutris1/segsmaker/raw/main/script/marking.py')
448
- ]
449
-
450
- [SyS(y) for x, y in z if not Path(x).exists()]
451
-
452
- j = {
453
- 'ENVNAME': ENVNAME,
454
- 'HOMEPATH': HOME,
455
- 'TEMPPATH': TMP,
456
- 'BASEPATH': Path(ENVBASE),
457
- 'PYV': PYV
458
- }
459
-
460
- text = '\n'.join(f"{k} = '{v}'" for k, v in j.items())
461
- Path(KANDANG).write_text(text)
462
-
463
- key_inject(civitai_key, hf_read_token)
464
- marking(SRC, MARKED, webui)
465
- sys.path.append(str(STR))
466
-
467
- for scripts in [nenen, melon, KANDANG, MRK]: get_ipython().run_line_magic('run', str(scripts))
468
-
469
- ENVNAME, ENVBASE, ENVHOME = getENV()
470
- PYV = None
471
-
472
- if not ENVNAME:
473
- print('You are not in Kaggle or Google Colab.\nExiting.')
474
- sys.exit()
475
-
476
- RESET = '\033[0m'
477
- RED = '\033[31m'
478
- PURPLE = '\033[38;5;135m'
479
- ORANGE = '\033[38;5;208m'
480
- ARROW = f'{ORANGE}▶{RESET}'
481
- ERROR = f'{PURPLE}[{RESET}{RED}ERROR{RESET}{PURPLE}]{RESET}'
482
- IMG = 'https://github.com/gutris1/segsmaker/raw/main/script/loading.png'
483
-
484
- HOME = Path(ENVHOME)
485
- TMP = Path(ENVBASE) / 'temp'
486
-
487
- PY = Path('/GUTRIS1')
488
- SRC = HOME / 'gutris1'
489
- MRK = SRC / 'marking.py'
490
- KEY = SRC / 'api-key.json'
491
- MARKED = SRC / 'marking.json'
492
-
493
- USR = Path('/usr/bin')
494
- STR = Path('/root/.ipython/profile_default/startup')
495
- nenen = STR / 'nenen88.py'
496
- melon = STR / 'melon00.py'
497
- KANDANG = STR / 'KANDANG.py'
498
-
499
- TMP.mkdir(parents=True, exist_ok=True)
500
- SRC.mkdir(parents=True, exist_ok=True)
501
-
502
- output = widgets.Output()
503
- loading = widgets.Output()
504
-
505
- webui, civitai_key, hf_read_token = getArgs()
506
- if civitai_key is None: sys.exit()
507
-
508
- display(output, loading)
509
- with loading: display(Image(url=IMG))
510
- with output: PY.exists() or getPython()
511
- notebook_scripts()
512
-
513
- from nenen88 import clone, say, download, tempe, pull
514
- webui_installer()