liuhaotian commited on
Commit
d85229e
1 Parent(s): 7564980
Files changed (2) hide show
  1. app.py +5 -2
  2. requirements.txt +1 -2
app.py CHANGED
@@ -6,11 +6,14 @@ import subprocess
6
 
7
  import llava.serve.gradio_web_server as gws
8
 
 
 
 
9
 
10
  def start_controller():
11
  print("Starting the controller")
12
  controller_command = [
13
- "python",
14
  "-m",
15
  "llava.serve.controller",
16
  "--host",
@@ -29,7 +32,7 @@ def start_worker(model_path: str, bits=16):
29
  if bits != 16:
30
  model_name += f"-{bits}bit"
31
  worker_command = [
32
- "python",
33
  "-m",
34
  "llava.serve.model_worker",
35
  "--host",
 
6
 
7
  import llava.serve.gradio_web_server as gws
8
 
9
+ # Execute the pip install command with additional options
10
+ subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'flash-attn', '--no-build-isolation', '-U'])
11
+
12
 
13
  def start_controller():
14
  print("Starting the controller")
15
  controller_command = [
16
+ sys.executable,
17
  "-m",
18
  "llava.serve.controller",
19
  "--host",
 
32
  if bits != 16:
33
  model_name += f"-{bits}bit"
34
  worker_command = [
35
+ sys.executable,
36
  "-m",
37
  "llava.serve.model_worker",
38
  "--host",
requirements.txt CHANGED
@@ -1,2 +1 @@
1
- llava-torch
2
- flash-attn
 
1
+ llava-torch