Skip to content

Commit

Permalink
change the ASR model id
Browse files Browse the repository at this point in the history
change the ASR model id

change the ASR model id

change the ASR model id

change the ASR model id

change the ASR model id

change the ASR model id
  • Loading branch information
openvino-dev-samples committed Dec 17, 2024
1 parent dfd4aed commit 1508f3c
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions notebooks/multimodal-rag/multimodal-rag-llamaindex.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,12 @@
}
],
"source": [
"%pip uninstall -q -y \"moviepy\" \"decorator\"\n",
"\n",
"%pip install -q \"llama-index-core\" \"llama-index-embeddings-openvino>=0.4.1\" \"llama-index-multi-modal-llms-openvino\" \"llama-index-readers-file\" \\\n",
" \"llama-index-vector-stores-qdrant\" \\\n",
" \"transformers>=4.45\" \\\n",
" \"moviepy==1.0.3\" \\\n",
" \"moviepy>=2.1.1\" \\\n",
" \"librosa\" \\\n",
" \"python-ffmpeg<=1.0.16\" \\\n",
" \"open_clip_torch\" \\\n",
Expand All @@ -82,7 +84,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": null,
"id": "f24c553d-8c4c-40dd-86e4-313b99f928d0",
"metadata": {},
"outputs": [
Expand Down Expand Up @@ -146,7 +148,7 @@
"source": [
"import huggingface_hub as hf_hub\n",
"\n",
"asr_model_id = \"OpenVINO/distil-large-v3-int8-ov\"\n",
"asr_model_id = \"OpenVINO/distil-whisper-large-v3-int8-ov\"\n",
"asr_model_path = asr_model_id.split(\"/\")[-1]\n",
"\n",
"if not Path(asr_model_path).exists():\n",
Expand Down Expand Up @@ -296,17 +298,16 @@
"outputs": [],
"source": [
"video_url = \"https://github.com/user-attachments/assets/2e38afa5-ce3e-448c-ad1a-0e9471039ff1\"\n",
"output_video_path = \"./video_data/\"\n",
"output_folder = \"./mixed_data/\"\n",
"output_audio_path = \"./mixed_data/output_audio.wav\"\n",
"filepath = \"video_data/input_vid.mp4\"\n",
"\n",
"filepath = output_video_path + \"input_vid.mp4\"\n",
"Path(output_folder).mkdir(parents=True, exist_ok=True)\n",
"example_path = Path(filepath)\n",
"example_path.parent.mkdir(parents=True, exist_ok=True)\n",
"\n",
"if not Path(filepath).exists():\n",
" r = requests.get(video_url)\n",
" with Path(filepath).open(\"wb\") as f:\n",
" f.write(r.content)"
"r = requests.get(video_url)\n",
"with example_path.open(\"wb\") as f:\n",
" f.write(r.content)"
]
},
{
Expand Down Expand Up @@ -442,7 +443,7 @@
},
{
"cell_type": "code",
"execution_count": 35,
"execution_count": null,
"id": "8f45641a",
"metadata": {},
"outputs": [
Expand Down

0 comments on commit 1508f3c

Please sign in to comment.