LPX55 commited on
Commit
5c2bf26
·
1 Parent(s): e2d09ed

refactor: update consensus display in full_prediction function for improved readability

Browse files
Files changed (1) hide show
  1. app.py +1 -2
app.py CHANGED
@@ -361,10 +361,9 @@ def full_prediction(img, confidence_threshold, rotate_degrees, noise_level, shar
361
  ]
362
  anomaly_detection_results = anomaly_agent.analyze_forensic_outputs(forensic_output_descriptions)
363
  logger.info(f"Forensic anomaly detection: {anomaly_detection_results['summary']}")
364
- consensus_html = f"<b><span style='color:{'red' if final_prediction_label == 'AI' else ('green' if final_prediction_label == 'REAL' else 'orange')}'>{final_prediction_label}</span></b>"
365
  inference_params = {
366
  "confidence_threshold": confidence_threshold,
367
- "augment_methods": ["rotate", "add_noise", "sharpen"],
368
  "rotate_degrees": rotate_degrees,
369
  "noise_level": noise_level,
370
  "sharpen_strength": sharpen_strength,
 
361
  ]
362
  anomaly_detection_results = anomaly_agent.analyze_forensic_outputs(forensic_output_descriptions)
363
  logger.info(f"Forensic anomaly detection: {anomaly_detection_results['summary']}")
364
+ consensus_html = f"<div style='font-size: 2.2em; font-weight: bold;padding: 10px;'>Consensus: <span style='color:{'red' if final_prediction_label == 'AI' else ('green' if final_prediction_label == 'REAL' else 'orange')}'>{final_prediction_label}</span></div>"
365
  inference_params = {
366
  "confidence_threshold": confidence_threshold,
 
367
  "rotate_degrees": rotate_degrees,
368
  "noise_level": noise_level,
369
  "sharpen_strength": sharpen_strength,