Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -99,7 +99,7 @@ class MolmoCaptionProcessor:
|
|
99 |
device_map='auto'
|
100 |
)
|
101 |
|
102 |
-
@spaces.GPU
|
103 |
def generate_response(self, image: Image.Image, msg: str) -> str:
|
104 |
inputs = self.processor.process(
|
105 |
images=[image],
|
@@ -230,7 +230,7 @@ def update_prompt(images: List[Image.Image], task_type: str, custom_msg: str = N
|
|
230 |
return "", f"Error generating captions: {str(e)}"
|
231 |
|
232 |
|
233 |
-
@spaces.GPU
|
234 |
def generate_image(images: List[Image.Image], prompt: str, negative_prompt: str, num_inference_steps: int, guidance_scale: float,
|
235 |
denoise_mask: List[str], task_type: str, azimuth: str, elevation: str, distance: str, focal_length: float,
|
236 |
height: int = 1024, width: int = 1024, scale_factor: float = 1.0, scale_watershed: float = 1.0,
|
|
|
99 |
device_map='auto'
|
100 |
)
|
101 |
|
102 |
+
@spaces.GPU
|
103 |
def generate_response(self, image: Image.Image, msg: str) -> str:
|
104 |
inputs = self.processor.process(
|
105 |
images=[image],
|
|
|
230 |
return "", f"Error generating captions: {str(e)}"
|
231 |
|
232 |
|
233 |
+
@spaces.GPU
|
234 |
def generate_image(images: List[Image.Image], prompt: str, negative_prompt: str, num_inference_steps: int, guidance_scale: float,
|
235 |
denoise_mask: List[str], task_type: str, azimuth: str, elevation: str, distance: str, focal_length: float,
|
236 |
height: int = 1024, width: int = 1024, scale_factor: float = 1.0, scale_watershed: float = 1.0,
|