drigoni commited on
Commit
7e5d7c9
1 Parent(s): 6730767

Upload folder using huggingface_hub

Browse files
Dockerfile ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ FROM python:3.9
3
+
4
+ WORKDIR /code
5
+
6
+ COPY --link --chown=1000 . .
7
+
8
+ RUN mkdir -p /tmp/cache/
9
+ RUN chmod a+rwx -R /tmp/cache/
10
+ ENV TRANSFORMERS_CACHE=/tmp/cache/
11
+
12
+ RUN pip install --no-cache-dir -r requirements.txt
13
+
14
+ ENV PYTHONUNBUFFERED=1 GRADIO_ALLOW_FLAGGING=never GRADIO_NUM_PORTS=1 GRADIO_SERVER_NAME=0.0.0.0 GRADIO_SERVER_PORT=7860 SYSTEM=spaces
15
+
16
+ CMD ["python", "app.py"]
README.md CHANGED
@@ -1,10 +1,10 @@
 
1
  ---
2
- title: Gradio Molgallery2d
3
- emoji: 🏃
4
- colorFrom: blue
5
- colorTo: yellow
6
  sdk: docker
7
  pinned: false
 
8
  ---
9
-
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
1
+
2
  ---
3
+ tags: [gradio-custom-component]
4
+ title: gradio_molgallery2d V0.0.1
5
+ colorFrom: yellow
6
+ colorTo: red
7
  sdk: docker
8
  pinned: false
9
+ license: apache-2.0
10
  ---
 
 
__init__.py ADDED
File without changes
__pycache__/__init__.cpython-311.pyc ADDED
Binary file (174 Bytes). View file
 
__pycache__/app.cpython-311.pyc ADDED
Binary file (1.52 kB). View file
 
app.py ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import gradio as gr
3
+ from gradio_molgallery2d import MolGallery2D
4
+
5
+ example = MolGallery2D().example_inputs()
6
+
7
+ with gr.Blocks() as demo:
8
+ with gr.Row():
9
+ MolGallery2D(label="Blank"), # blank component
10
+ with gr.Row():
11
+ MolGallery2D(value=[(mol, str(i+1)) for i, mol in enumerate(example)], label="Populated"), # populated component
12
+
13
+ demo.launch()
requirements.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ gradio_molgallery2d-0.0.1-py3-none-any.whl