Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -20,8 +20,10 @@ os.environ["PATH"] = conda_bin + os.pathsep + os.environ["PATH"]
|
|
20 |
# Activate the base environment (adjust if needed)
|
21 |
os.system(f'{conda_bin}/conda init --all')
|
22 |
os.system(f'{conda_bin}/conda activate base')
|
|
|
23 |
os.system(f'{conda_bin}/conda install nvidia/label/cuda-12.4.0::cuda-cudart-dev')
|
24 |
os.system(f'{conda_bin}/conda install nvidia/label/cuda-12.4.0::cuda-nvcc')
|
|
|
25 |
|
26 |
import random
|
27 |
import uuid
|
@@ -187,8 +189,8 @@ def load_and_prepare_model():
|
|
187 |
|
188 |
return pipe
|
189 |
|
190 |
-
hidet.option.parallel_build(
|
191 |
-
|
192 |
#hidet.torch.dynamo_config.steal_weights(False)
|
193 |
torch._dynamo.config.suppress_errors = True
|
194 |
torch._dynamo.disallow_in_graph(diffusers.models.attention.BasicTransformerBlock)
|
|
|
20 |
# Activate the base environment (adjust if needed)
|
21 |
os.system(f'{conda_bin}/conda init --all')
|
22 |
os.system(f'{conda_bin}/conda activate base')
|
23 |
+
os.system(f'{conda_bin}/conda install nvidia/label/cuda-12.4.0::cuda-cudart')
|
24 |
os.system(f'{conda_bin}/conda install nvidia/label/cuda-12.4.0::cuda-cudart-dev')
|
25 |
os.system(f'{conda_bin}/conda install nvidia/label/cuda-12.4.0::cuda-nvcc')
|
26 |
+
#os.system(f'{conda_bin}/conda install pytorch::pytorch-cuda')
|
27 |
|
28 |
import random
|
29 |
import uuid
|
|
|
189 |
|
190 |
return pipe
|
191 |
|
192 |
+
hidet.option.parallel_build(True)
|
193 |
+
hidet.option.parallel_tune(-1,1.75)
|
194 |
#hidet.torch.dynamo_config.steal_weights(False)
|
195 |
torch._dynamo.config.suppress_errors = True
|
196 |
torch._dynamo.disallow_in_graph(diffusers.models.attention.BasicTransformerBlock)
|