ThunderVVV commited on
Commit
01a3594
·
1 Parent(s): 4050875
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -6,7 +6,11 @@ import torch
6
  print(torch.__version__)
7
  print(torch.version.cuda)
8
 
9
- os.system('export DISPLAY=:0.0; Xvfb :0 -screen 0 640x480x24 &')
 
 
 
 
10
 
11
  # download model
12
  print("Downloading model weights")
 
6
  print(torch.__version__)
7
  print(torch.version.cuda)
8
 
9
+ os.system('mkdir -p /home/user/app/tmp/.X11-unix')
10
+ os.system('chmod 1777 /home/user/app/tmp/.X11-unix')
11
+ os.environ["TMPDIR"] = "/home/user/app/tmp"
12
+ os.environ["DISPLAY"] = ":0.0"
13
+ os.system('Xvfb :0 -screen 0 640x480x24 &')
14
 
15
  # download model
16
  print("Downloading model weights")