Spaces:
Sleeping
Sleeping
allowing shm
Browse files
README.md
CHANGED
@@ -55,3 +55,5 @@ poetry publish
|
|
55 |
|
56 |
|
57 |
# Deploy to huggingface.
|
|
|
|
|
|
55 |
|
56 |
|
57 |
# Deploy to huggingface.
|
58 |
+
git remote add hf https://huggingface.co/spaces/groueix/copaint
|
59 |
+
git push hf main
|
app.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
import argparse
|
2 |
from copaint.gradio_ui import build_gradio_ui
|
3 |
-
|
4 |
|
5 |
def main():
|
6 |
parser = argparse.ArgumentParser()
|
@@ -13,7 +13,11 @@ def main():
|
|
13 |
args = parser.parse_args()
|
14 |
|
15 |
demo = build_gradio_ui()
|
16 |
-
|
|
|
|
|
|
|
|
|
17 |
|
18 |
|
19 |
if __name__ == "__main__":
|
|
|
1 |
import argparse
|
2 |
from copaint.gradio_ui import build_gradio_ui
|
3 |
+
import os
|
4 |
|
5 |
def main():
|
6 |
parser = argparse.ArgumentParser()
|
|
|
13 |
args = parser.parse_args()
|
14 |
|
15 |
demo = build_gradio_ui()
|
16 |
+
# check if /dev/shm exists
|
17 |
+
if os.path.exists("/dev/shm"):
|
18 |
+
demo.launch(share=args.share, allowed_paths=["/dev/shm"])
|
19 |
+
else:
|
20 |
+
demo.launch(share=args.share)
|
21 |
|
22 |
|
23 |
if __name__ == "__main__":
|