Spaces:
Build error
Build error
Delete app.py
Browse files
app.py
DELETED
|
@@ -1,17 +0,0 @@
|
|
| 1 |
-
import gradio as gr
|
| 2 |
-
from ansys_script import run_beam_analysis
|
| 3 |
-
|
| 4 |
-
def simulate_beam_stress():
|
| 5 |
-
# Call the APDL script to run the beam analysis
|
| 6 |
-
plot_path = run_beam_analysis()
|
| 7 |
-
return plot_path
|
| 8 |
-
|
| 9 |
-
# Create a Gradio interface
|
| 10 |
-
iface = gr.Interface(fn=simulate_beam_stress,
|
| 11 |
-
inputs=None, # No input required
|
| 12 |
-
outputs=gr.Image(type="filepath"),
|
| 13 |
-
title="ANSYS Beam Stress Analysis with Visualization",
|
| 14 |
-
description="This tool runs an ANSYS simulation for a beam under load and visualizes the stress distribution along the beam.")
|
| 15 |
-
|
| 16 |
-
# Launch the Gradio app
|
| 17 |
-
iface.launch()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|