Spaces:
Runtime error
Runtime error
freemt
commited on
Commit
·
5811a7e
1
Parent(s):
3362acb
Update gradio sdk_version from 3.0.17 to 3.1.17, examples added
Browse files- README.md +1 -1
- app.py +3 -1
- install-sw1.sh +12 -3
- okteto.yml +1 -0
- radio_mlbee/~syncthing~gradio_queue.db-journal.tmp +0 -0
- requirements.txt +3 -3
- start-sshd.sh +3 -0
README.md
CHANGED
|
@@ -4,7 +4,7 @@ emoji: 💻
|
|
| 4 |
colorFrom: gray
|
| 5 |
colorTo: red
|
| 6 |
sdk: gradio
|
| 7 |
-
sdk_version: 3.
|
| 8 |
app_file: app.py
|
| 9 |
pinned: false
|
| 10 |
license: mit
|
|
|
|
| 4 |
colorFrom: gray
|
| 5 |
colorTo: red
|
| 6 |
sdk: gradio
|
| 7 |
+
sdk_version: 3.1.7
|
| 8 |
app_file: app.py
|
| 9 |
pinned: false
|
| 10 |
license: mit
|
app.py
CHANGED
|
@@ -155,7 +155,9 @@ iface = gr.Interface(
|
|
| 155 |
examples=[
|
| 156 |
# [text1, text2, False],
|
| 157 |
# [text1[: len(text1) // 5], text2[: len(text2) // 5], False, False, False],
|
| 158 |
-
[
|
|
|
|
|
|
|
| 159 |
],
|
| 160 |
allow_flagging="never",
|
| 161 |
)
|
|
|
|
| 155 |
examples=[
|
| 156 |
# [text1, text2, False],
|
| 157 |
# [text1[: len(text1) // 5], text2[: len(text2) // 5], False, False, False],
|
| 158 |
+
["a\nb\nc", "a\nc", False, False],
|
| 159 |
+
["test 1 \n test2", "测试 1\n我爱你\n 更多测试", False, False],
|
| 160 |
+
[text1, text2, True, True], # modi
|
| 161 |
],
|
| 162 |
allow_flagging="never",
|
| 163 |
)
|
install-sw1.sh
CHANGED
|
@@ -12,14 +12,23 @@ echo export PATH=~/.local/bin:$PATH > ~/.bashrc
|
|
| 12 |
source ~/.bashrc
|
| 13 |
# ~/.local/bin/poetry install
|
| 14 |
|
| 15 |
-
wget -c https://deb.nodesource.com/
|
| 16 |
-
bash
|
| 17 |
apt-get install -y nodejs
|
| 18 |
npm install -g npm@latest
|
| 19 |
npm install -g nodemon
|
| 20 |
-
rm
|
|
|
|
|
|
|
|
|
|
| 21 |
|
| 22 |
# apt update # alerady done in apt-get install -y nodejs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23 |
apt install byobu -y > /dev/null 2>&1
|
| 24 |
byobu-enable
|
|
|
|
| 25 |
byobu
|
|
|
|
| 12 |
source ~/.bashrc
|
| 13 |
# ~/.local/bin/poetry install
|
| 14 |
|
| 15 |
+
wget -c https://deb.nodesource.com/setup_14.x
|
| 16 |
+
bash setup_14.x
|
| 17 |
apt-get install -y nodejs
|
| 18 |
npm install -g npm@latest
|
| 19 |
npm install -g nodemon
|
| 20 |
+
rm setup_14.x
|
| 21 |
+
|
| 22 |
+
# pytorch cpu
|
| 23 |
+
# pip3 install torch==1.8.2+cpu torchvision==0.9.2+cpu torchaudio==0.8.2 -f https://download.pytorch.org/whl/lts/1.8/torch_lts.html
|
| 24 |
|
| 25 |
# apt update # alerady done in apt-get install -y nodejs
|
| 26 |
+
|
| 27 |
+
# install sshd and publickey
|
| 28 |
+
# apt-get install openssh-server
|
| 29 |
+
# /etc/init.d/ssh restart && mkdir -p ~/.ssh && echo ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOl+SiDFL1ZUh1QJ0454eYKtamkMCVs2hhuv3cWN1LU7 id_ed25519_colab > ~/.ssh/authorized_keys
|
| 30 |
+
|
| 31 |
apt install byobu -y > /dev/null 2>&1
|
| 32 |
byobu-enable
|
| 33 |
+
cd /usr/src/app
|
| 34 |
byobu
|
okteto.yml
CHANGED
|
@@ -39,6 +39,7 @@ dev:
|
|
| 39 |
- 7861:7861
|
| 40 |
- 7860:7860
|
| 41 |
- 8501:8501
|
|
|
|
| 42 |
reverse:
|
| 43 |
- 9000:9000
|
| 44 |
autocreate: true
|
|
|
|
| 39 |
- 7861:7861
|
| 40 |
- 7860:7860
|
| 41 |
- 8501:8501
|
| 42 |
+
- 22:22
|
| 43 |
reverse:
|
| 44 |
- 9000:9000
|
| 45 |
autocreate: true
|
radio_mlbee/~syncthing~gradio_queue.db-journal.tmp
DELETED
|
Binary file (512 Bytes)
|
|
|
requirements.txt
CHANGED
|
@@ -29,9 +29,9 @@ ffmpy==0.3.0; python_version >= "3.7"
|
|
| 29 |
filelock==3.7.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0" and python_version >= "3.7"
|
| 30 |
fonttools==4.33.3; python_version >= "3.7"
|
| 31 |
frozenlist==1.3.0; python_version >= "3.7"
|
| 32 |
-
gradio==3.
|
| 33 |
grapheme==0.6.0; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 34 |
-
h11==0.
|
| 35 |
hf-model-s-cpu==0.1.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 36 |
huggingface-hub==0.5.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 37 |
icecream==2.1.2
|
|
@@ -91,7 +91,7 @@ starlette==0.19.1; python_full_version >= "3.6.1" and python_version >= "3.7"
|
|
| 91 |
threadpoolctl==3.1.0; python_full_version >= "3.8.3" and python_full_version < "4.0.0" and python_version >= "3.8"
|
| 92 |
tokenizers==0.12.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 93 |
tomli==2.0.1; python_version >= "3.7"
|
| 94 |
-
|
| 95 |
torchvision==0.12.0; python_version >= "3.7"
|
| 96 |
tqdm==4.64.0; python_full_version >= "3.8.3" and python_full_version < "4.0.0" and (python_version >= "3.8" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.8" and python_version < "4.0" and python_full_version >= "3.4.0") and python_version >= "3.7"
|
| 97 |
transformers==4.19.4; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
|
|
|
| 29 |
filelock==3.7.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0" and python_version >= "3.7"
|
| 30 |
fonttools==4.33.3; python_version >= "3.7"
|
| 31 |
frozenlist==1.3.0; python_version >= "3.7"
|
| 32 |
+
gradio==3.1.7; python_version >= "3.7"
|
| 33 |
grapheme==0.6.0; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 34 |
+
h11==0.12.0; python_version >= "3.7"
|
| 35 |
hf-model-s-cpu==0.1.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 36 |
huggingface-hub==0.5.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 37 |
icecream==2.1.2
|
|
|
|
| 91 |
threadpoolctl==3.1.0; python_full_version >= "3.8.3" and python_full_version < "4.0.0" and python_version >= "3.8"
|
| 92 |
tokenizers==0.12.1; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
| 93 |
tomli==2.0.1; python_version >= "3.7"
|
| 94 |
+
torch @ https://download.pytorch.org/whl/cpu/torch-1.11.0%2Bcpu-cp38-cp38-linux_x86_64.whl ; python_full_version >= "3.7.0" and python_version >= "3.7" or sys_platform == "linux" or sys_platform == "win32"
|
| 95 |
torchvision==0.12.0; python_version >= "3.7"
|
| 96 |
tqdm==4.64.0; python_full_version >= "3.8.3" and python_full_version < "4.0.0" and (python_version >= "3.8" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.8" and python_version < "4.0" and python_full_version >= "3.4.0") and python_version >= "3.7"
|
| 97 |
transformers==4.19.4; python_full_version >= "3.8.3" and python_full_version < "4.0.0"
|
start-sshd.sh
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
apt update && apt-get install openssh-server -y
|
| 2 |
+
/etc/init.d/ssh restart && mkdir -p ~/.ssh && echo ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOl+SiDFL1ZUh1QJ0454eYKtamkMCVs2hhuv3cWN1LU7 id_ed25519_colab > ~/.ssh/authorized_keys
|
| 3 |
+
echo cd /usr/src/app >> ~/.bashrc
|