nightfury commited on
Commit
925affe
1 Parent(s): 0ff0e56

Update app_t.py

Browse files
Files changed (1) hide show
  1. app_t.py +20 -18
app_t.py CHANGED
@@ -1,3 +1,5 @@
 
 
1
  import git
2
 
3
  git.Git("clipseg/").clone("https://github.com/ThereforeGames/txt2mask.git")
@@ -7,7 +9,7 @@ zf = ZipFile('clipseg-master.zip', 'r')
7
  zf.extractall('clipseg/')
8
  zf.close()
9
 
10
- import gradio as gr
11
 
12
  #download_and_extract_zip_file()
13
  #clone_github_repository()
@@ -15,30 +17,30 @@ import gradio as gr
15
  #with gr.Blocks() as demo:
16
  #demo.launch()
17
 
18
- import time
19
  #import git
20
 
21
  #git.Git("clipseg/").clone("https://github.com/ThereforeGames/txt2mask.git")
22
 
23
- from git import RemoteProgress
24
 
25
- class CloneProgress(RemoteProgress):
26
- def update(self, op_code, cur_count, max_count=None, message=''):
27
- if message:
28
- print(message)
29
 
30
- git_root='home/user/app/clipseg1'
31
- print('Cloning into %s' % git_root)
32
- git.Repo.clone_from('https://github.com/ThereforeGames/txt2mask.git', git_root,
33
- branch='master', progress=CloneProgress())
34
 
35
  #-------------
36
- import sys
37
- import os
38
 
39
- path = "home/user/app/clipseg"
40
- clone = "git clone https://github.com/ThereforeGames/txt2mask.git"
41
 
42
- os.system("sshpass -p your_password ssh user_name@your_localhost")
43
- os.chdir(path) # Specifying the path where the cloned project needs to be copied
44
- os.system(clone) # Cloning
 
1
+ import gradio as gr
2
+
3
  import git
4
 
5
  git.Git("clipseg/").clone("https://github.com/ThereforeGames/txt2mask.git")
 
9
  zf.extractall('clipseg/')
10
  zf.close()
11
 
12
+
13
 
14
  #download_and_extract_zip_file()
15
  #clone_github_repository()
 
17
  #with gr.Blocks() as demo:
18
  #demo.launch()
19
 
20
+ #import time
21
  #import git
22
 
23
  #git.Git("clipseg/").clone("https://github.com/ThereforeGames/txt2mask.git")
24
 
25
+ #from git import RemoteProgress
26
 
27
+ #class CloneProgress(RemoteProgress):
28
+ # def update(self, op_code, cur_count, max_count=None, message=''):
29
+ # if message:
30
+ # print(message)
31
 
32
+ #git_root='home/user/app/clipseg1'
33
+ #print('Cloning into %s' % git_root)
34
+ #git.Repo.clone_from('https://github.com/ThereforeGames/txt2mask.git', git_root,
35
+ # branch='master', progress=CloneProgress())
36
 
37
  #-------------
38
+ #import sys
39
+ #import os
40
 
41
+ #path = "home/user/app/clipseg"
42
+ #clone = "git clone https://github.com/ThereforeGames/txt2mask.git"
43
 
44
+ #os.system("sshpass -p your_password ssh user_name@your_localhost")
45
+ #os.chdir(path) # Specifying the path where the cloned project needs to be copied
46
+ #os.system(clone) # Cloning