Skip to content

Commit 955dd73

Browse files
pip helper usage
1 parent 753ea59 commit 955dd73

File tree

1 file changed

+44
-17
lines changed

1 file changed

+44
-17
lines changed

notebooks/outetts-text-to-speech/outetts-text-to-speech.ipynb

+44-17
Original file line numberDiff line numberDiff line change
@@ -49,22 +49,6 @@
4949
"[back to top ⬆️](#Table-of-contents:)"
5050
]
5151
},
52-
{
53-
"cell_type": "code",
54-
"execution_count": null,
55-
"metadata": {},
56-
"outputs": [],
57-
"source": [
58-
"import platform\n",
59-
"\n",
60-
"%pip install -q \"torch>=2.1\" \"torchaudio\" \"einops\" \"transformers>=4.46.1\" \"loguru\" \"inflect\" \"pesq\" \"torchcrepe\" \"natsort\" \"polars\" uroman mecab-python3 unidic-lite --extra-index-url https://download.pytorch.org/whl/cpu\n",
61-
"%pip install -q \"gradio>=4.19\" \"openvino>=2024.4.0\" \"tqdm\" \"pyyaml\" \"librosa\" \"soundfile\" \"nncf\"\n",
62-
"%pip install -q \"git+https://github.com/huggingface/optimum-intel.git\" --extra-index-url https://download.pytorch.org/whl/cpu\n",
63-
"\n",
64-
"if platform.system() == \"Darwin\":\n",
65-
" %pip install -q \"numpy<2.0.0\""
66-
]
67-
},
6852
{
6953
"cell_type": "code",
7054
"execution_count": null,
@@ -74,7 +58,7 @@
7458
"import requests\n",
7559
"from pathlib import Path\n",
7660
"\n",
77-
"utility_files = [\"cmd_helper.py\", \"notebook_utils.py\"]\n",
61+
"utility_files = [\"cmd_helper.py\", \"notebook_utils.py\", \"pip_helper.py\"]\n",
7862
"base_utility_url = \"https://raw.githubusercontent.com/openvinotoolkit/openvino_notebooks/latest/utils/\"\n",
7963
"\n",
8064
"for utility_file in utility_files:\n",
@@ -99,6 +83,49 @@
9983
"collect_telemetry(\"outetts-text-to-speech.ipynb\")"
10084
]
10185
},
86+
{
87+
"cell_type": "code",
88+
"execution_count": null,
89+
"metadata": {},
90+
"outputs": [],
91+
"source": [
92+
"import platform\n",
93+
"from pip_helper import pip_install\n",
94+
"\n",
95+
"pip_install(\n",
96+
" \"-q\",\n",
97+
" \"torch>=2.1\",\n",
98+
" \"torchaudio\",\n",
99+
" \"einops\",\n",
100+
" \"transformers>=4.46.1\",\n",
101+
" \"loguru\",\n",
102+
" \"inflect\",\n",
103+
" \"pesq\",\n",
104+
" \"torchcrepe\",\n",
105+
" \"natsort\",\n",
106+
" \"polars\",\n",
107+
" \"uroman\",\n",
108+
" \"mecab-python3\",\n",
109+
" \"unidic-lite\",\n",
110+
" \"--extra-index-url\",\n",
111+
" \"https://download.pytorch.org/whl/cpu\",\n",
112+
")\n",
113+
"pip_install(\n",
114+
" \"-q\",\n",
115+
" \"gradio>=4.19\",\n",
116+
" \"openvino>=2024.4.0\",\n",
117+
" \"tqdm\",\n",
118+
" \"pyyaml\",\n",
119+
" \"librosa\",\n",
120+
" \"soundfile\",\n",
121+
" \"nncf\",\n",
122+
")\n",
123+
"pip_install(\"-q\", \"git+https://github.com/huggingface/optimum-intel.git\", \"--extra-index-url\", \"https://download.pytorch.org/whl/cpu\")\n",
124+
"\n",
125+
"if platform.system() == \"Darwin\":\n",
126+
" pip_install(\"-q\", \"numpy<2.0.0\")"
127+
]
128+
},
102129
{
103130
"cell_type": "code",
104131
"execution_count": null,

0 commit comments

Comments
 (0)