Spaces:
Runtime error
Runtime error
import gradio as gr | |
import os | |
url = os.environ['IP_ADDRESS'] | |
with gr.Blocks() as demo: | |
gr.HTML( | |
""" | |
<!DOCTYPE html> | |
<html lang="zh"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>En3D</title> | |
<style> | |
body {font-family: Arial, sans-serif; | |
text-align: center; | |
} | |
header, section, footer { | |
margin-bottom: 10px; | |
} | |
iframe { | |
width: 80%; | |
height: 1000px; | |
align-items: center; | |
border: none; | |
} | |
</style> | |
</head> | |
<body> | |
<iframe src=""" + url + """ title="demo"></iframe> | |
</section> | |
</body> | |
</html>""") | |
if __name__ == "__main__": | |
demo.queue(max_size=100) | |
demo.launch(share=False) | |