cg2all / app.py
huhlim's picture
Update app.py
3e2256f
raw
history blame
455 Bytes
import gradio as gr
import cg2all
import os
def runner(in_pdb, model_type):
out_fn = in_pdb.name[:-4] + "-all.pdb"
print(in_pdb, in_pdb.name, os.path.exists(in_pdb.name))
cg2all.convert_cg2all(in_pdb.name, out_fn, model_type=model_type)
demo = gr.Interface(fn=cg2all.convert_cg2all,
inputs=["file", gr.Radio(["CalphaBasedModel", "ResidueBasedModel", "Martini"])],
outputs=["file"])
demo.launch()