Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -119,9 +119,7 @@ from simulation_scripts_orbmol import (
|
|
| 119 |
# ========== Wrappers MD / Relax (con firma correcta) ==========
|
| 120 |
def md_wrapper(structure_file, charge, spin, steps, tempK, timestep_fs, ensemble):
|
| 121 |
"""
|
| 122 |
-
Llama a tu run_md_simulation con
|
| 123 |
-
(structure_file, num_steps, num_prerelax_steps, md_timestep, temperature_k, md_ensemble,
|
| 124 |
-
task_name='OMol', total_charge=..., spin_multiplicity=...)
|
| 125 |
"""
|
| 126 |
try:
|
| 127 |
if not structure_file:
|
|
@@ -150,8 +148,7 @@ def md_wrapper(structure_file, charge, spin, steps, tempK, timestep_fs, ensemble
|
|
| 150 |
|
| 151 |
def relax_wrapper(structure_file, steps, fmax, charge, spin, relax_cell):
|
| 152 |
"""
|
| 153 |
-
|
| 154 |
-
(structure_file, num_steps, fmax, task_name='OMol', total_charge=..., spin_multiplicity=..., relax_unit_cell=...)
|
| 155 |
"""
|
| 156 |
try:
|
| 157 |
if not structure_file:
|
|
@@ -223,7 +220,7 @@ with gr.Blocks(theme=gr.themes.Ocean(), title="OrbMol Demo") as demo:
|
|
| 223 |
with gr.Column(variant="panel", min_width=520):
|
| 224 |
md_status = gr.Textbox(label="MD Status", interactive=False)
|
| 225 |
md_traj = gr.File(label="Trajectory (.traj)", interactive=False)
|
| 226 |
-
md_html = gr.HTML(label="Trajectory Viewer"
|
| 227 |
md_log = gr.Textbox(label="Log", interactive=False, lines=15, max_lines=25)
|
| 228 |
md_script = gr.Code(label="Reproduction Script", language="python", interactive=False, lines=18, max_lines=28)
|
| 229 |
md_explain= gr.Markdown()
|
|
@@ -255,7 +252,7 @@ with gr.Blocks(theme=gr.themes.Ocean(), title="OrbMol Demo") as demo:
|
|
| 255 |
with gr.Column(variant="panel", min_width=520):
|
| 256 |
rlx_status = gr.Textbox(label="Status", interactive=False)
|
| 257 |
rlx_traj = gr.File(label="Trajectory (.traj)", interactive=False)
|
| 258 |
-
rlx_html = gr.HTML(label="Final Structure / Trajectory"
|
| 259 |
rlx_log = gr.Textbox(label="Log", interactive=False, lines=15, max_lines=25)
|
| 260 |
rlx_script = gr.Code(label="Reproduction Script", language="python", interactive=False, lines=18, max_lines=28)
|
| 261 |
rlx_explain= gr.Markdown()
|
|
|
|
| 119 |
# ========== Wrappers MD / Relax (con firma correcta) ==========
|
| 120 |
def md_wrapper(structure_file, charge, spin, steps, tempK, timestep_fs, ensemble):
|
| 121 |
"""
|
| 122 |
+
Llama a tu run_md_simulation con keywords correctos.
|
|
|
|
|
|
|
| 123 |
"""
|
| 124 |
try:
|
| 125 |
if not structure_file:
|
|
|
|
| 148 |
|
| 149 |
def relax_wrapper(structure_file, steps, fmax, charge, spin, relax_cell):
|
| 150 |
"""
|
| 151 |
+
Llama a run_relaxation_simulation con keywords correctos.
|
|
|
|
| 152 |
"""
|
| 153 |
try:
|
| 154 |
if not structure_file:
|
|
|
|
| 220 |
with gr.Column(variant="panel", min_width=520):
|
| 221 |
md_status = gr.Textbox(label="MD Status", interactive=False)
|
| 222 |
md_traj = gr.File(label="Trajectory (.traj)", interactive=False)
|
| 223 |
+
md_html = gr.HTML(label="Trajectory Viewer") # <- sin sanitize
|
| 224 |
md_log = gr.Textbox(label="Log", interactive=False, lines=15, max_lines=25)
|
| 225 |
md_script = gr.Code(label="Reproduction Script", language="python", interactive=False, lines=18, max_lines=28)
|
| 226 |
md_explain= gr.Markdown()
|
|
|
|
| 252 |
with gr.Column(variant="panel", min_width=520):
|
| 253 |
rlx_status = gr.Textbox(label="Status", interactive=False)
|
| 254 |
rlx_traj = gr.File(label="Trajectory (.traj)", interactive=False)
|
| 255 |
+
rlx_html = gr.HTML(label="Final Structure / Trajectory") # <- sin sanitize
|
| 256 |
rlx_log = gr.Textbox(label="Log", interactive=False, lines=15, max_lines=25)
|
| 257 |
rlx_script = gr.Code(label="Reproduction Script", language="python", interactive=False, lines=18, max_lines=28)
|
| 258 |
rlx_explain= gr.Markdown()
|