nakas commited on
Commit
88c3e8d
·
verified ·
1 Parent(s): b46696a

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +23 -0
app.py ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+
3
+ # Create a simple HTML interface that embeds the Jupyter notebook
4
+ html_content = """
5
+ <div style="text-align:center; padding:10px;">
6
+ <h2>Mobile-Friendly Jupyter Notebook</h2>
7
+ <p>The notebook interface will appear below:</p>
8
+ </div>
9
+ <iframe src="/proxy/8888/tree" width="100%" height="800px" frameborder="0" style="overflow:hidden;"></iframe>
10
+ """
11
+
12
+ # Create Gradio interface
13
+ demo = gr.Interface(
14
+ fn=lambda: None,
15
+ inputs=[],
16
+ outputs=[gr.HTML(html_content)],
17
+ title="Jupyter Notebook",
18
+ css=".gradio-container {max-width: 100% !important; padding: 0 !important;} .min-h-\[48rem\] {min-height: auto !important;}"
19
+ )
20
+
21
+ # Launch the app
22
+ if __name__ == "__main__":
23
+ demo.launch(server_port=7860, share=False)