mabzak commited on
Commit
8761162
1 Parent(s): 9ac10db

Upload example.ipynb

Browse files
Files changed (1) hide show
  1. example.ipynb +1682 -0
example.ipynb ADDED
@@ -0,0 +1,1682 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "nbformat": 4,
3
+ "nbformat_minor": 0,
4
+ "metadata": {
5
+ "colab": {
6
+ "provenance": []
7
+ },
8
+ "kernelspec": {
9
+ "name": "python3",
10
+ "display_name": "Python 3"
11
+ },
12
+ "language_info": {
13
+ "name": "python"
14
+ },
15
+ "widgets": {
16
+ "application/vnd.jupyter.widget-state+json": {
17
+ "afb4cf60647746cea3e1ef02bd4637fb": {
18
+ "model_module": "@jupyter-widgets/controls",
19
+ "model_name": "VBoxModel",
20
+ "model_module_version": "1.5.0",
21
+ "state": {
22
+ "_dom_classes": [],
23
+ "_model_module": "@jupyter-widgets/controls",
24
+ "_model_module_version": "1.5.0",
25
+ "_model_name": "VBoxModel",
26
+ "_view_count": null,
27
+ "_view_module": "@jupyter-widgets/controls",
28
+ "_view_module_version": "1.5.0",
29
+ "_view_name": "VBoxView",
30
+ "box_style": "",
31
+ "children": [
32
+ "IPY_MODEL_343c47eaccd249c8a797b2c1378603c5",
33
+ "IPY_MODEL_aba32fb028f447ee91c74092b14e494f",
34
+ "IPY_MODEL_59901c4463764d719fc799e52c91a07a",
35
+ "IPY_MODEL_7d591e5027c54034a51ae0ffc6fbb9c3"
36
+ ],
37
+ "layout": "IPY_MODEL_2b7db7372ba64aa899516acad2df2cca"
38
+ }
39
+ },
40
+ "0645cea30b14400aa891ef4223c0e52d": {
41
+ "model_module": "@jupyter-widgets/controls",
42
+ "model_name": "HTMLModel",
43
+ "model_module_version": "1.5.0",
44
+ "state": {
45
+ "_dom_classes": [],
46
+ "_model_module": "@jupyter-widgets/controls",
47
+ "_model_module_version": "1.5.0",
48
+ "_model_name": "HTMLModel",
49
+ "_view_count": null,
50
+ "_view_module": "@jupyter-widgets/controls",
51
+ "_view_module_version": "1.5.0",
52
+ "_view_name": "HTMLView",
53
+ "description": "",
54
+ "description_tooltip": null,
55
+ "layout": "IPY_MODEL_e4ef40a5fe904eeea29938f2b399521f",
56
+ "placeholder": "​",
57
+ "style": "IPY_MODEL_58f4807b08fc4e4ca6eed3d266c2990e",
58
+ "value": "<center> <img\nsrc=https://huggingface.co/front/assets/huggingface_logo-noborder.svg\nalt='Hugging Face'> <br> Copy a token from <a\nhref=\"https://huggingface.co/settings/tokens\" target=\"_blank\">your Hugging Face\ntokens page</a> and paste it below. <br> Immediately click login after copying\nyour token or it might be stored in plain text in this notebook file. </center>"
59
+ }
60
+ },
61
+ "80633cc88f124faf8f4aa3dc2c5d8550": {
62
+ "model_module": "@jupyter-widgets/controls",
63
+ "model_name": "PasswordModel",
64
+ "model_module_version": "1.5.0",
65
+ "state": {
66
+ "_dom_classes": [],
67
+ "_model_module": "@jupyter-widgets/controls",
68
+ "_model_module_version": "1.5.0",
69
+ "_model_name": "PasswordModel",
70
+ "_view_count": null,
71
+ "_view_module": "@jupyter-widgets/controls",
72
+ "_view_module_version": "1.5.0",
73
+ "_view_name": "PasswordView",
74
+ "continuous_update": true,
75
+ "description": "Token:",
76
+ "description_tooltip": null,
77
+ "disabled": false,
78
+ "layout": "IPY_MODEL_614d8f9b2a684344a6308886d6a6a965",
79
+ "placeholder": "​",
80
+ "style": "IPY_MODEL_7ea45a099d7d4f89aa221426b0b31738",
81
+ "value": ""
82
+ }
83
+ },
84
+ "3a632a25760f4fbbbba8078825084a55": {
85
+ "model_module": "@jupyter-widgets/controls",
86
+ "model_name": "CheckboxModel",
87
+ "model_module_version": "1.5.0",
88
+ "state": {
89
+ "_dom_classes": [],
90
+ "_model_module": "@jupyter-widgets/controls",
91
+ "_model_module_version": "1.5.0",
92
+ "_model_name": "CheckboxModel",
93
+ "_view_count": null,
94
+ "_view_module": "@jupyter-widgets/controls",
95
+ "_view_module_version": "1.5.0",
96
+ "_view_name": "CheckboxView",
97
+ "description": "Add token as git credential?",
98
+ "description_tooltip": null,
99
+ "disabled": false,
100
+ "indent": true,
101
+ "layout": "IPY_MODEL_80a77d6070284a5a88a42c1f7ae9438d",
102
+ "style": "IPY_MODEL_6f2700e5f2f549978717c117122b77b4",
103
+ "value": true
104
+ }
105
+ },
106
+ "f9c6c58d612447eab1af89ec963afa9e": {
107
+ "model_module": "@jupyter-widgets/controls",
108
+ "model_name": "ButtonModel",
109
+ "model_module_version": "1.5.0",
110
+ "state": {
111
+ "_dom_classes": [],
112
+ "_model_module": "@jupyter-widgets/controls",
113
+ "_model_module_version": "1.5.0",
114
+ "_model_name": "ButtonModel",
115
+ "_view_count": null,
116
+ "_view_module": "@jupyter-widgets/controls",
117
+ "_view_module_version": "1.5.0",
118
+ "_view_name": "ButtonView",
119
+ "button_style": "",
120
+ "description": "Login",
121
+ "disabled": false,
122
+ "icon": "",
123
+ "layout": "IPY_MODEL_3fb30bbe0b4f445992638460afab6542",
124
+ "style": "IPY_MODEL_72a2c3784981458f9279b3e817ac2f66",
125
+ "tooltip": ""
126
+ }
127
+ },
128
+ "12a3006fa511479d802c869977087f08": {
129
+ "model_module": "@jupyter-widgets/controls",
130
+ "model_name": "HTMLModel",
131
+ "model_module_version": "1.5.0",
132
+ "state": {
133
+ "_dom_classes": [],
134
+ "_model_module": "@jupyter-widgets/controls",
135
+ "_model_module_version": "1.5.0",
136
+ "_model_name": "HTMLModel",
137
+ "_view_count": null,
138
+ "_view_module": "@jupyter-widgets/controls",
139
+ "_view_module_version": "1.5.0",
140
+ "_view_name": "HTMLView",
141
+ "description": "",
142
+ "description_tooltip": null,
143
+ "layout": "IPY_MODEL_f9fbc0bca2434a468eb561531e070807",
144
+ "placeholder": "​",
145
+ "style": "IPY_MODEL_87800c464d694f5a953b4ea27b8eccab",
146
+ "value": "\n<b>Pro Tip:</b> If you don't already have one, you can create a dedicated\n'notebooks' token with 'write' access, that you can then easily reuse for all\nnotebooks. </center>"
147
+ }
148
+ },
149
+ "2b7db7372ba64aa899516acad2df2cca": {
150
+ "model_module": "@jupyter-widgets/base",
151
+ "model_name": "LayoutModel",
152
+ "model_module_version": "1.2.0",
153
+ "state": {
154
+ "_model_module": "@jupyter-widgets/base",
155
+ "_model_module_version": "1.2.0",
156
+ "_model_name": "LayoutModel",
157
+ "_view_count": null,
158
+ "_view_module": "@jupyter-widgets/base",
159
+ "_view_module_version": "1.2.0",
160
+ "_view_name": "LayoutView",
161
+ "align_content": null,
162
+ "align_items": "center",
163
+ "align_self": null,
164
+ "border": null,
165
+ "bottom": null,
166
+ "display": "flex",
167
+ "flex": null,
168
+ "flex_flow": "column",
169
+ "grid_area": null,
170
+ "grid_auto_columns": null,
171
+ "grid_auto_flow": null,
172
+ "grid_auto_rows": null,
173
+ "grid_column": null,
174
+ "grid_gap": null,
175
+ "grid_row": null,
176
+ "grid_template_areas": null,
177
+ "grid_template_columns": null,
178
+ "grid_template_rows": null,
179
+ "height": null,
180
+ "justify_content": null,
181
+ "justify_items": null,
182
+ "left": null,
183
+ "margin": null,
184
+ "max_height": null,
185
+ "max_width": null,
186
+ "min_height": null,
187
+ "min_width": null,
188
+ "object_fit": null,
189
+ "object_position": null,
190
+ "order": null,
191
+ "overflow": null,
192
+ "overflow_x": null,
193
+ "overflow_y": null,
194
+ "padding": null,
195
+ "right": null,
196
+ "top": null,
197
+ "visibility": null,
198
+ "width": "50%"
199
+ }
200
+ },
201
+ "e4ef40a5fe904eeea29938f2b399521f": {
202
+ "model_module": "@jupyter-widgets/base",
203
+ "model_name": "LayoutModel",
204
+ "model_module_version": "1.2.0",
205
+ "state": {
206
+ "_model_module": "@jupyter-widgets/base",
207
+ "_model_module_version": "1.2.0",
208
+ "_model_name": "LayoutModel",
209
+ "_view_count": null,
210
+ "_view_module": "@jupyter-widgets/base",
211
+ "_view_module_version": "1.2.0",
212
+ "_view_name": "LayoutView",
213
+ "align_content": null,
214
+ "align_items": null,
215
+ "align_self": null,
216
+ "border": null,
217
+ "bottom": null,
218
+ "display": null,
219
+ "flex": null,
220
+ "flex_flow": null,
221
+ "grid_area": null,
222
+ "grid_auto_columns": null,
223
+ "grid_auto_flow": null,
224
+ "grid_auto_rows": null,
225
+ "grid_column": null,
226
+ "grid_gap": null,
227
+ "grid_row": null,
228
+ "grid_template_areas": null,
229
+ "grid_template_columns": null,
230
+ "grid_template_rows": null,
231
+ "height": null,
232
+ "justify_content": null,
233
+ "justify_items": null,
234
+ "left": null,
235
+ "margin": null,
236
+ "max_height": null,
237
+ "max_width": null,
238
+ "min_height": null,
239
+ "min_width": null,
240
+ "object_fit": null,
241
+ "object_position": null,
242
+ "order": null,
243
+ "overflow": null,
244
+ "overflow_x": null,
245
+ "overflow_y": null,
246
+ "padding": null,
247
+ "right": null,
248
+ "top": null,
249
+ "visibility": null,
250
+ "width": null
251
+ }
252
+ },
253
+ "58f4807b08fc4e4ca6eed3d266c2990e": {
254
+ "model_module": "@jupyter-widgets/controls",
255
+ "model_name": "DescriptionStyleModel",
256
+ "model_module_version": "1.5.0",
257
+ "state": {
258
+ "_model_module": "@jupyter-widgets/controls",
259
+ "_model_module_version": "1.5.0",
260
+ "_model_name": "DescriptionStyleModel",
261
+ "_view_count": null,
262
+ "_view_module": "@jupyter-widgets/base",
263
+ "_view_module_version": "1.2.0",
264
+ "_view_name": "StyleView",
265
+ "description_width": ""
266
+ }
267
+ },
268
+ "614d8f9b2a684344a6308886d6a6a965": {
269
+ "model_module": "@jupyter-widgets/base",
270
+ "model_name": "LayoutModel",
271
+ "model_module_version": "1.2.0",
272
+ "state": {
273
+ "_model_module": "@jupyter-widgets/base",
274
+ "_model_module_version": "1.2.0",
275
+ "_model_name": "LayoutModel",
276
+ "_view_count": null,
277
+ "_view_module": "@jupyter-widgets/base",
278
+ "_view_module_version": "1.2.0",
279
+ "_view_name": "LayoutView",
280
+ "align_content": null,
281
+ "align_items": null,
282
+ "align_self": null,
283
+ "border": null,
284
+ "bottom": null,
285
+ "display": null,
286
+ "flex": null,
287
+ "flex_flow": null,
288
+ "grid_area": null,
289
+ "grid_auto_columns": null,
290
+ "grid_auto_flow": null,
291
+ "grid_auto_rows": null,
292
+ "grid_column": null,
293
+ "grid_gap": null,
294
+ "grid_row": null,
295
+ "grid_template_areas": null,
296
+ "grid_template_columns": null,
297
+ "grid_template_rows": null,
298
+ "height": null,
299
+ "justify_content": null,
300
+ "justify_items": null,
301
+ "left": null,
302
+ "margin": null,
303
+ "max_height": null,
304
+ "max_width": null,
305
+ "min_height": null,
306
+ "min_width": null,
307
+ "object_fit": null,
308
+ "object_position": null,
309
+ "order": null,
310
+ "overflow": null,
311
+ "overflow_x": null,
312
+ "overflow_y": null,
313
+ "padding": null,
314
+ "right": null,
315
+ "top": null,
316
+ "visibility": null,
317
+ "width": null
318
+ }
319
+ },
320
+ "7ea45a099d7d4f89aa221426b0b31738": {
321
+ "model_module": "@jupyter-widgets/controls",
322
+ "model_name": "DescriptionStyleModel",
323
+ "model_module_version": "1.5.0",
324
+ "state": {
325
+ "_model_module": "@jupyter-widgets/controls",
326
+ "_model_module_version": "1.5.0",
327
+ "_model_name": "DescriptionStyleModel",
328
+ "_view_count": null,
329
+ "_view_module": "@jupyter-widgets/base",
330
+ "_view_module_version": "1.2.0",
331
+ "_view_name": "StyleView",
332
+ "description_width": ""
333
+ }
334
+ },
335
+ "80a77d6070284a5a88a42c1f7ae9438d": {
336
+ "model_module": "@jupyter-widgets/base",
337
+ "model_name": "LayoutModel",
338
+ "model_module_version": "1.2.0",
339
+ "state": {
340
+ "_model_module": "@jupyter-widgets/base",
341
+ "_model_module_version": "1.2.0",
342
+ "_model_name": "LayoutModel",
343
+ "_view_count": null,
344
+ "_view_module": "@jupyter-widgets/base",
345
+ "_view_module_version": "1.2.0",
346
+ "_view_name": "LayoutView",
347
+ "align_content": null,
348
+ "align_items": null,
349
+ "align_self": null,
350
+ "border": null,
351
+ "bottom": null,
352
+ "display": null,
353
+ "flex": null,
354
+ "flex_flow": null,
355
+ "grid_area": null,
356
+ "grid_auto_columns": null,
357
+ "grid_auto_flow": null,
358
+ "grid_auto_rows": null,
359
+ "grid_column": null,
360
+ "grid_gap": null,
361
+ "grid_row": null,
362
+ "grid_template_areas": null,
363
+ "grid_template_columns": null,
364
+ "grid_template_rows": null,
365
+ "height": null,
366
+ "justify_content": null,
367
+ "justify_items": null,
368
+ "left": null,
369
+ "margin": null,
370
+ "max_height": null,
371
+ "max_width": null,
372
+ "min_height": null,
373
+ "min_width": null,
374
+ "object_fit": null,
375
+ "object_position": null,
376
+ "order": null,
377
+ "overflow": null,
378
+ "overflow_x": null,
379
+ "overflow_y": null,
380
+ "padding": null,
381
+ "right": null,
382
+ "top": null,
383
+ "visibility": null,
384
+ "width": null
385
+ }
386
+ },
387
+ "6f2700e5f2f549978717c117122b77b4": {
388
+ "model_module": "@jupyter-widgets/controls",
389
+ "model_name": "DescriptionStyleModel",
390
+ "model_module_version": "1.5.0",
391
+ "state": {
392
+ "_model_module": "@jupyter-widgets/controls",
393
+ "_model_module_version": "1.5.0",
394
+ "_model_name": "DescriptionStyleModel",
395
+ "_view_count": null,
396
+ "_view_module": "@jupyter-widgets/base",
397
+ "_view_module_version": "1.2.0",
398
+ "_view_name": "StyleView",
399
+ "description_width": ""
400
+ }
401
+ },
402
+ "3fb30bbe0b4f445992638460afab6542": {
403
+ "model_module": "@jupyter-widgets/base",
404
+ "model_name": "LayoutModel",
405
+ "model_module_version": "1.2.0",
406
+ "state": {
407
+ "_model_module": "@jupyter-widgets/base",
408
+ "_model_module_version": "1.2.0",
409
+ "_model_name": "LayoutModel",
410
+ "_view_count": null,
411
+ "_view_module": "@jupyter-widgets/base",
412
+ "_view_module_version": "1.2.0",
413
+ "_view_name": "LayoutView",
414
+ "align_content": null,
415
+ "align_items": null,
416
+ "align_self": null,
417
+ "border": null,
418
+ "bottom": null,
419
+ "display": null,
420
+ "flex": null,
421
+ "flex_flow": null,
422
+ "grid_area": null,
423
+ "grid_auto_columns": null,
424
+ "grid_auto_flow": null,
425
+ "grid_auto_rows": null,
426
+ "grid_column": null,
427
+ "grid_gap": null,
428
+ "grid_row": null,
429
+ "grid_template_areas": null,
430
+ "grid_template_columns": null,
431
+ "grid_template_rows": null,
432
+ "height": null,
433
+ "justify_content": null,
434
+ "justify_items": null,
435
+ "left": null,
436
+ "margin": null,
437
+ "max_height": null,
438
+ "max_width": null,
439
+ "min_height": null,
440
+ "min_width": null,
441
+ "object_fit": null,
442
+ "object_position": null,
443
+ "order": null,
444
+ "overflow": null,
445
+ "overflow_x": null,
446
+ "overflow_y": null,
447
+ "padding": null,
448
+ "right": null,
449
+ "top": null,
450
+ "visibility": null,
451
+ "width": null
452
+ }
453
+ },
454
+ "72a2c3784981458f9279b3e817ac2f66": {
455
+ "model_module": "@jupyter-widgets/controls",
456
+ "model_name": "ButtonStyleModel",
457
+ "model_module_version": "1.5.0",
458
+ "state": {
459
+ "_model_module": "@jupyter-widgets/controls",
460
+ "_model_module_version": "1.5.0",
461
+ "_model_name": "ButtonStyleModel",
462
+ "_view_count": null,
463
+ "_view_module": "@jupyter-widgets/base",
464
+ "_view_module_version": "1.2.0",
465
+ "_view_name": "StyleView",
466
+ "button_color": null,
467
+ "font_weight": ""
468
+ }
469
+ },
470
+ "f9fbc0bca2434a468eb561531e070807": {
471
+ "model_module": "@jupyter-widgets/base",
472
+ "model_name": "LayoutModel",
473
+ "model_module_version": "1.2.0",
474
+ "state": {
475
+ "_model_module": "@jupyter-widgets/base",
476
+ "_model_module_version": "1.2.0",
477
+ "_model_name": "LayoutModel",
478
+ "_view_count": null,
479
+ "_view_module": "@jupyter-widgets/base",
480
+ "_view_module_version": "1.2.0",
481
+ "_view_name": "LayoutView",
482
+ "align_content": null,
483
+ "align_items": null,
484
+ "align_self": null,
485
+ "border": null,
486
+ "bottom": null,
487
+ "display": null,
488
+ "flex": null,
489
+ "flex_flow": null,
490
+ "grid_area": null,
491
+ "grid_auto_columns": null,
492
+ "grid_auto_flow": null,
493
+ "grid_auto_rows": null,
494
+ "grid_column": null,
495
+ "grid_gap": null,
496
+ "grid_row": null,
497
+ "grid_template_areas": null,
498
+ "grid_template_columns": null,
499
+ "grid_template_rows": null,
500
+ "height": null,
501
+ "justify_content": null,
502
+ "justify_items": null,
503
+ "left": null,
504
+ "margin": null,
505
+ "max_height": null,
506
+ "max_width": null,
507
+ "min_height": null,
508
+ "min_width": null,
509
+ "object_fit": null,
510
+ "object_position": null,
511
+ "order": null,
512
+ "overflow": null,
513
+ "overflow_x": null,
514
+ "overflow_y": null,
515
+ "padding": null,
516
+ "right": null,
517
+ "top": null,
518
+ "visibility": null,
519
+ "width": null
520
+ }
521
+ },
522
+ "87800c464d694f5a953b4ea27b8eccab": {
523
+ "model_module": "@jupyter-widgets/controls",
524
+ "model_name": "DescriptionStyleModel",
525
+ "model_module_version": "1.5.0",
526
+ "state": {
527
+ "_model_module": "@jupyter-widgets/controls",
528
+ "_model_module_version": "1.5.0",
529
+ "_model_name": "DescriptionStyleModel",
530
+ "_view_count": null,
531
+ "_view_module": "@jupyter-widgets/base",
532
+ "_view_module_version": "1.2.0",
533
+ "_view_name": "StyleView",
534
+ "description_width": ""
535
+ }
536
+ },
537
+ "fd2fd0d53cd24e0cabf6478529ebd794": {
538
+ "model_module": "@jupyter-widgets/controls",
539
+ "model_name": "LabelModel",
540
+ "model_module_version": "1.5.0",
541
+ "state": {
542
+ "_dom_classes": [],
543
+ "_model_module": "@jupyter-widgets/controls",
544
+ "_model_module_version": "1.5.0",
545
+ "_model_name": "LabelModel",
546
+ "_view_count": null,
547
+ "_view_module": "@jupyter-widgets/controls",
548
+ "_view_module_version": "1.5.0",
549
+ "_view_name": "LabelView",
550
+ "description": "",
551
+ "description_tooltip": null,
552
+ "layout": "IPY_MODEL_9a42ecb77a184287ab35ff44c1da21df",
553
+ "placeholder": "​",
554
+ "style": "IPY_MODEL_f998e7f3df9d42c7953f288bc3fd039a",
555
+ "value": "Connecting..."
556
+ }
557
+ },
558
+ "9a42ecb77a184287ab35ff44c1da21df": {
559
+ "model_module": "@jupyter-widgets/base",
560
+ "model_name": "LayoutModel",
561
+ "model_module_version": "1.2.0",
562
+ "state": {
563
+ "_model_module": "@jupyter-widgets/base",
564
+ "_model_module_version": "1.2.0",
565
+ "_model_name": "LayoutModel",
566
+ "_view_count": null,
567
+ "_view_module": "@jupyter-widgets/base",
568
+ "_view_module_version": "1.2.0",
569
+ "_view_name": "LayoutView",
570
+ "align_content": null,
571
+ "align_items": null,
572
+ "align_self": null,
573
+ "border": null,
574
+ "bottom": null,
575
+ "display": null,
576
+ "flex": null,
577
+ "flex_flow": null,
578
+ "grid_area": null,
579
+ "grid_auto_columns": null,
580
+ "grid_auto_flow": null,
581
+ "grid_auto_rows": null,
582
+ "grid_column": null,
583
+ "grid_gap": null,
584
+ "grid_row": null,
585
+ "grid_template_areas": null,
586
+ "grid_template_columns": null,
587
+ "grid_template_rows": null,
588
+ "height": null,
589
+ "justify_content": null,
590
+ "justify_items": null,
591
+ "left": null,
592
+ "margin": null,
593
+ "max_height": null,
594
+ "max_width": null,
595
+ "min_height": null,
596
+ "min_width": null,
597
+ "object_fit": null,
598
+ "object_position": null,
599
+ "order": null,
600
+ "overflow": null,
601
+ "overflow_x": null,
602
+ "overflow_y": null,
603
+ "padding": null,
604
+ "right": null,
605
+ "top": null,
606
+ "visibility": null,
607
+ "width": null
608
+ }
609
+ },
610
+ "f998e7f3df9d42c7953f288bc3fd039a": {
611
+ "model_module": "@jupyter-widgets/controls",
612
+ "model_name": "DescriptionStyleModel",
613
+ "model_module_version": "1.5.0",
614
+ "state": {
615
+ "_model_module": "@jupyter-widgets/controls",
616
+ "_model_module_version": "1.5.0",
617
+ "_model_name": "DescriptionStyleModel",
618
+ "_view_count": null,
619
+ "_view_module": "@jupyter-widgets/base",
620
+ "_view_module_version": "1.2.0",
621
+ "_view_name": "StyleView",
622
+ "description_width": ""
623
+ }
624
+ },
625
+ "343c47eaccd249c8a797b2c1378603c5": {
626
+ "model_module": "@jupyter-widgets/controls",
627
+ "model_name": "LabelModel",
628
+ "model_module_version": "1.5.0",
629
+ "state": {
630
+ "_dom_classes": [],
631
+ "_model_module": "@jupyter-widgets/controls",
632
+ "_model_module_version": "1.5.0",
633
+ "_model_name": "LabelModel",
634
+ "_view_count": null,
635
+ "_view_module": "@jupyter-widgets/controls",
636
+ "_view_module_version": "1.5.0",
637
+ "_view_name": "LabelView",
638
+ "description": "",
639
+ "description_tooltip": null,
640
+ "layout": "IPY_MODEL_7efa196b0c24409d8ee0b23ad303f653",
641
+ "placeholder": "​",
642
+ "style": "IPY_MODEL_9f7f6ce9ee854d65827321123c82b9f6",
643
+ "value": "Token is valid (permission: write)."
644
+ }
645
+ },
646
+ "aba32fb028f447ee91c74092b14e494f": {
647
+ "model_module": "@jupyter-widgets/controls",
648
+ "model_name": "LabelModel",
649
+ "model_module_version": "1.5.0",
650
+ "state": {
651
+ "_dom_classes": [],
652
+ "_model_module": "@jupyter-widgets/controls",
653
+ "_model_module_version": "1.5.0",
654
+ "_model_name": "LabelModel",
655
+ "_view_count": null,
656
+ "_view_module": "@jupyter-widgets/controls",
657
+ "_view_module_version": "1.5.0",
658
+ "_view_name": "LabelView",
659
+ "description": "",
660
+ "description_tooltip": null,
661
+ "layout": "IPY_MODEL_7afcba778e9048a29044aaf01aec7ca2",
662
+ "placeholder": "​",
663
+ "style": "IPY_MODEL_ab0c301db6104a37abb4051f9f90a896",
664
+ "value": "Your token has been saved in your configured git credential helpers (store)."
665
+ }
666
+ },
667
+ "59901c4463764d719fc799e52c91a07a": {
668
+ "model_module": "@jupyter-widgets/controls",
669
+ "model_name": "LabelModel",
670
+ "model_module_version": "1.5.0",
671
+ "state": {
672
+ "_dom_classes": [],
673
+ "_model_module": "@jupyter-widgets/controls",
674
+ "_model_module_version": "1.5.0",
675
+ "_model_name": "LabelModel",
676
+ "_view_count": null,
677
+ "_view_module": "@jupyter-widgets/controls",
678
+ "_view_module_version": "1.5.0",
679
+ "_view_name": "LabelView",
680
+ "description": "",
681
+ "description_tooltip": null,
682
+ "layout": "IPY_MODEL_eb262072aa73425ba9bc5324f5920665",
683
+ "placeholder": "​",
684
+ "style": "IPY_MODEL_c475ac1a2f904d038944cb7e4a65812e",
685
+ "value": "Your token has been saved to /root/.cache/huggingface/token"
686
+ }
687
+ },
688
+ "7d591e5027c54034a51ae0ffc6fbb9c3": {
689
+ "model_module": "@jupyter-widgets/controls",
690
+ "model_name": "LabelModel",
691
+ "model_module_version": "1.5.0",
692
+ "state": {
693
+ "_dom_classes": [],
694
+ "_model_module": "@jupyter-widgets/controls",
695
+ "_model_module_version": "1.5.0",
696
+ "_model_name": "LabelModel",
697
+ "_view_count": null,
698
+ "_view_module": "@jupyter-widgets/controls",
699
+ "_view_module_version": "1.5.0",
700
+ "_view_name": "LabelView",
701
+ "description": "",
702
+ "description_tooltip": null,
703
+ "layout": "IPY_MODEL_e1af2b8270ca43aa9c9b0f7f4acd5300",
704
+ "placeholder": "​",
705
+ "style": "IPY_MODEL_cd7b4ce4f200489cbfbf0174b0561511",
706
+ "value": "Login successful"
707
+ }
708
+ },
709
+ "7efa196b0c24409d8ee0b23ad303f653": {
710
+ "model_module": "@jupyter-widgets/base",
711
+ "model_name": "LayoutModel",
712
+ "model_module_version": "1.2.0",
713
+ "state": {
714
+ "_model_module": "@jupyter-widgets/base",
715
+ "_model_module_version": "1.2.0",
716
+ "_model_name": "LayoutModel",
717
+ "_view_count": null,
718
+ "_view_module": "@jupyter-widgets/base",
719
+ "_view_module_version": "1.2.0",
720
+ "_view_name": "LayoutView",
721
+ "align_content": null,
722
+ "align_items": null,
723
+ "align_self": null,
724
+ "border": null,
725
+ "bottom": null,
726
+ "display": null,
727
+ "flex": null,
728
+ "flex_flow": null,
729
+ "grid_area": null,
730
+ "grid_auto_columns": null,
731
+ "grid_auto_flow": null,
732
+ "grid_auto_rows": null,
733
+ "grid_column": null,
734
+ "grid_gap": null,
735
+ "grid_row": null,
736
+ "grid_template_areas": null,
737
+ "grid_template_columns": null,
738
+ "grid_template_rows": null,
739
+ "height": null,
740
+ "justify_content": null,
741
+ "justify_items": null,
742
+ "left": null,
743
+ "margin": null,
744
+ "max_height": null,
745
+ "max_width": null,
746
+ "min_height": null,
747
+ "min_width": null,
748
+ "object_fit": null,
749
+ "object_position": null,
750
+ "order": null,
751
+ "overflow": null,
752
+ "overflow_x": null,
753
+ "overflow_y": null,
754
+ "padding": null,
755
+ "right": null,
756
+ "top": null,
757
+ "visibility": null,
758
+ "width": null
759
+ }
760
+ },
761
+ "9f7f6ce9ee854d65827321123c82b9f6": {
762
+ "model_module": "@jupyter-widgets/controls",
763
+ "model_name": "DescriptionStyleModel",
764
+ "model_module_version": "1.5.0",
765
+ "state": {
766
+ "_model_module": "@jupyter-widgets/controls",
767
+ "_model_module_version": "1.5.0",
768
+ "_model_name": "DescriptionStyleModel",
769
+ "_view_count": null,
770
+ "_view_module": "@jupyter-widgets/base",
771
+ "_view_module_version": "1.2.0",
772
+ "_view_name": "StyleView",
773
+ "description_width": ""
774
+ }
775
+ },
776
+ "7afcba778e9048a29044aaf01aec7ca2": {
777
+ "model_module": "@jupyter-widgets/base",
778
+ "model_name": "LayoutModel",
779
+ "model_module_version": "1.2.0",
780
+ "state": {
781
+ "_model_module": "@jupyter-widgets/base",
782
+ "_model_module_version": "1.2.0",
783
+ "_model_name": "LayoutModel",
784
+ "_view_count": null,
785
+ "_view_module": "@jupyter-widgets/base",
786
+ "_view_module_version": "1.2.0",
787
+ "_view_name": "LayoutView",
788
+ "align_content": null,
789
+ "align_items": null,
790
+ "align_self": null,
791
+ "border": null,
792
+ "bottom": null,
793
+ "display": null,
794
+ "flex": null,
795
+ "flex_flow": null,
796
+ "grid_area": null,
797
+ "grid_auto_columns": null,
798
+ "grid_auto_flow": null,
799
+ "grid_auto_rows": null,
800
+ "grid_column": null,
801
+ "grid_gap": null,
802
+ "grid_row": null,
803
+ "grid_template_areas": null,
804
+ "grid_template_columns": null,
805
+ "grid_template_rows": null,
806
+ "height": null,
807
+ "justify_content": null,
808
+ "justify_items": null,
809
+ "left": null,
810
+ "margin": null,
811
+ "max_height": null,
812
+ "max_width": null,
813
+ "min_height": null,
814
+ "min_width": null,
815
+ "object_fit": null,
816
+ "object_position": null,
817
+ "order": null,
818
+ "overflow": null,
819
+ "overflow_x": null,
820
+ "overflow_y": null,
821
+ "padding": null,
822
+ "right": null,
823
+ "top": null,
824
+ "visibility": null,
825
+ "width": null
826
+ }
827
+ },
828
+ "ab0c301db6104a37abb4051f9f90a896": {
829
+ "model_module": "@jupyter-widgets/controls",
830
+ "model_name": "DescriptionStyleModel",
831
+ "model_module_version": "1.5.0",
832
+ "state": {
833
+ "_model_module": "@jupyter-widgets/controls",
834
+ "_model_module_version": "1.5.0",
835
+ "_model_name": "DescriptionStyleModel",
836
+ "_view_count": null,
837
+ "_view_module": "@jupyter-widgets/base",
838
+ "_view_module_version": "1.2.0",
839
+ "_view_name": "StyleView",
840
+ "description_width": ""
841
+ }
842
+ },
843
+ "eb262072aa73425ba9bc5324f5920665": {
844
+ "model_module": "@jupyter-widgets/base",
845
+ "model_name": "LayoutModel",
846
+ "model_module_version": "1.2.0",
847
+ "state": {
848
+ "_model_module": "@jupyter-widgets/base",
849
+ "_model_module_version": "1.2.0",
850
+ "_model_name": "LayoutModel",
851
+ "_view_count": null,
852
+ "_view_module": "@jupyter-widgets/base",
853
+ "_view_module_version": "1.2.0",
854
+ "_view_name": "LayoutView",
855
+ "align_content": null,
856
+ "align_items": null,
857
+ "align_self": null,
858
+ "border": null,
859
+ "bottom": null,
860
+ "display": null,
861
+ "flex": null,
862
+ "flex_flow": null,
863
+ "grid_area": null,
864
+ "grid_auto_columns": null,
865
+ "grid_auto_flow": null,
866
+ "grid_auto_rows": null,
867
+ "grid_column": null,
868
+ "grid_gap": null,
869
+ "grid_row": null,
870
+ "grid_template_areas": null,
871
+ "grid_template_columns": null,
872
+ "grid_template_rows": null,
873
+ "height": null,
874
+ "justify_content": null,
875
+ "justify_items": null,
876
+ "left": null,
877
+ "margin": null,
878
+ "max_height": null,
879
+ "max_width": null,
880
+ "min_height": null,
881
+ "min_width": null,
882
+ "object_fit": null,
883
+ "object_position": null,
884
+ "order": null,
885
+ "overflow": null,
886
+ "overflow_x": null,
887
+ "overflow_y": null,
888
+ "padding": null,
889
+ "right": null,
890
+ "top": null,
891
+ "visibility": null,
892
+ "width": null
893
+ }
894
+ },
895
+ "c475ac1a2f904d038944cb7e4a65812e": {
896
+ "model_module": "@jupyter-widgets/controls",
897
+ "model_name": "DescriptionStyleModel",
898
+ "model_module_version": "1.5.0",
899
+ "state": {
900
+ "_model_module": "@jupyter-widgets/controls",
901
+ "_model_module_version": "1.5.0",
902
+ "_model_name": "DescriptionStyleModel",
903
+ "_view_count": null,
904
+ "_view_module": "@jupyter-widgets/base",
905
+ "_view_module_version": "1.2.0",
906
+ "_view_name": "StyleView",
907
+ "description_width": ""
908
+ }
909
+ },
910
+ "e1af2b8270ca43aa9c9b0f7f4acd5300": {
911
+ "model_module": "@jupyter-widgets/base",
912
+ "model_name": "LayoutModel",
913
+ "model_module_version": "1.2.0",
914
+ "state": {
915
+ "_model_module": "@jupyter-widgets/base",
916
+ "_model_module_version": "1.2.0",
917
+ "_model_name": "LayoutModel",
918
+ "_view_count": null,
919
+ "_view_module": "@jupyter-widgets/base",
920
+ "_view_module_version": "1.2.0",
921
+ "_view_name": "LayoutView",
922
+ "align_content": null,
923
+ "align_items": null,
924
+ "align_self": null,
925
+ "border": null,
926
+ "bottom": null,
927
+ "display": null,
928
+ "flex": null,
929
+ "flex_flow": null,
930
+ "grid_area": null,
931
+ "grid_auto_columns": null,
932
+ "grid_auto_flow": null,
933
+ "grid_auto_rows": null,
934
+ "grid_column": null,
935
+ "grid_gap": null,
936
+ "grid_row": null,
937
+ "grid_template_areas": null,
938
+ "grid_template_columns": null,
939
+ "grid_template_rows": null,
940
+ "height": null,
941
+ "justify_content": null,
942
+ "justify_items": null,
943
+ "left": null,
944
+ "margin": null,
945
+ "max_height": null,
946
+ "max_width": null,
947
+ "min_height": null,
948
+ "min_width": null,
949
+ "object_fit": null,
950
+ "object_position": null,
951
+ "order": null,
952
+ "overflow": null,
953
+ "overflow_x": null,
954
+ "overflow_y": null,
955
+ "padding": null,
956
+ "right": null,
957
+ "top": null,
958
+ "visibility": null,
959
+ "width": null
960
+ }
961
+ },
962
+ "cd7b4ce4f200489cbfbf0174b0561511": {
963
+ "model_module": "@jupyter-widgets/controls",
964
+ "model_name": "DescriptionStyleModel",
965
+ "model_module_version": "1.5.0",
966
+ "state": {
967
+ "_model_module": "@jupyter-widgets/controls",
968
+ "_model_module_version": "1.5.0",
969
+ "_model_name": "DescriptionStyleModel",
970
+ "_view_count": null,
971
+ "_view_module": "@jupyter-widgets/base",
972
+ "_view_module_version": "1.2.0",
973
+ "_view_name": "StyleView",
974
+ "description_width": ""
975
+ }
976
+ },
977
+ "7ed17347ad114ee6a3f5bbe44547458e": {
978
+ "model_module": "@jupyter-widgets/controls",
979
+ "model_name": "HBoxModel",
980
+ "model_module_version": "1.5.0",
981
+ "state": {
982
+ "_dom_classes": [],
983
+ "_model_module": "@jupyter-widgets/controls",
984
+ "_model_module_version": "1.5.0",
985
+ "_model_name": "HBoxModel",
986
+ "_view_count": null,
987
+ "_view_module": "@jupyter-widgets/controls",
988
+ "_view_module_version": "1.5.0",
989
+ "_view_name": "HBoxView",
990
+ "box_style": "",
991
+ "children": [
992
+ "IPY_MODEL_c25700be00a04f41b6792c9a3e75cffc",
993
+ "IPY_MODEL_fa3fb7b518bf4d4f8b1201d16fe0767f",
994
+ "IPY_MODEL_9ff4dbe4ff744d2aae82de08feead57f"
995
+ ],
996
+ "layout": "IPY_MODEL_15c7a3f8f13d4812a436fe6ea3fb7573"
997
+ }
998
+ },
999
+ "c25700be00a04f41b6792c9a3e75cffc": {
1000
+ "model_module": "@jupyter-widgets/controls",
1001
+ "model_name": "HTMLModel",
1002
+ "model_module_version": "1.5.0",
1003
+ "state": {
1004
+ "_dom_classes": [],
1005
+ "_model_module": "@jupyter-widgets/controls",
1006
+ "_model_module_version": "1.5.0",
1007
+ "_model_name": "HTMLModel",
1008
+ "_view_count": null,
1009
+ "_view_module": "@jupyter-widgets/controls",
1010
+ "_view_module_version": "1.5.0",
1011
+ "_view_name": "HTMLView",
1012
+ "description": "",
1013
+ "description_tooltip": null,
1014
+ "layout": "IPY_MODEL_895122e40b324be1aae88771173ac719",
1015
+ "placeholder": "​",
1016
+ "style": "IPY_MODEL_bb72a3986e8d4dd2a551cdcada837881",
1017
+ "value": "Fetching 8 files: 100%"
1018
+ }
1019
+ },
1020
+ "fa3fb7b518bf4d4f8b1201d16fe0767f": {
1021
+ "model_module": "@jupyter-widgets/controls",
1022
+ "model_name": "FloatProgressModel",
1023
+ "model_module_version": "1.5.0",
1024
+ "state": {
1025
+ "_dom_classes": [],
1026
+ "_model_module": "@jupyter-widgets/controls",
1027
+ "_model_module_version": "1.5.0",
1028
+ "_model_name": "FloatProgressModel",
1029
+ "_view_count": null,
1030
+ "_view_module": "@jupyter-widgets/controls",
1031
+ "_view_module_version": "1.5.0",
1032
+ "_view_name": "ProgressView",
1033
+ "bar_style": "success",
1034
+ "description": "",
1035
+ "description_tooltip": null,
1036
+ "layout": "IPY_MODEL_8dd8f7deb5d64e80b30e348470ec21e6",
1037
+ "max": 8,
1038
+ "min": 0,
1039
+ "orientation": "horizontal",
1040
+ "style": "IPY_MODEL_c63216e05f8547ce9682b8570b954252",
1041
+ "value": 8
1042
+ }
1043
+ },
1044
+ "9ff4dbe4ff744d2aae82de08feead57f": {
1045
+ "model_module": "@jupyter-widgets/controls",
1046
+ "model_name": "HTMLModel",
1047
+ "model_module_version": "1.5.0",
1048
+ "state": {
1049
+ "_dom_classes": [],
1050
+ "_model_module": "@jupyter-widgets/controls",
1051
+ "_model_module_version": "1.5.0",
1052
+ "_model_name": "HTMLModel",
1053
+ "_view_count": null,
1054
+ "_view_module": "@jupyter-widgets/controls",
1055
+ "_view_module_version": "1.5.0",
1056
+ "_view_name": "HTMLView",
1057
+ "description": "",
1058
+ "description_tooltip": null,
1059
+ "layout": "IPY_MODEL_c5b57f3fa4b847baa7548ce653d9aaa2",
1060
+ "placeholder": "​",
1061
+ "style": "IPY_MODEL_b465c6b89cc74a358d7b0aff13d5c058",
1062
+ "value": " 8/8 [00:00&lt;00:00, 267.14it/s]"
1063
+ }
1064
+ },
1065
+ "15c7a3f8f13d4812a436fe6ea3fb7573": {
1066
+ "model_module": "@jupyter-widgets/base",
1067
+ "model_name": "LayoutModel",
1068
+ "model_module_version": "1.2.0",
1069
+ "state": {
1070
+ "_model_module": "@jupyter-widgets/base",
1071
+ "_model_module_version": "1.2.0",
1072
+ "_model_name": "LayoutModel",
1073
+ "_view_count": null,
1074
+ "_view_module": "@jupyter-widgets/base",
1075
+ "_view_module_version": "1.2.0",
1076
+ "_view_name": "LayoutView",
1077
+ "align_content": null,
1078
+ "align_items": null,
1079
+ "align_self": null,
1080
+ "border": null,
1081
+ "bottom": null,
1082
+ "display": null,
1083
+ "flex": null,
1084
+ "flex_flow": null,
1085
+ "grid_area": null,
1086
+ "grid_auto_columns": null,
1087
+ "grid_auto_flow": null,
1088
+ "grid_auto_rows": null,
1089
+ "grid_column": null,
1090
+ "grid_gap": null,
1091
+ "grid_row": null,
1092
+ "grid_template_areas": null,
1093
+ "grid_template_columns": null,
1094
+ "grid_template_rows": null,
1095
+ "height": null,
1096
+ "justify_content": null,
1097
+ "justify_items": null,
1098
+ "left": null,
1099
+ "margin": null,
1100
+ "max_height": null,
1101
+ "max_width": null,
1102
+ "min_height": null,
1103
+ "min_width": null,
1104
+ "object_fit": null,
1105
+ "object_position": null,
1106
+ "order": null,
1107
+ "overflow": null,
1108
+ "overflow_x": null,
1109
+ "overflow_y": null,
1110
+ "padding": null,
1111
+ "right": null,
1112
+ "top": null,
1113
+ "visibility": null,
1114
+ "width": null
1115
+ }
1116
+ },
1117
+ "895122e40b324be1aae88771173ac719": {
1118
+ "model_module": "@jupyter-widgets/base",
1119
+ "model_name": "LayoutModel",
1120
+ "model_module_version": "1.2.0",
1121
+ "state": {
1122
+ "_model_module": "@jupyter-widgets/base",
1123
+ "_model_module_version": "1.2.0",
1124
+ "_model_name": "LayoutModel",
1125
+ "_view_count": null,
1126
+ "_view_module": "@jupyter-widgets/base",
1127
+ "_view_module_version": "1.2.0",
1128
+ "_view_name": "LayoutView",
1129
+ "align_content": null,
1130
+ "align_items": null,
1131
+ "align_self": null,
1132
+ "border": null,
1133
+ "bottom": null,
1134
+ "display": null,
1135
+ "flex": null,
1136
+ "flex_flow": null,
1137
+ "grid_area": null,
1138
+ "grid_auto_columns": null,
1139
+ "grid_auto_flow": null,
1140
+ "grid_auto_rows": null,
1141
+ "grid_column": null,
1142
+ "grid_gap": null,
1143
+ "grid_row": null,
1144
+ "grid_template_areas": null,
1145
+ "grid_template_columns": null,
1146
+ "grid_template_rows": null,
1147
+ "height": null,
1148
+ "justify_content": null,
1149
+ "justify_items": null,
1150
+ "left": null,
1151
+ "margin": null,
1152
+ "max_height": null,
1153
+ "max_width": null,
1154
+ "min_height": null,
1155
+ "min_width": null,
1156
+ "object_fit": null,
1157
+ "object_position": null,
1158
+ "order": null,
1159
+ "overflow": null,
1160
+ "overflow_x": null,
1161
+ "overflow_y": null,
1162
+ "padding": null,
1163
+ "right": null,
1164
+ "top": null,
1165
+ "visibility": null,
1166
+ "width": null
1167
+ }
1168
+ },
1169
+ "bb72a3986e8d4dd2a551cdcada837881": {
1170
+ "model_module": "@jupyter-widgets/controls",
1171
+ "model_name": "DescriptionStyleModel",
1172
+ "model_module_version": "1.5.0",
1173
+ "state": {
1174
+ "_model_module": "@jupyter-widgets/controls",
1175
+ "_model_module_version": "1.5.0",
1176
+ "_model_name": "DescriptionStyleModel",
1177
+ "_view_count": null,
1178
+ "_view_module": "@jupyter-widgets/base",
1179
+ "_view_module_version": "1.2.0",
1180
+ "_view_name": "StyleView",
1181
+ "description_width": ""
1182
+ }
1183
+ },
1184
+ "8dd8f7deb5d64e80b30e348470ec21e6": {
1185
+ "model_module": "@jupyter-widgets/base",
1186
+ "model_name": "LayoutModel",
1187
+ "model_module_version": "1.2.0",
1188
+ "state": {
1189
+ "_model_module": "@jupyter-widgets/base",
1190
+ "_model_module_version": "1.2.0",
1191
+ "_model_name": "LayoutModel",
1192
+ "_view_count": null,
1193
+ "_view_module": "@jupyter-widgets/base",
1194
+ "_view_module_version": "1.2.0",
1195
+ "_view_name": "LayoutView",
1196
+ "align_content": null,
1197
+ "align_items": null,
1198
+ "align_self": null,
1199
+ "border": null,
1200
+ "bottom": null,
1201
+ "display": null,
1202
+ "flex": null,
1203
+ "flex_flow": null,
1204
+ "grid_area": null,
1205
+ "grid_auto_columns": null,
1206
+ "grid_auto_flow": null,
1207
+ "grid_auto_rows": null,
1208
+ "grid_column": null,
1209
+ "grid_gap": null,
1210
+ "grid_row": null,
1211
+ "grid_template_areas": null,
1212
+ "grid_template_columns": null,
1213
+ "grid_template_rows": null,
1214
+ "height": null,
1215
+ "justify_content": null,
1216
+ "justify_items": null,
1217
+ "left": null,
1218
+ "margin": null,
1219
+ "max_height": null,
1220
+ "max_width": null,
1221
+ "min_height": null,
1222
+ "min_width": null,
1223
+ "object_fit": null,
1224
+ "object_position": null,
1225
+ "order": null,
1226
+ "overflow": null,
1227
+ "overflow_x": null,
1228
+ "overflow_y": null,
1229
+ "padding": null,
1230
+ "right": null,
1231
+ "top": null,
1232
+ "visibility": null,
1233
+ "width": null
1234
+ }
1235
+ },
1236
+ "c63216e05f8547ce9682b8570b954252": {
1237
+ "model_module": "@jupyter-widgets/controls",
1238
+ "model_name": "ProgressStyleModel",
1239
+ "model_module_version": "1.5.0",
1240
+ "state": {
1241
+ "_model_module": "@jupyter-widgets/controls",
1242
+ "_model_module_version": "1.5.0",
1243
+ "_model_name": "ProgressStyleModel",
1244
+ "_view_count": null,
1245
+ "_view_module": "@jupyter-widgets/base",
1246
+ "_view_module_version": "1.2.0",
1247
+ "_view_name": "StyleView",
1248
+ "bar_color": null,
1249
+ "description_width": ""
1250
+ }
1251
+ },
1252
+ "c5b57f3fa4b847baa7548ce653d9aaa2": {
1253
+ "model_module": "@jupyter-widgets/base",
1254
+ "model_name": "LayoutModel",
1255
+ "model_module_version": "1.2.0",
1256
+ "state": {
1257
+ "_model_module": "@jupyter-widgets/base",
1258
+ "_model_module_version": "1.2.0",
1259
+ "_model_name": "LayoutModel",
1260
+ "_view_count": null,
1261
+ "_view_module": "@jupyter-widgets/base",
1262
+ "_view_module_version": "1.2.0",
1263
+ "_view_name": "LayoutView",
1264
+ "align_content": null,
1265
+ "align_items": null,
1266
+ "align_self": null,
1267
+ "border": null,
1268
+ "bottom": null,
1269
+ "display": null,
1270
+ "flex": null,
1271
+ "flex_flow": null,
1272
+ "grid_area": null,
1273
+ "grid_auto_columns": null,
1274
+ "grid_auto_flow": null,
1275
+ "grid_auto_rows": null,
1276
+ "grid_column": null,
1277
+ "grid_gap": null,
1278
+ "grid_row": null,
1279
+ "grid_template_areas": null,
1280
+ "grid_template_columns": null,
1281
+ "grid_template_rows": null,
1282
+ "height": null,
1283
+ "justify_content": null,
1284
+ "justify_items": null,
1285
+ "left": null,
1286
+ "margin": null,
1287
+ "max_height": null,
1288
+ "max_width": null,
1289
+ "min_height": null,
1290
+ "min_width": null,
1291
+ "object_fit": null,
1292
+ "object_position": null,
1293
+ "order": null,
1294
+ "overflow": null,
1295
+ "overflow_x": null,
1296
+ "overflow_y": null,
1297
+ "padding": null,
1298
+ "right": null,
1299
+ "top": null,
1300
+ "visibility": null,
1301
+ "width": null
1302
+ }
1303
+ },
1304
+ "b465c6b89cc74a358d7b0aff13d5c058": {
1305
+ "model_module": "@jupyter-widgets/controls",
1306
+ "model_name": "DescriptionStyleModel",
1307
+ "model_module_version": "1.5.0",
1308
+ "state": {
1309
+ "_model_module": "@jupyter-widgets/controls",
1310
+ "_model_module_version": "1.5.0",
1311
+ "_model_name": "DescriptionStyleModel",
1312
+ "_view_count": null,
1313
+ "_view_module": "@jupyter-widgets/base",
1314
+ "_view_module_version": "1.2.0",
1315
+ "_view_name": "StyleView",
1316
+ "description_width": ""
1317
+ }
1318
+ }
1319
+ }
1320
+ }
1321
+ },
1322
+ "cells": [
1323
+ {
1324
+ "cell_type": "code",
1325
+ "source": [
1326
+ "!pip install transformers"
1327
+ ],
1328
+ "metadata": {
1329
+ "colab": {
1330
+ "base_uri": "https://localhost:8080/"
1331
+ },
1332
+ "id": "Ac2NHDhEJStP",
1333
+ "outputId": "72a7436e-12aa-4a3a-ccd8-820a4d7d69c5"
1334
+ },
1335
+ "execution_count": 3,
1336
+ "outputs": [
1337
+ {
1338
+ "output_type": "stream",
1339
+ "name": "stdout",
1340
+ "text": [
1341
+ "Collecting transformers\n",
1342
+ " Downloading transformers-4.35.0-py3-none-any.whl (7.9 MB)\n",
1343
+ "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m7.9/7.9 MB\u001b[0m \u001b[31m46.5 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
1344
+ "\u001b[?25hRequirement already satisfied: filelock in /usr/local/lib/python3.10/dist-packages (from transformers) (3.12.4)\n",
1345
+ "Collecting huggingface-hub<1.0,>=0.16.4 (from transformers)\n",
1346
+ " Downloading huggingface_hub-0.18.0-py3-none-any.whl (301 kB)\n",
1347
+ "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m302.0/302.0 kB\u001b[0m \u001b[31m29.6 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
1348
+ "\u001b[?25hRequirement already satisfied: numpy>=1.17 in /usr/local/lib/python3.10/dist-packages (from transformers) (1.23.5)\n",
1349
+ "Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.10/dist-packages (from transformers) (23.2)\n",
1350
+ "Requirement already satisfied: pyyaml>=5.1 in /usr/local/lib/python3.10/dist-packages (from transformers) (6.0.1)\n",
1351
+ "Requirement already satisfied: regex!=2019.12.17 in /usr/local/lib/python3.10/dist-packages (from transformers) (2023.6.3)\n",
1352
+ "Requirement already satisfied: requests in /usr/local/lib/python3.10/dist-packages (from transformers) (2.31.0)\n",
1353
+ "Collecting tokenizers<0.15,>=0.14 (from transformers)\n",
1354
+ " Downloading tokenizers-0.14.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.8 MB)\n",
1355
+ "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m3.8/3.8 MB\u001b[0m \u001b[31m99.1 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
1356
+ "\u001b[?25hCollecting safetensors>=0.3.1 (from transformers)\n",
1357
+ " Downloading safetensors-0.4.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB)\n",
1358
+ "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m1.3/1.3 MB\u001b[0m \u001b[31m61.0 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
1359
+ "\u001b[?25hRequirement already satisfied: tqdm>=4.27 in /usr/local/lib/python3.10/dist-packages (from transformers) (4.66.1)\n",
1360
+ "Requirement already satisfied: fsspec>=2023.5.0 in /usr/local/lib/python3.10/dist-packages (from huggingface-hub<1.0,>=0.16.4->transformers) (2023.6.0)\n",
1361
+ "Requirement already satisfied: typing-extensions>=3.7.4.3 in /usr/local/lib/python3.10/dist-packages (from huggingface-hub<1.0,>=0.16.4->transformers) (4.5.0)\n",
1362
+ "Collecting huggingface-hub<1.0,>=0.16.4 (from transformers)\n",
1363
+ " Downloading huggingface_hub-0.17.3-py3-none-any.whl (295 kB)\n",
1364
+ "\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m295.0/295.0 kB\u001b[0m \u001b[31m27.5 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n",
1365
+ "\u001b[?25hRequirement already satisfied: charset-normalizer<4,>=2 in /usr/local/lib/python3.10/dist-packages (from requests->transformers) (3.3.1)\n",
1366
+ "Requirement already satisfied: idna<4,>=2.5 in /usr/local/lib/python3.10/dist-packages (from requests->transformers) (3.4)\n",
1367
+ "Requirement already satisfied: urllib3<3,>=1.21.1 in /usr/local/lib/python3.10/dist-packages (from requests->transformers) (2.0.7)\n",
1368
+ "Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.10/dist-packages (from requests->transformers) (2023.7.22)\n",
1369
+ "Installing collected packages: safetensors, huggingface-hub, tokenizers, transformers\n",
1370
+ "Successfully installed huggingface-hub-0.17.3 safetensors-0.4.0 tokenizers-0.14.1 transformers-4.35.0\n"
1371
+ ]
1372
+ }
1373
+ ]
1374
+ },
1375
+ {
1376
+ "cell_type": "code",
1377
+ "source": [
1378
+ "!huggingface-cli login\n",
1379
+ "#from huggingface_hub import notebook_login\n",
1380
+ "#notebook_login()"
1381
+ ],
1382
+ "metadata": {
1383
+ "colab": {
1384
+ "base_uri": "https://localhost:8080/",
1385
+ "height": 509,
1386
+ "referenced_widgets": [
1387
+ "afb4cf60647746cea3e1ef02bd4637fb",
1388
+ "0645cea30b14400aa891ef4223c0e52d",
1389
+ "80633cc88f124faf8f4aa3dc2c5d8550",
1390
+ "3a632a25760f4fbbbba8078825084a55",
1391
+ "f9c6c58d612447eab1af89ec963afa9e",
1392
+ "12a3006fa511479d802c869977087f08",
1393
+ "2b7db7372ba64aa899516acad2df2cca",
1394
+ "e4ef40a5fe904eeea29938f2b399521f",
1395
+ "58f4807b08fc4e4ca6eed3d266c2990e",
1396
+ "614d8f9b2a684344a6308886d6a6a965",
1397
+ "7ea45a099d7d4f89aa221426b0b31738",
1398
+ "80a77d6070284a5a88a42c1f7ae9438d",
1399
+ "6f2700e5f2f549978717c117122b77b4",
1400
+ "3fb30bbe0b4f445992638460afab6542",
1401
+ "72a2c3784981458f9279b3e817ac2f66",
1402
+ "f9fbc0bca2434a468eb561531e070807",
1403
+ "87800c464d694f5a953b4ea27b8eccab",
1404
+ "fd2fd0d53cd24e0cabf6478529ebd794",
1405
+ "9a42ecb77a184287ab35ff44c1da21df",
1406
+ "f998e7f3df9d42c7953f288bc3fd039a",
1407
+ "343c47eaccd249c8a797b2c1378603c5",
1408
+ "aba32fb028f447ee91c74092b14e494f",
1409
+ "59901c4463764d719fc799e52c91a07a",
1410
+ "7d591e5027c54034a51ae0ffc6fbb9c3",
1411
+ "7efa196b0c24409d8ee0b23ad303f653",
1412
+ "9f7f6ce9ee854d65827321123c82b9f6",
1413
+ "7afcba778e9048a29044aaf01aec7ca2",
1414
+ "ab0c301db6104a37abb4051f9f90a896",
1415
+ "eb262072aa73425ba9bc5324f5920665",
1416
+ "c475ac1a2f904d038944cb7e4a65812e",
1417
+ "e1af2b8270ca43aa9c9b0f7f4acd5300",
1418
+ "cd7b4ce4f200489cbfbf0174b0561511"
1419
+ ]
1420
+ },
1421
+ "id": "4PwffMXrLsVy",
1422
+ "outputId": "16bf648d-2275-40b0-c1db-fee21ee94699"
1423
+ },
1424
+ "execution_count": 4,
1425
+ "outputs": [
1426
+ {
1427
+ "output_type": "stream",
1428
+ "name": "stdout",
1429
+ "text": [
1430
+ "\n",
1431
+ " _| _| _| _| _|_|_| _|_|_| _|_|_| _| _| _|_|_| _|_|_|_| _|_| _|_|_| _|_|_|_|\n",
1432
+ " _| _| _| _| _| _| _| _|_| _| _| _| _| _| _| _|\n",
1433
+ " _|_|_|_| _| _| _| _|_| _| _|_| _| _| _| _| _| _|_| _|_|_| _|_|_|_| _| _|_|_|\n",
1434
+ " _| _| _| _| _| _| _| _| _| _| _|_| _| _| _| _| _| _| _|\n",
1435
+ " _| _| _|_| _|_|_| _|_|_| _|_|_| _| _| _|_|_| _| _| _| _|_|_| _|_|_|_|\n",
1436
+ " \n",
1437
+ " To login, `huggingface_hub` requires a token generated from https://huggingface.co/settings/tokens .\n",
1438
+ "Token: \n",
1439
+ "Add token as git credential? (Y/n) y\n",
1440
+ "Token is valid (permission: write).\n",
1441
+ "\u001b[1m\u001b[31mCannot authenticate through git-credential as no helper is defined on your machine.\n",
1442
+ "You might have to re-authenticate when pushing to the Hugging Face Hub.\n",
1443
+ "Run the following command in your terminal in case you want to set the 'store' credential helper as default.\n",
1444
+ "\n",
1445
+ "git config --global credential.helper store\n",
1446
+ "\n",
1447
+ "Read https://git-scm.com/book/en/v2/Git-Tools-Credential-Storage for more details.\u001b[0m\n",
1448
+ "Token has not been saved to git credential helper.\n",
1449
+ "Your token has been saved to /root/.cache/huggingface/token\n",
1450
+ "Login successful\n"
1451
+ ]
1452
+ },
1453
+ {
1454
+ "output_type": "display_data",
1455
+ "data": {
1456
+ "text/plain": [
1457
+ "VBox(children=(HTML(value='<center> <img\\nsrc=https://huggingface.co/front/assets/huggingface_logo-noborder.sv…"
1458
+ ],
1459
+ "application/vnd.jupyter.widget-view+json": {
1460
+ "version_major": 2,
1461
+ "version_minor": 0,
1462
+ "model_id": "afb4cf60647746cea3e1ef02bd4637fb"
1463
+ }
1464
+ },
1465
+ "metadata": {}
1466
+ }
1467
+ ]
1468
+ },
1469
+ {
1470
+ "cell_type": "code",
1471
+ "execution_count": 11,
1472
+ "metadata": {
1473
+ "colab": {
1474
+ "base_uri": "https://localhost:8080/",
1475
+ "height": 101,
1476
+ "referenced_widgets": [
1477
+ "7ed17347ad114ee6a3f5bbe44547458e",
1478
+ "c25700be00a04f41b6792c9a3e75cffc",
1479
+ "fa3fb7b518bf4d4f8b1201d16fe0767f",
1480
+ "9ff4dbe4ff744d2aae82de08feead57f",
1481
+ "15c7a3f8f13d4812a436fe6ea3fb7573",
1482
+ "895122e40b324be1aae88771173ac719",
1483
+ "bb72a3986e8d4dd2a551cdcada837881",
1484
+ "8dd8f7deb5d64e80b30e348470ec21e6",
1485
+ "c63216e05f8547ce9682b8570b954252",
1486
+ "c5b57f3fa4b847baa7548ce653d9aaa2",
1487
+ "b465c6b89cc74a358d7b0aff13d5c058"
1488
+ ]
1489
+ },
1490
+ "id": "vnRfcWYuJFSd",
1491
+ "outputId": "e662c39e-f5a9-412e-b9cc-632baed6b263"
1492
+ },
1493
+ "outputs": [
1494
+ {
1495
+ "output_type": "stream",
1496
+ "name": "stderr",
1497
+ "text": [
1498
+ "config.json not found in HuggingFace Hub.\n",
1499
+ "WARNING:huggingface_hub.hub_mixin:config.json not found in HuggingFace Hub.\n"
1500
+ ]
1501
+ },
1502
+ {
1503
+ "output_type": "display_data",
1504
+ "data": {
1505
+ "text/plain": [
1506
+ "Fetching 8 files: 0%| | 0/8 [00:00<?, ?it/s]"
1507
+ ],
1508
+ "application/vnd.jupyter.widget-view+json": {
1509
+ "version_major": 2,
1510
+ "version_minor": 0,
1511
+ "model_id": "7ed17347ad114ee6a3f5bbe44547458e"
1512
+ }
1513
+ },
1514
+ "metadata": {}
1515
+ },
1516
+ {
1517
+ "output_type": "stream",
1518
+ "name": "stderr",
1519
+ "text": [
1520
+ "WARNING:tensorflow:No training configuration found in save file, so the model was *not* compiled. Compile it manually.\n"
1521
+ ]
1522
+ }
1523
+ ],
1524
+ "source": [
1525
+ "from huggingface_hub import from_pretrained_keras\n",
1526
+ "\n",
1527
+ "model = from_pretrained_keras(\"mabzak/lstm-id-yt-comment\")"
1528
+ ]
1529
+ },
1530
+ {
1531
+ "cell_type": "code",
1532
+ "source": [
1533
+ "from tensorflow.keras.preprocessing.text import Tokenizer\n",
1534
+ "import pandas as pd\n",
1535
+ "from keras.preprocessing.text import Tokenizer\n",
1536
+ "from tensorflow.keras.preprocessing.sequence import pad_sequences"
1537
+ ],
1538
+ "metadata": {
1539
+ "id": "ASQghJpLYx_I"
1540
+ },
1541
+ "execution_count": 13,
1542
+ "outputs": []
1543
+ },
1544
+ {
1545
+ "cell_type": "code",
1546
+ "source": [
1547
+ "# Gantilah 'comments.csv' dengan nama file CSV yang sesuai\n",
1548
+ "df = pd.read_csv('https://huggingface.co/datasets/mabzak/indonesia-youtube-comment/raw/main/comment1.csv')\n",
1549
+ "texts = df['text']\n",
1550
+ "\n",
1551
+ "# Membuang baris dengan nilai teks yang hilang\n",
1552
+ "texts = texts.dropna()\n",
1553
+ "\n",
1554
+ "# Tokenisasi dan pembuatan representasi numerik dari kata-kata\n",
1555
+ "tokenizer = Tokenizer()\n",
1556
+ "tokenizer.fit_on_texts(texts)\n",
1557
+ "total_words = len(tokenizer.word_index) + 1"
1558
+ ],
1559
+ "metadata": {
1560
+ "id": "JRJ2mLn4XQcM"
1561
+ },
1562
+ "execution_count": 15,
1563
+ "outputs": []
1564
+ },
1565
+ {
1566
+ "cell_type": "code",
1567
+ "source": [
1568
+ "tokenizer"
1569
+ ],
1570
+ "metadata": {
1571
+ "colab": {
1572
+ "base_uri": "https://localhost:8080/"
1573
+ },
1574
+ "id": "7S_MvtZAb3nr",
1575
+ "outputId": "e3262896-35df-4f40-dbba-571c46349dd9"
1576
+ },
1577
+ "execution_count": 64,
1578
+ "outputs": [
1579
+ {
1580
+ "output_type": "execute_result",
1581
+ "data": {
1582
+ "text/plain": [
1583
+ "<keras.src.preprocessing.text.Tokenizer at 0x7d12a85ebe80>"
1584
+ ]
1585
+ },
1586
+ "metadata": {},
1587
+ "execution_count": 64
1588
+ }
1589
+ ]
1590
+ },
1591
+ {
1592
+ "cell_type": "code",
1593
+ "source": [
1594
+ "input_sequences = []\n",
1595
+ "for line in texts:\n",
1596
+ " token_list = tokenizer.texts_to_sequences([line])[0]\n",
1597
+ " for i in range(1, len(token_list)):\n",
1598
+ " n_gram_sequence = token_list[:i+1]\n",
1599
+ " input_sequences.append(n_gram_sequence)\n",
1600
+ "\n",
1601
+ "max_sequence_length = max([len(x) for x in input_sequences])\n",
1602
+ "input_sequences = pad_sequences(input_sequences, maxlen=max_sequence_length, padding='pre')\n",
1603
+ "predictors, label = input_sequences[:, :-1], input_sequences[:, -1]"
1604
+ ],
1605
+ "metadata": {
1606
+ "id": "PZC9THPtWHx7"
1607
+ },
1608
+ "execution_count": 16,
1609
+ "outputs": []
1610
+ },
1611
+ {
1612
+ "cell_type": "code",
1613
+ "source": [
1614
+ "import numpy as np\n",
1615
+ "\n",
1616
+ "def predict_next_sentence(seed_text, model, tokenizer, max_sequence_length, num_words):\n",
1617
+ " generated_sentence = seed_text\n",
1618
+ "\n",
1619
+ " for _ in range(num_words):\n",
1620
+ " token_list = tokenizer.texts_to_sequences([generated_sentence])[0]\n",
1621
+ " token_list = pad_sequences([token_list], maxlen=max_sequence_length-1, padding='pre')\n",
1622
+ " predicted_probs = model.predict(token_list, verbose=0)[0]\n",
1623
+ " predicted_index = np.argmax(predicted_probs)\n",
1624
+ "\n",
1625
+ " # Temukan kata yang sesuai dengan indeks prediksi\n",
1626
+ " output_word = \"\"\n",
1627
+ " for word, index in tokenizer.word_index.items():\n",
1628
+ " if index == predicted_index:\n",
1629
+ " output_word = word\n",
1630
+ " break\n",
1631
+ "\n",
1632
+ " # Tambahkan kata ke kalimat yang dihasilkan\n",
1633
+ " generated_sentence += \" \" + output_word\n",
1634
+ "\n",
1635
+ " return generated_sentence\n"
1636
+ ],
1637
+ "metadata": {
1638
+ "id": "JfUx3ItpV1k_"
1639
+ },
1640
+ "execution_count": 17,
1641
+ "outputs": []
1642
+ },
1643
+ {
1644
+ "cell_type": "code",
1645
+ "source": [
1646
+ "# Menggunakan seed text untuk memprediksi kalimat berikutnya\n",
1647
+ "seed_text = \"masa depan negara\"\n",
1648
+ "predicted_sentence = predict_next_sentence(seed_text, model, tokenizer, max_sequence_length, num_words=10)\n",
1649
+ "print(\"Kalimat yang Diprediksi:\", predicted_sentence)"
1650
+ ],
1651
+ "metadata": {
1652
+ "colab": {
1653
+ "base_uri": "https://localhost:8080/"
1654
+ },
1655
+ "id": "qcO83u2fVsKE",
1656
+ "outputId": "cbfebba6-ceb1-4bb0-d76d-305ce3491287"
1657
+ },
1658
+ "execution_count": 21,
1659
+ "outputs": [
1660
+ {
1661
+ "output_type": "stream",
1662
+ "name": "stdout",
1663
+ "text": [
1664
+ "Kalimat yang Diprediksi: masa depan negara ini saya yakin bisa di pimpin oleh orang yg baik\n"
1665
+ ]
1666
+ }
1667
+ ]
1668
+ },
1669
+ {
1670
+ "cell_type": "markdown",
1671
+ "source": [
1672
+ "\n",
1673
+ "\n",
1674
+ "---\n",
1675
+ "\n"
1676
+ ],
1677
+ "metadata": {
1678
+ "id": "sGs-qtsIltSr"
1679
+ }
1680
+ }
1681
+ ]
1682
+ }