Spaces:
Sleeping
Sleeping
Update anime_model.py
Browse files- anime_model.py +1 -2
anime_model.py
CHANGED
|
@@ -17,7 +17,6 @@ from diffusers import (
|
|
| 17 |
from settings import MAX_IMAGE_RESOLUTION, MAX_NUM_IMAGES
|
| 18 |
|
| 19 |
class Model:
|
| 20 |
-
MODEL_ID = "lllyasviel/Annotators"
|
| 21 |
|
| 22 |
def __init__(self):
|
| 23 |
print("Initializing base model: ", base_model_id, " with ", task_name)
|
|
@@ -170,7 +169,7 @@ class Model:
|
|
| 170 |
#if num_images > MAX_NUM_IMAGES:
|
| 171 |
# raise ValueError
|
| 172 |
#self.load("NormalBae")
|
| 173 |
-
model = NormalBaeDetector.from_pretrained(
|
| 174 |
torch.cuda.empty_cache()
|
| 175 |
gc.collect()
|
| 176 |
control_image = self.preprocess(
|
|
|
|
| 17 |
from settings import MAX_IMAGE_RESOLUTION, MAX_NUM_IMAGES
|
| 18 |
|
| 19 |
class Model:
|
|
|
|
| 20 |
|
| 21 |
def __init__(self):
|
| 22 |
print("Initializing base model: ", base_model_id, " with ", task_name)
|
|
|
|
| 169 |
#if num_images > MAX_NUM_IMAGES:
|
| 170 |
# raise ValueError
|
| 171 |
#self.load("NormalBae")
|
| 172 |
+
model = NormalBaeDetector.from_pretrained("lllyasviel/Annotators").to("cuda")
|
| 173 |
torch.cuda.empty_cache()
|
| 174 |
gc.collect()
|
| 175 |
control_image = self.preprocess(
|