LPX commited on
Commit
aa96f77
·
1 Parent(s): 88d2155

refactor: still in progress

Browse files

- Moved the debug JSON output into the accordion for better organization in the UI.
- Added `tf-keras` to requirements.txt to support TensorFlow Keras functionalities.

Files changed (2) hide show
  1. app_mcp.py +3 -5
  2. requirements.txt +1 -0
app_mcp.py CHANGED
@@ -20,7 +20,7 @@ from forensics.registry import register_model, MODEL_REGISTRY, ModelEntry
20
 
21
 
22
  # Configure logging
23
- logging.basicConfig(level=logging.INFO)
24
  logger = logging.getLogger(__name__)
25
 
26
 
@@ -304,10 +304,8 @@ with gr.Blocks(css="#post-gallery { overflow: hidden !important;} .grid-wrap{ ov
304
  datatype=["str", "str", "number", "number", "str"]
305
  )
306
  forensics_gallery = gr.Gallery(label="Post Processed Images", visible=True, columns=[4], rows=[2], container=False, height="auto", object_fit="contain", elem_id="post-gallery")
307
- debug_json = gr.JSON(label="Raw Model Results")
308
- debug_accordion = gr.Accordion("Debug Output (Raw JSON)", open=False)
309
- with debug_accordion:
310
- debug_json.render()
311
 
312
  outputs = [image_output, forensics_gallery, results_table, debug_json]
313
 
 
20
 
21
 
22
  # Configure logging
23
+ logging.basicConfig(level=logging.DEBUG)
24
  logger = logging.getLogger(__name__)
25
 
26
 
 
304
  datatype=["str", "str", "number", "number", "str"]
305
  )
306
  forensics_gallery = gr.Gallery(label="Post Processed Images", visible=True, columns=[4], rows=[2], container=False, height="auto", object_fit="contain", elem_id="post-gallery")
307
+ with gr.Accordion("Debug Output (Raw JSON)", open=False):
308
+ debug_json = gr.JSON(label="Raw Model Results")
 
 
309
 
310
  outputs = [image_output, forensics_gallery, results_table, debug_json]
311
 
requirements.txt CHANGED
@@ -9,3 +9,4 @@ pillow
9
  opencv-python
10
  modelscope_studio
11
  pydantic==2.10.6
 
 
9
  opencv-python
10
  modelscope_studio
11
  pydantic==2.10.6
12
+ tf-keras