File size: 2,852 Bytes
0163a2c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
import launch

if not launch.is_installed("accelerate"):
    try:
        launch.run_pip("install accelerate", "requirements for accelerate")
    except Exception:
        print("Can't install accelerate. Please follow the readme to install manually")

if not launch.is_installed("diffusers"):
    try:
        launch.run_pip("install diffusers", "requirements for diffusers")
    except Exception:
        print("Can't install diffusers. Please follow the readme to install manually")

if not launch.is_installed("huggingface_hub"):
    try:
        launch.run_pip("install huggingface-hub", "requirements for huggingface_hub")
    except Exception:
        print("Can't install huggingface-hub. Please follow the readme to install manually")

if not launch.is_installed("numpy"):
    try:
        launch.run_pip("install numpy", "requirements for numpy")
    except Exception:
        print("Can't install numpy. Please follow the readme to install manually")

if not launch.is_installed("cv2"):
    try:
        launch.run_pip("install opencv-python", "requirements for cv2")
    except Exception:
        print("Can't install opencv-python. Please follow the readme to install manually")

if not launch.is_installed("PIL"):
    try:
        launch.run_pip("install Pillow", "requirements for PIL")
    except Exception:
        print("Can't install Pillow. Please follow the readme to install manually")

if not launch.is_installed("segment_anything"):
    try:
        launch.run_pip("install segment-anything", "requirements for segment_anything")
    except Exception:
        print("Can't install segment-anything. Please follow the readme to install manually")

if not launch.is_installed("transformers"):
    try:
        launch.run_pip("install transformers", "requirements for transformers")
    except Exception:
        print("Can't install transformers. Please follow the readme to install manually")

if not launch.is_installed("lama_cleaner"):
    try:
        launch.run_pip("install lama-cleaner", "requirements for lama_cleaner")
    except Exception:
        print("Can't install lama-cleaner. Please follow the readme to install manually")

if not launch.is_installed("ultralytics"):
    try:
        launch.run_pip("install ultralytics", "requirements for ultralytics")
    except Exception:
        print("Can't install ultralytics. Please follow the readme to install manually")

if not launch.is_installed("tqdm"):
    try:
        launch.run_pip("install tqdm", "requirements for tqdm")
    except Exception:
        print("Can't install tqdm. Please follow the readme to install manually")

if not launch.is_installed("packaging"):
    try:
        launch.run_pip("install packaging", "requirements for packaging")
    except Exception:
        print("Can't install packaging. Please follow the readme to install manually")