Spaces:
Sleeping
Sleeping
Update app.py
Browse files226 unmodified lines2272282292302302312322331 unmodified line23523623723823924023823924024124224324435 unmodified lines280281282282283226 unmodified lines
summary = f"## Grade: {grade} — {total_score}/100\n\n"
summary += "**Top Attention Areas:**\n" summary += "**Where Attention Goes First:**\n" if zones: for z in zones: summary += f"- {z['position'].replace('-', ' ').title()} ({z['intensity']}/100 intensity, {z['area_pct']}% of design)\n"1 unmodified line summary += "- Attention is fairly even across the design, no strong single hotspot.\n"
summary += ( f"\n**Scores:** Focus {scores['focus_score']}/100 • " f"Spread {scores['spread_score']}/100 • " f"Readability: " f"\n**Scores:**\n" f"- Clear Focal Point: {scores['focus_score']}/100 (how strongly attention lands on one main spot, vs scattered everywhere)\n" f"- Attention Coverage: {scores['spread_score']}/100 (how much of the whole design draws some interest, not just one hotspot)\n" f"- Readability: " ) if read['words_checked'] == 0: summary += "no text detected\n"35 unmodified lines text_output = gr.Markdown() analyze_btn.click(fn=analyze, inputs=[image_input, strength_slider], outputs=[image_output, text_output])
demo.launch()demo.launch()app.py+6-5