Skip to content

Commit ed60cc9

Browse files
update glm4.1v and minicpmv notebooks (#3106)
1 parent 9dab7d0 commit ed60cc9

File tree

3 files changed

+101
-97
lines changed

3 files changed

+101
-97
lines changed

.ci/skipped_notebooks.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -456,6 +456,12 @@
456456
- macos-13
457457
- ubuntu-22.04
458458
- windows-2022
459+
- notebook: notebooks/minicpm-v-multimodal-chatbot/minicpm-v-multimodal-chatbot.ipynb
460+
skips:
461+
- python:
462+
- '3.9'
463+
- os:
464+
- macos-13
459465
- notebook: notebooks/kokoro/kokoro.ipynb
460466
skips:
461467
- os:
@@ -510,8 +516,11 @@
510516
- windows-2022
511517
- notebook: notebooks/glm4.1-v-thinking/glm4.1-v-thinking.ipynb
512518
skips:
519+
- python:
520+
- "3.9"
513521
- os:
514522
- macos-13
523+
- windows-2022
515524
- notebook: notebooks/ace-step-music-generation/ace-step-music-generation.ipynb
516525
skips:
517526
- os:

notebooks/glm4.1-v-thinking/glm4.1-v-thinking.ipynb

Lines changed: 70 additions & 40 deletions
Large diffs are not rendered by default.

notebooks/minicpm-v-multimodal-chatbot/minicpm-v-multimodal-chatbot.ipynb

Lines changed: 22 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -50,52 +50,24 @@
5050
"execution_count": null,
5151
"id": "0116846d-da6f-4e81-b6be-0a882a3eb872",
5252
"metadata": {},
53-
"outputs": [
54-
{
55-
"name": "stdout",
56-
"output_type": "stream",
57-
"text": [
58-
"\n",
59-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m A new release of pip is available: \u001b[0m\u001b[31;49m25.1.1\u001b[0m\u001b[39;49m -> \u001b[0m\u001b[32;49m25.2\u001b[0m\n",
60-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m To update, run: \u001b[0m\u001b[32;49mpip install --upgrade pip\u001b[0m\n",
61-
"Note: you may need to restart the kernel to use updated packages.\n",
62-
"\n",
63-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m A new release of pip is available: \u001b[0m\u001b[31;49m25.1.1\u001b[0m\u001b[39;49m -> \u001b[0m\u001b[32;49m25.2\u001b[0m\n",
64-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m To update, run: \u001b[0m\u001b[32;49mpip install --upgrade pip\u001b[0m\n",
65-
"Note: you may need to restart the kernel to use updated packages.\n",
66-
"\n",
67-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m A new release of pip is available: \u001b[0m\u001b[31;49m25.1.1\u001b[0m\u001b[39;49m -> \u001b[0m\u001b[32;49m25.2\u001b[0m\n",
68-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m To update, run: \u001b[0m\u001b[32;49mpip install --upgrade pip\u001b[0m\n",
69-
"Note: you may need to restart the kernel to use updated packages.\n",
70-
"\u001b[31mERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.\n",
71-
"optimum-intel 1.26.0.dev0+7c64417 requires optimum==1.27.*, but you have optimum 2.0.0.dev0 which is incompatible.\u001b[0m\u001b[31m\n",
72-
"\u001b[0m\n",
73-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m A new release of pip is available: \u001b[0m\u001b[31;49m25.1.1\u001b[0m\u001b[39;49m -> \u001b[0m\u001b[32;49m25.2\u001b[0m\n",
74-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m To update, run: \u001b[0m\u001b[32;49mpip install --upgrade pip\u001b[0m\n",
75-
"Note: you may need to restart the kernel to use updated packages.\n",
76-
"\n",
77-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m A new release of pip is available: \u001b[0m\u001b[31;49m25.1.1\u001b[0m\u001b[39;49m -> \u001b[0m\u001b[32;49m25.2\u001b[0m\n",
78-
"\u001b[1m[\u001b[0m\u001b[34;49mnotice\u001b[0m\u001b[1;39;49m]\u001b[0m\u001b[39;49m To update, run: \u001b[0m\u001b[32;49mpip install --upgrade pip\u001b[0m\n",
79-
"Note: you may need to restart the kernel to use updated packages.\n"
80-
]
81-
}
82-
],
53+
"outputs": [],
8354
"source": [
8455
"import platform\n",
8556
"\n",
57+
"%pip uninstall -q -y optimum optimum-intel optimum-onnx\n",
8658
"if platform.system() == \"Darwin\":\n",
8759
" %pip install -q \"numpy<2.0.0\"\n",
8860
"\n",
89-
"%pip install -q \"torch>=2.1\" \"torchvision\" \"timm>=0.9.2\" \"transformers>=4.45\" \"Pillow\" \"gradio>=4.40\" \"tqdm\" \"sentencepiece\" \"peft\" \"huggingface-hub>=0.24.0\" --extra-index-url https://download.pytorch.org/whl/cpu\n",
61+
"%pip install -q \"torch>=2.1,<2.9\" \"torchvision\" \"timm>=0.9.2\" \"transformers>=4.45,<4.56\" \"Pillow\" \"gradio>=4.40\" \"tqdm\" \"sentencepiece\" \"peft\" \"huggingface-hub>=0.24.0\" --extra-index-url https://download.pytorch.org/whl/cpu\n",
9062
"%pip install -q \"nncf>=2.14.0\"\n",
91-
"%pip install -q \"git+https://github.com/openvino-dev-samples/optimum-intel.git@minicpm4v\" --extra-index-url https://download.pytorch.org/whl/cpu\n",
63+
"%pip install -q \"git+https://github.com/openvino-dev-samples/optimum-intel.git@81f69be5e0f7fd80aba81b5e5d4c213dfe3e9344\" --extra-index-url https://download.pytorch.org/whl/cpu\n",
9264
"%pip install -q \"git+https://github.com/openvino-dev-samples/optimum.git@minicpm4v\" --extra-index-url https://download.pytorch.org/whl/cpu\n",
9365
"%pip install -q -U --pre \"openvino>=2025.0\" \"openvino-tokenizers>=2025.0\" \"openvino-genai>=2025.0\" --extra-index-url https://storage.openvinotoolkit.org/simple/wheels/nightly"
9466
]
9567
},
9668
{
9769
"cell_type": "code",
98-
"execution_count": 1,
70+
"execution_count": 2,
9971
"id": "1534e378-1b87-4f1b-94e8-09061e960700",
10072
"metadata": {},
10173
"outputs": [],
@@ -155,26 +127,26 @@
155127
},
156128
{
157129
"cell_type": "code",
158-
"execution_count": 4,
130+
"execution_count": 3,
159131
"id": "a0851b3c",
160132
"metadata": {
161133
"test_replace": {
162-
"openbmb/MiniCPM-V-4_5": "katuni4ka/tiny-random-minicpmv-2_6"
134+
"openbmb/MiniCPM-V-4_5": "optimum-intel-internal-testing/tiny-random-minicpm-v-4_5"
163135
}
164136
},
165137
"outputs": [
166138
{
167139
"data": {
168140
"application/vnd.jupyter.widget-view+json": {
169-
"model_id": "0b19f64efc1941acaa7f8c482ee5e78b",
141+
"model_id": "6a4d3186778f4dd3bd0a2f2e3b5f5090",
170142
"version_major": 2,
171143
"version_minor": 0
172144
},
173145
"text/plain": [
174146
"Dropdown(description='Model:', options=('openbmb/MiniCPM-V-4_5', 'openbmb/MiniCPM-V-4', 'openbmb/MiniCPM-V-2_6…"
175147
]
176148
},
177-
"execution_count": 4,
149+
"execution_count": 3,
178150
"metadata": {},
179151
"output_type": "execute_result"
180152
}
@@ -223,7 +195,7 @@
223195
},
224196
{
225197
"cell_type": "code",
226-
"execution_count": 5,
198+
"execution_count": 4,
227199
"id": "82e846bb",
228200
"metadata": {},
229201
"outputs": [
@@ -251,18 +223,11 @@
251223
"metadata": {},
252224
"output_type": "display_data"
253225
},
254-
{
255-
"name": "stderr",
256-
"output_type": "stream",
257-
"text": [
258-
"/home/ethan/intel/openvino_notebooks/openvino_env/lib/python3.10/site-packages/openvino/runtime/__init__.py:10: DeprecationWarning: The `openvino.runtime` module is deprecated and will be removed in the 2026.0 release. Please replace `openvino.runtime` with `openvino`.\n",
259-
" warnings.warn(\n"
260-
]
261-
},
262226
{
263227
"name": "stdout",
264228
"output_type": "stream",
265229
"text": [
230+
"WARNING:nncf:NNCF provides best results with torch==2.7.*, while current torch version is 2.5.1+cpu. If you encounter issues, consider switching to torch==2.7.*\n",
266231
"INFO:nncf:Statistics of the bitwidth distribution:\n",
267232
"┍━━━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┑\n",
268233
"│ Weight compression mode │ % all parameters (layers) │ % ratio-defining parameters (layers) │\n",
@@ -274,7 +239,7 @@
274239
{
275240
"data": {
276241
"application/vnd.jupyter.widget-view+json": {
277-
"model_id": "e8e93d5dc404481ea7a248a7ce08d08d",
242+
"model_id": "72c61bfc2d5c4c03b53909a3b7a8bd8e",
278243
"version_major": 2,
279244
"version_minor": 0
280245
},
@@ -358,22 +323,22 @@
358323
},
359324
{
360325
"cell_type": "code",
361-
"execution_count": 6,
326+
"execution_count": 5,
362327
"id": "626fef57",
363328
"metadata": {},
364329
"outputs": [
365330
{
366331
"data": {
367332
"application/vnd.jupyter.widget-view+json": {
368-
"model_id": "c4b32db22ceb4213aa2e7023e93756e7",
333+
"model_id": "5cd9ab6492364253850049b73d81660c",
369334
"version_major": 2,
370335
"version_minor": 0
371336
},
372337
"text/plain": [
373338
"Dropdown(description='Device:', index=2, options=('CPU', 'GPU', 'AUTO'), value='AUTO')"
374339
]
375340
},
376-
"execution_count": 6,
341+
"execution_count": 5,
377342
"metadata": {},
378343
"output_type": "execute_result"
379344
}
@@ -388,7 +353,7 @@
388353
},
389354
{
390355
"cell_type": "code",
391-
"execution_count": 7,
356+
"execution_count": 6,
392357
"id": "e7af404b",
393358
"metadata": {},
394359
"outputs": [],
@@ -414,7 +379,7 @@
414379
},
415380
{
416381
"cell_type": "code",
417-
"execution_count": 8,
382+
"execution_count": 7,
418383
"id": "e56db20f-7cf0-4ead-b6af-8e048e61b059",
419384
"metadata": {},
420385
"outputs": [],
@@ -461,7 +426,7 @@
461426
},
462427
{
463428
"cell_type": "code",
464-
"execution_count": 9,
429+
"execution_count": 8,
465430
"id": "7522d730-f039-46e6-b06d-f90bd4c76f7a",
466431
"metadata": {
467432
"tags": []
@@ -483,7 +448,7 @@
483448
"<PIL.Image.Image image mode=RGB size=1000x667>"
484449
]
485450
},
486-
"execution_count": 9,
451+
"execution_count": 8,
487452
"metadata": {},
488453
"output_type": "execute_result"
489454
}
@@ -499,7 +464,7 @@
499464
},
500465
{
501466
"cell_type": "code",
502-
"execution_count": 10,
467+
"execution_count": 9,
503468
"id": "b31e4cc5-42b3-4795-b04b-9a653228b6a4",
504469
"metadata": {
505470
"tags": []
@@ -509,7 +474,7 @@
509474
"name": "stdout",
510475
"output_type": "stream",
511476
"text": [
512-
"The unusual aspect of this image is that a cat is lying on its back inside a cardboard box, appearing relaxed and content. Cats are known for their curiosity and love for confined spaces, but seeing one in such a relaxed position with its belly exposed in a box is a charming and uncommon sight."
477+
"The unusual aspect of this image is that a cat is lying completely inside an open cardboard box, with its head resting on the edge of the box and its body fully extended within it. Cats are known for their love of boxes, but seeing one sprawled out in such a relaxed manner in an open box is quite a unique and amusing sight."
513478
]
514479
}
515480
],
@@ -567,7 +532,7 @@
567532
"name": "python",
568533
"nbconvert_exporter": "python",
569534
"pygments_lexer": "ipython3",
570-
"version": "3.10.12"
535+
"version": "3.10.7"
571536
},
572537
"openvino_notebooks": {
573538
"imageUrl": "https://github.com/openvinotoolkit/openvino_notebooks/assets/29454499/7b0919ea-6fe4-4c8f-8395-cb0ee6e87937",

0 commit comments

Comments
 (0)