Spaces:
Runtime error
Runtime error
File size: 4,773 Bytes
08ff08a |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 |
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## **Applio**\n",
"A simple, high-quality voice conversion tool focused on ease of use and performance.\n",
"\n",
"[Support](https://discord.gg/urxFjYmYYh) — [GitHub](https://github.com/IAHispano/Applio)\n",
"\n",
"<br>\n",
"\n",
"### **Credits**\n",
"- Encryption method: [Hina](https://github.com/hinabl)\n",
"- Uv code: [Shirou](https://github.com/ShiromiyaG)\n",
"- Main development: [Applio Team](https://github.com/IAHispano)\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Install"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"trusted": true
},
"outputs": [],
"source": [
"import codecs\n",
"from IPython.display import clear_output\n",
"rot_47 = lambda encoded_text: \"\".join(\n",
" [\n",
" (\n",
" chr(\n",
" (ord(c) - (ord(\"a\") if c.islower() else ord(\"A\")) - 47) % 26\n",
" + (ord(\"a\") if c.islower() else ord(\"A\"))\n",
" )\n",
" if c.isalpha()\n",
" else c\n",
" )\n",
" for c in encoded_text\n",
" ]\n",
")\n",
"\n",
"new_name = rot_47(\"kmjbmvh_hg\")\n",
"findme = rot_47(codecs.decode(\"pbbxa://oqbpcj.kwu/Dqlitvb/qurwg-mtnqvlmz.oqb\", \"rot_13\"))\n",
"uioawhd = rot_47(codecs.decode(\"pbbxa://oqbpcj.kwu/QIPqaxivw/Ixxtqw.oqb\", \"rot_13\"))\n",
"!pip install uv\n",
"!git clone --depth 1 $uioawhd $new_name --branch 3.2.8-bugfix\n",
"clear_output()\n",
"!mkdir -p /kaggle/tmp\n",
"%cd /kaggle/tmp\n",
"!uv venv .venv --python 3.10.12 > /dev/null 2>&1\n",
"!uv pip install -r /kaggle/working/program_ml/requirements.txt -q\n",
"!uv pip install torch==2.3.1 torchvision==0.18.1 torchaudio==2.3.1 --upgrade --index-url https://download.pytorch.org/whl/cu121 -q\n",
"!uv pip install numpy==1.26.4 -q\n",
"!uv pip install gradio==5.23.1\n",
"%cd /kaggle/working/program_ml\n",
"!source /kaggle/tmp/.venv/bin/activate; python core.py \"prerequisites\" --models \"True\" --exe \"True\" --pretraineds_v1_f0 \"False\" --pretraineds_v2_f0 \"True\" --pretraineds_v1_nof0 \"False\" --pretraineds_v2_nof0 \"False\" > /dev/null 2>&1\n",
"!sudo curl -fsSL https://raw.githubusercontent.com/filebrowser/get/master/get.sh | sudo bash\n",
"!filebrowser config init\n",
"!filebrowser config set --auth.method=noauth\n",
"!filebrowser users add \"applio\" \"\" --perm.admin\n",
"clear_output()\n",
"print(\"Finished\")"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Setup Ngrok"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"trusted": true
},
"outputs": [],
"source": [
"#https://dashboard.ngrok.com/get-started/your-authtoken (Token Ngrok)\n",
"!pip install pyngrok\n",
"!ngrok config add-authtoken token"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Start"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"trusted": true
},
"outputs": [],
"source": [
"import os\n",
"from pyngrok import ngrok\n",
"from IPython.display import clear_output\n",
"ngrok.kill()\n",
"%cd /kaggle/working/program_ml\n",
"os.system(f\"filebrowser -r /kaggle -p 9876 > /dev/null 2>&1 &\")\n",
"clear_output()\n",
"%load_ext tensorboard\n",
"%tensorboard --logdir logs --port 8077\n",
"p_tunnel = ngrok.connect(6969)\n",
"t_tunnel = ngrok.connect(8077)\n",
"f_tunnel = ngrok.connect(9876)\n",
"clear_output()\n",
"print(\"Applio Url:\", p_tunnel.public_url)\n",
"print(\"Tensorboard Url:\", t_tunnel.public_url)\n",
"print(\"File Url:\", f_tunnel.public_url)\n",
"print(\"Save the link for later, this will take a while...\")\n",
"\n",
"!source /kaggle/tmp/.venv/bin/activate; python app.py"
]
}
],
"metadata": {
"kaggle": {
"accelerator": "nvidiaTeslaT4",
"dataSources": [],
"dockerImageVersionId": 30558,
"isGpuEnabled": true,
"isInternetEnabled": true,
"language": "python",
"sourceType": "notebook"
},
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.12"
}
},
"nbformat": 4,
"nbformat_minor": 4
}
|