Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -27,8 +27,8 @@ import numpy as np
|
|
27 |
from huggingface_hub import hf_hub_download, list_repo_files
|
28 |
|
29 |
# flash attention
|
30 |
-
import subprocess
|
31 |
-
subprocess.run('pip install flash-attn --no-build-isolation', env={'FLASH_ATTENTION_SKIP_CUDA_BUILD': "TRUE"}, shell=True)
|
32 |
|
33 |
# Define constants
|
34 |
DESCRIPTION = "[ShowUI Demo](https://huggingface.co/showlab/ShowUI-2B)"
|
@@ -55,7 +55,7 @@ model = Qwen2VLForConditionalGeneration.from_pretrained(
|
|
55 |
destination_folder,
|
56 |
torch_dtype=torch.bfloat16,
|
57 |
device_map="cpu",
|
58 |
-
attn_implementation="flash_attention_2",
|
59 |
)
|
60 |
|
61 |
# Load the processor
|
|
|
27 |
from huggingface_hub import hf_hub_download, list_repo_files
|
28 |
|
29 |
# flash attention
|
30 |
+
# import subprocess
|
31 |
+
# subprocess.run('pip install flash-attn --no-build-isolation', env={'FLASH_ATTENTION_SKIP_CUDA_BUILD': "TRUE"}, shell=True)
|
32 |
|
33 |
# Define constants
|
34 |
DESCRIPTION = "[ShowUI Demo](https://huggingface.co/showlab/ShowUI-2B)"
|
|
|
55 |
destination_folder,
|
56 |
torch_dtype=torch.bfloat16,
|
57 |
device_map="cpu",
|
58 |
+
# attn_implementation="flash_attention_2",
|
59 |
)
|
60 |
|
61 |
# Load the processor
|