change theme; set ultra resolution_level
Browse files
app.py
CHANGED
@@ -82,7 +82,7 @@ def main(share: bool, pretrained_model_name_or_path: str, model_version: str, us
|
|
82 |
|
83 |
height, width = image.shape[:2]
|
84 |
|
85 |
-
resolution_level_int = {'Low': 0, 'Medium': 5, 'High': 9, 'Ultra':
|
86 |
output = run_with_gpu(image, resolution_level_int, apply_mask)
|
87 |
|
88 |
points, depth, mask, normal = output['points'], output['depth'], output['mask'], output.get('normal', None)
|
@@ -225,7 +225,7 @@ def main(share: bool, pretrained_model_name_or_path: str, model_version: str, us
|
|
225 |
return [image, measure_points, depth_text]
|
226 |
|
227 |
print("Create Gradio app...")
|
228 |
-
with gr.Blocks() as demo:
|
229 |
gr.Markdown(
|
230 |
f'''
|
231 |
<div align="center">
|
|
|
82 |
|
83 |
height, width = image.shape[:2]
|
84 |
|
85 |
+
resolution_level_int = {'Low': 0, 'Medium': 5, 'High': 9, 'Ultra': 30}.get(resolution_level, 9)
|
86 |
output = run_with_gpu(image, resolution_level_int, apply_mask)
|
87 |
|
88 |
points, depth, mask, normal = output['points'], output['depth'], output['mask'], output.get('normal', None)
|
|
|
225 |
return [image, measure_points, depth_text]
|
226 |
|
227 |
print("Create Gradio app...")
|
228 |
+
with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
229 |
gr.Markdown(
|
230 |
f'''
|
231 |
<div align="center">
|