Skip to content

Staging - #1039

Merged
iamzoltan merged 48 commits into
mainfrom
staging
Jun 18, 2026
Merged

Staging#1039
iamzoltan merged 48 commits into
mainfrom
staging

Conversation

@iamzoltan

Copy link
Copy Markdown
Contributor

No description provided.

cindyhfls and others added 30 commits April 5, 2026 18:08
- Rename W2D2_ConvnetsAndDlThinking → W2D2_Convnets
- W2D2_Tutorial1: remove Think! 0 (regularization overlap with W2D1),
  remove Bonus 2 (dropout/augmentation overlap with W2D1), keep Bonus 1
  training loop; add Section 5 Transfer Learning (moved from W2D2_Tutorial2);
  add ResNet one-sentence explainer; update "last week" → wording fixes
- W2D2_BonusLecture: merge W2D3_Tutorial1 (modern ConvNets) + W2D3_Tutorial2
  (facial recognition + ethics) into single bonus; renumber sections 1-8,
  videos 1-9; update feedback_prefix to W2D2_BL
- Remove W2D3_ModernConvnets folder entirely (content absorbed into W2D2)
- materials.yml: rename W2D2 day to Convnets; update tutorial count to 1;
  remove W2D3 day entry

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
For each tutorial (W2D1 T1+T2, W2D2 T1+BonusLecture, W2D4 T1+T2+T3, W2D5 T1+T2):
- Added version check / install cell to Setup section (prints key package
  versions; points local users to requirements.txt on GitHub)
- Consolidated imports to top-level Setup section: added os, requests,
  zipfile, random where missing; removed duplicate imports from Set Seed cells
- W2D4_Tutorial1: fixed `import matplotlib.pylab` → `import matplotlib.pyplot`
- W2D4_Tutorial3: removed duplicate `import numpy as np`
- W2D5_Tutorial2: moved `!pip install flair` from mid-notebook helper cell
  to Install dependencies cell
- Video player cells retain their local imports (consistent with W1 style)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Restore source field to array format after string conversion
introduced by our processing script. No content change.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…aterials.yml

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…rmers to W3D1

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Move Tutorial 1 and Bonus Lecture from old W2D4_GenerativeModels to new
W2D3_GenerativeModelsAndDeepLearningDiscussion1; rename W2D4 to DiffusionModels
with remaining tutorials; update materials.yml accordingly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Tutorial 1:
- Fix invalid escape sequences (\l, \s) in docstrings and plot titles
- Replace np.sqrt() on torch tensors with ** 0.5 throughout
- Restore missing "Define utils functions" cell (GaussianFourierProjection,
  ScoreModel_Time, sample_X_and_score_t_depend)

Tutorial 2:
- Fix invalid escape sequences in docstrings
- Swap gated SD model (stabilityai/stable-diffusion-2-1) to open model
  (stable-diffusion-v1-5/stable-diffusion-v1-5) with token=False to
  suppress HF token prompt on Colab
- Fix SD inference image not displaying (add explicit display() call)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
W2D2:
- Extract Bonus 1 training loop from T1 into new T2 (Writing Your Own
  Training Loop); rename former BonusLecture to T3 (Modern ConvNets and
  Facial Recognition); section headings, video numbers, feedback_prefix,
  and cross-references updated; materials.yml updated to 3 tutorials

W2D4:
- Rename folder W2D4_DiffusionModels → W2D4_DiffusionGenerativeModels
- Remove conditional diffusion bonus (Section 2) and training bonus from
  T2; renumber Section 3 Ethics → Section 2, Video 4 → Video 2,
  Think! 3 → Think! 2; update title and summary; T2 now 47 cells
- materials.yml: update name, remove stale Bonus Lecture slide entry

W2D5:
- Rename tutorial files W3D1_Tutorial*.ipynb → W2D5_Tutorial*.ipynb
  to match the day swap done in May; fix day line (Week 3, Day 1 →
  Week 2, Day 5) and feedback_prefix (W3D1_T* → W2D5_T*) in all three
  notebooks

materials.yml:
- W2D3 BonusLecture slide corrected from r9pjc → gx84r

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Rename W2D5_Tutorial*.ipynb → W3D1_Tutorial*.ipynb in
W3D1_AttentionAndTransformers to match the W2D5↔W3D1 day swap done
in May; fix day line (Week 2, Day 5 → Week 3, Day 1) and
feedback_prefix (W2D5_T* → W3D1_T*) in both notebooks.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ay names

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…, W2D5, W3D1

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Notebook Processing Failure Context

tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb

2026-06-18T02:44:48.6635529Z Executing tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb
2026-06-18T02:44:49.6876195Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T02:45:00.2912586Z tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb failed quality control.
2026-06-18T02:45:00.2913356Z ============================== Failure ==============================
2026-06-18T02:45:00.2913999Z An error occurred while executing the following cell:
2026-06-18T02:45:00.2914486Z ------------------
2026-06-18T02:45:00.2914874Z # Visualize the output of your function
2026-06-18T02:45:00.2915386Z from IPython.display import display as IPydisplay
2026-06-18T02:45:00.2915749Z 
2026-06-18T02:45:00.2916112Z with open("images/chicago_skyline_shrunk_v2.bmp", 'rb') as skyline_image_file:
2026-06-18T02:45:00.2916846Z   img_skyline_orig = Image.open(skyline_image_file)
2026-06-18T02:45:00.2917879Z   img_skyline_mat = np.asarray(img_skyline_orig)
2026-06-18T02:45:00.2918461Z   kernel_ver = np.array([[-1, 0, 1], [-2, 0, 2], [-1, 0, 1]])
2026-06-18T02:45:00.2919071Z   kernel_hor = np.array([[-1, 0, 1], [-2, 0, 2], [-1, 0, 1]]).T
2026-06-18T02:45:00.2919737Z   img_processed_mat_ver = convolution2d(img_skyline_mat, kernel_ver)
2026-06-18T02:45:00.2920445Z   img_processed_mat_hor = convolution2d(img_skyline_mat, kernel_hor)
2026-06-18T02:45:00.2921384Z   img_processed_mat = np.sqrt(np.multiply(img_processed_mat_ver,
2026-06-18T02:45:00.2921996Z                                           img_processed_mat_ver) + \
2026-06-18T02:45:00.2922533Z                               np.multiply(img_processed_mat_hor,
2026-06-18T02:45:00.2923069Z                                           img_processed_mat_hor))
2026-06-18T02:45:00.2923414Z 
2026-06-18T02:45:00.2923610Z   img_processed_mat *= 255.0/img_processed_mat.max()
2026-06-18T02:45:00.2924191Z   img_processed_mat = img_processed_mat.astype(np.uint8)
2026-06-18T02:45:00.2924778Z   img_processed = Image.fromarray(img_processed_mat, 'L')
2026-06-18T02:45:00.2925291Z   width, height = img_skyline_orig.size
2026-06-18T02:45:00.2925717Z   scale = 0.6
2026-06-18T02:45:00.2926232Z   IPydisplay(img_skyline_orig.resize((int(width*scale), int(height*scale))),
2026-06-18T02:45:00.2926885Z              Image.NEAREST)
2026-06-18T02:45:00.2927674Z   IPydisplay(img_processed.resize((int(width*scale), int(height*scale))),
2026-06-18T02:45:00.2928259Z              Image.NEAREST)
2026-06-18T02:45:00.2928608Z ------------------
2026-06-18T02:45:00.2928807Z 
2026-06-18T02:45:00.2928814Z 
2026-06-18T02:45:00.2929409Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T02:45:00.2930317Z �[0;31mUnidentifiedImageError�[0m                    Traceback (most recent call last)
2026-06-18T02:45:00.2931034Z Cell �[0;32mIn[30], line 5�[0m
2026-06-18T02:45:00.2932610Z �[1;32m      2�[0m �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;21;01mIPython�[39;00m�[38;5;21;01m.�[39;00m�[38;5;21;01mdisplay�[39;00m�[38;5;250m �[39m�[38;5;28;01mimport�[39;00m display �[38;5;28;01mas�[39;00m IPydisplay
2026-06-18T02:45:00.2934849Z �[1;32m      4�[0m �[38;5;28;01mwith�[39;00m �[38;5;28mopen�[39m(�[38;5;124m"�[39m�[38;5;124mimages/chicago_skyline_shrunk_v2.bmp�[39m�[38;5;124m"�[39m, �[38;5;124m'�[39m�[38;5;124mrb�[39m�[38;5;124m'�[39m) �[38;5;28;01mas�[39;00m skyline_image_file:
2026-06-18T02:45:00.2936694Z �[0;32m----> 5�[0m   img_skyline_orig �[38;5;241m=�[39m �[43mImage�[49m�[38;5;241;43m.�[39;49m�[43mopen�[49m�[43m(�[49m�[43mskyline_image_file�[49m�[43m)�[49m
2026-06-18T02:45:00.2937890Z �[1;32m      6�[0m   img_skyline_mat �[38;5;241m=�[39m np�[38;5;241m.�[39masarray(img_skyline_orig)
2026-06-18T02:45:00.2939756Z �[1;32m      7�[0m   kernel_ver �[38;5;241m=�[39m np�[38;5;241m.�[39marray([[�[38;5;241m-�[39m�[38;5;241m1�[39m, �[38;5;241m0�[39m, �[38;5;241m1�[39m], [�[38;5;241m-�[39m�[38;5;241m2�[39m, �[38;5;241m0�[39m, �[38;5;241m2�[39m], [�[38;5;241m-�[39m�[38;5;241m1�[39m, �[38;5;241m0�[39m, �[38;5;241m1�[39m]])
2026-06-18T02:45:00.2940946Z 
2026-06-18T02:45:00.2942167Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/PIL/Image.py:3711�[0m, in �[0;36mopen�[0;34m(fp, mode, formats)�[0m
2026-06-18T02:45:00.2943293Z �[1;32m   3709�[0m     warnings�[38;5;241m.�[39mwarn(message)
2026-06-18T02:45:00.2944841Z �[1;32m   3710�[0m msg �[38;5;241m=�[39m �[38;5;124m"�[39m�[38;5;124mcannot identify image file �[39m�[38;5;132;01m%r�[39;00m�[38;5;124m"�[39m �[38;5;241m%�[39m (filename �[38;5;28;01mif�[39;00m filename �[38;5;28;01melse�[39;00m fp)
2026-06-18T02:45:00.2946333Z �[0;32m-> 3711�[0m �[38;5;28;01mraise�[39;00m UnidentifiedImageError(msg)
2026-06-18T02:45:00.2946756Z 
2026-06-18T02:45:00.2947501Z �[0;31mUnidentifiedImageError�[0m: cannot identify image file <_io.BufferedReader name='images/chicago_skyline_shrunk_v2.bmp'>
2026-06-18T02:45:00.2948260Z 
2026-06-18T02:45:00.5643119Z ##[error]Process completed with exit code 1.

tutorials/W2D2_Convnets/W2D2_Tutorial3.ipynb

2026-06-18T02:46:34.2510380Z 
2026-06-18T02:46:34.2510525Z  95%|█████████▍| 220M/233M [00:07<00:00, 34.2MB/s]
2026-06-18T02:46:34.2510803Z ----- stderr -----
2026-06-18T02:46:34.2510925Z 
2026-06-18T02:46:34.2511067Z  96%|█████████▌| 224M/233M [00:07<00:00, 32.3MB/s]
2026-06-18T02:46:34.2511465Z ----- stderr -----
2026-06-18T02:46:34.2511582Z 
2026-06-18T02:46:34.2511956Z  98%|█████████▊| 228M/233M [00:08<00:00, 32.4MB/s]
2026-06-18T02:46:34.2512237Z ----- stderr -----
2026-06-18T02:46:34.2512358Z 
2026-06-18T02:46:34.2512516Z  99%|█████████▉| 232M/233M [00:08<00:00, 35.0MB/s]
2026-06-18T02:46:34.2512776Z ----- stderr -----
2026-06-18T02:46:34.2512893Z 
2026-06-18T02:46:34.2513043Z 100%|██████████| 233M/233M [00:08<00:00, 29.8MB/s]
2026-06-18T02:46:34.2513317Z ----- stderr -----
2026-06-18T02:46:34.2513435Z 
2026-06-18T02:46:34.2513512Z ------------------
2026-06-18T02:46:34.2513629Z 
2026-06-18T02:46:34.2513889Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T02:46:34.2514439Z �[0;31mAttributeError�[0m                            Traceback (most recent call last)
2026-06-18T02:46:34.2514872Z Cell �[0;32mIn[15], line 12�[0m
2026-06-18T02:46:34.2516038Z �[1;32m     11�[0m url, filename �[38;5;241m=�[39m (�[38;5;124m"�[39m�[38;5;124mhttps://raw.githubusercontent.com/NeuromatchAcademy/course-content-dl/main/tutorials/W2D2_Convnets/static/dog.jpg�[39m�[38;5;124m"�[39m, �[38;5;124m"�[39m�[38;5;124mdog.jpg�[39m�[38;5;124m"�[39m)
2026-06-18T02:46:34.2517407Z �[0;32m---> 12�[0m �[38;5;28;01mtry�[39;00m: urllib�[38;5;241m.�[39mURLopener()�[38;5;241m.�[39mretrieve(url, filename)
2026-06-18T02:46:34.2518165Z �[1;32m     13�[0m �[38;5;28;01mexcept�[39;00m: urllib�[38;5;241m.�[39mrequest�[38;5;241m.�[39murlretrieve(url, filename)
2026-06-18T02:46:34.2518554Z 
2026-06-18T02:46:34.2518804Z �[0;31mAttributeError�[0m: module 'urllib' has no attribute 'URLopener'
2026-06-18T02:46:34.2519101Z 
2026-06-18T02:46:34.2519296Z During handling of the above exception, another exception occurred:
2026-06-18T02:46:34.2519571Z 
2026-06-18T02:46:34.2519820Z �[0;31mHTTPError�[0m                                 Traceback (most recent call last)
2026-06-18T02:46:34.2520226Z Cell �[0;32mIn[15], line 13�[0m
2026-06-18T02:46:34.2521352Z �[1;32m     11�[0m url, filename �[38;5;241m=�[39m (�[38;5;124m"�[39m�[38;5;124mhttps://raw.githubusercontent.com/NeuromatchAcademy/course-content-dl/main/tutorials/W2D2_Convnets/static/dog.jpg�[39m�[38;5;124m"�[39m, �[38;5;124m"�[39m�[38;5;124mdog.jpg�[39m�[38;5;124m"�[39m)
2026-06-18T02:46:34.2522933Z �[1;32m     12�[0m �[38;5;28;01mtry�[39;00m: urllib�[38;5;241m.�[39mURLopener()�[38;5;241m.�[39mretrieve(url, filename)
2026-06-18T02:46:34.2523709Z �[0;32m---> 13�[0m �[38;5;28;01mexcept�[39;00m: urllib�[38;5;241m.�[39mrequest�[38;5;241m.�[39murlretrieve(url, filename)
2026-06-18T02:46:34.2524351Z �[1;32m     15�[0m input_image �[38;5;241m=�[39m Image�[38;5;241m.�[39mopen(filename)
2026-06-18T02:46:34.2524916Z �[1;32m     16�[0m preprocess �[38;5;241m=�[39m transforms�[38;5;241m.�[39mCompose([
2026-06-18T02:46:34.2525630Z �[1;32m     17�[0m                                  transforms�[38;5;241m.�[39mResize(�[38;5;241m256�[39m),
2026-06-18T02:46:34.2526244Z �[1;32m     18�[0m                                  transforms�[38;5;241m.�[39mCenterCrop(�[38;5;241m224�[39m),
2026-06-18T02:46:34.2526671Z �[0;32m   (...)�[0m
2026-06-18T02:46:34.2527210Z �[1;32m     21�[0m                                                       std�[38;5;241m=�[39m[�[38;5;241m0.229�[39m, �[38;5;241m0.224�[39m, �[38;5;241m0.225�[39m]),
2026-06-18T02:46:34.2527760Z �[1;32m     22�[0m                                  ])
2026-06-18T02:46:34.2527958Z 
2026-06-18T02:46:34.2528554Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:241�[0m, in �[0;36murlretrieve�[0;34m(url, filename, reporthook, data)�[0m
2026-06-18T02:46:34.2529309Z �[1;32m    224�[0m �[38;5;250m�[39m�[38;5;124;03m"""�[39;00m
2026-06-18T02:46:34.2529809Z �[1;32m    225�[0m �[38;5;124;03mRetrieve a URL into a temporary location on disk.�[39;00m
2026-06-18T02:46:34.2530224Z �[1;32m    226�[0m 
2026-06-18T02:46:34.2530450Z �[0;32m   (...)�[0m
2026-06-18T02:46:34.2530876Z �[1;32m    237�[0m �[38;5;124;03mdata file as well as the resulting HTTPMessage object.�[39;00m
2026-06-18T02:46:34.2531343Z �[1;32m    238�[0m �[38;5;124;03m"""�[39;00m
2026-06-18T02:46:34.2532238Z �[1;32m    239�[0m url_type, path �[38;5;241m=�[39m _splittype(url)
2026-06-18T02:46:34.2533145Z �[0;32m--> 241�[0m �[38;5;28;01mwith�[39;00m contextlib�[38;5;241m.�[39mclosing(�[43murlopen�[49m�[43m(�[49m�[43murl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m)�[49m) �[38;5;28;01mas�[39;00m fp:
2026-06-18T02:46:34.2533952Z �[1;32m    242�[0m     headers �[38;5;241m=�[39m fp�[38;5;241m.�[39minfo()
2026-06-18T02:46:34.2534550Z �[1;32m    244�[0m     �[38;5;66;03m# Just return the local path and the "headers" for file://�[39;00m
2026-06-18T02:46:34.2535182Z �[1;32m    245�[0m     �[38;5;66;03m# URLs. No sense in performing a copy unless requested.�[39;00m
2026-06-18T02:46:34.2535510Z 
2026-06-18T02:46:34.2536172Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:216�[0m, in �[0;36murlopen�[0;34m(url, data, timeout, cafile, capath, cadefault, context)�[0m
2026-06-18T02:46:34.2536934Z �[1;32m    214�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T02:46:34.2537298Z �[1;32m    215�[0m     opener �[38;5;241m=�[39m _opener
2026-06-18T02:46:34.2538161Z �[0;32m--> 216�[0m �[38;5;28;01mreturn�[39;00m �[43mopener�[49m�[38;5;241;43m.�[39;49m�[43mopen�[49m�[43m(�[49m�[43murl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m,�[49m�[43m �[49m�[43mtimeout�[49m�[43m)�[49m
2026-06-18T02:46:34.2538772Z 
2026-06-18T02:46:34.2539390Z File �[0;32m~/.ipython/profile_default/startup/00-stub-widgets.py:154�[0m, in �[0;36m_install_resilient_opener.<locals>._open_with_retry�[0;34m(fullurl, data, timeout)�[0m
2026-06-18T02:46:34.2540443Z �[1;32m    152�[0m �[38;5;28;01mfor�[39;00m attempt �[38;5;129;01min�[39;00m �[38;5;28mrange�[39m(_MAX_RETRIES �[38;5;241m+�[39m �[38;5;241m1�[39m):
2026-06-18T02:46:34.2541032Z �[1;32m    153�[0m     �[38;5;28;01mtry�[39;00m:
2026-06-18T02:46:34.2542066Z �[0;32m--> 154�[0m         �[38;5;28;01mreturn�[39;00m �[43m_inner_open�[49m�[43m(�[49m�[43mfullurl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m,�[49m�[43m �[49m�[43mtimeout�[49m�[43m)�[49m
2026-06-18T02:46:34.2543053Z �[1;32m    155�[0m     �[38;5;28;01mexcept�[39;00m urllib�[38;5;241m.�[39merror�[38;5;241m.�[39mHTTPError �[38;5;28;01mas�[39;00m e:
2026-06-18T02:46:34.2544080Z �[1;32m    156�[0m         �[38;5;28;01mif�[39;00m e�[38;5;241m.�[39mcode �[38;5;129;01mnot�[39;00m �[38;5;129;01min�[39;00m _RETRY_STATUSES �[38;5;129;01mor�[39;00m attempt �[38;5;241m==�[39m _MAX_RETRIES:
2026-06-18T02:46:34.2544671Z 
2026-06-18T02:46:34.2545270Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:525�[0m, in �[0;36mOpenerDirector.open�[0;34m(self, fullurl, data, timeout)�[0m
2026-06-18T02:46:34.2546356Z �[1;32m    523�[0m �[38;5;28;01mfor�[39;00m processor �[38;5;129;01min�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39mprocess_response�[38;5;241m.�[39mget(protocol, []):
2026-06-18T02:46:34.2547259Z �[1;32m    524�[0m     meth �[38;5;241m=�[39m �[38;5;28mgetattr�[39m(processor, meth_name)
2026-06-18T02:46:34.2548000Z �[0;32m--> 525�[0m     response �[38;5;241m=�[39m �[43mmeth�[49m�[43m(�[49m�[43mreq�[49m�[43m,�[49m�[43m �[49m�[43mresponse�[49m�[43m)�[49m
2026-06-18T02:46:34.2548607Z �[1;32m    527�[0m �[38;5;28;01mreturn�[39;00m response
2026-06-18T02:46:34.2548820Z 
2026-06-18T02:46:34.2549453Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:634�[0m, in �[0;36mHTTPErrorProcessor.http_response�[0;34m(self, request, response)�[0m
2026-06-18T02:46:34.2550387Z �[1;32m    631�[0m �[38;5;66;03m# According to RFC 2616, "2xx" code indicates that the client's�[39;00m
2026-06-18T02:46:34.2551053Z �[1;32m    632�[0m �[38;5;66;03m# request was successfully received, understood, and accepted.�[39;00m
2026-06-18T02:46:34.2552140Z �[1;32m    633�[0m �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m (�[38;5;241m200�[39m �[38;5;241m<�[39m�[38;5;241m=�[39m code �[38;5;241m<�[39m �[38;5;241m300�[39m):
2026-06-18T02:46:34.2553139Z �[0;32m--> 634�[0m     response �[38;5;241m=�[39m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43mparent�[49m�[38;5;241;43m.�[39;49m�[43merror�[49m�[43m(�[49m
2026-06-18T02:46:34.2554685Z �[1;32m    635�[0m �[43m        �[49m�[38;5;124;43m'�[39;49m�[38;5;124;43mhttp�[39;49m�[38;5;124;43m'�[39;49m�[43m,�[49m�[43m �[49m�[43mrequest�[49m�[43m,�[49m�[43m �[49m�[43mresponse�[49m�[43m,�[49m�[43m �[49m�[43mcode�[49m�[43m,�[49m�[43m �[49m�[43mmsg�[49m�[43m,�[49m�[43m �[49m�[43mhdrs�[49m�[43m)�[49m
2026-06-18T02:46:34.2555669Z �[1;32m    637�[0m �[38;5;28;01mreturn�[39;00m response
2026-06-18T02:46:34.2555882Z 
2026-06-18T02:46:34.2556453Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:563�[0m, in �[0;36mOpenerDirector.error�[0;34m(self, proto, *args)�[0m
2026-06-18T02:46:34.2557163Z �[1;32m    561�[0m �[38;5;28;01mif�[39;00m http_err:
2026-06-18T02:46:34.2558048Z �[1;32m    562�[0m     args �[38;5;241m=�[39m (�[38;5;28mdict�[39m, �[38;5;124m'�[39m�[38;5;124mdefault�[39m�[38;5;124m'�[39m, �[38;5;124m'�[39m�[38;5;124mhttp_error_default�[39m�[38;5;124m'�[39m) �[38;5;241m+�[39m orig_args
2026-06-18T02:46:34.2559215Z �[0;32m--> 563�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43m_call_chain�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m)�[49m
2026-06-18T02:46:34.2559737Z 
2026-06-18T02:46:34.2560384Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:496�[0m, in �[0;36mOpenerDirector._call_chain�[0;34m(self, chain, kind, meth_name, *args)�[0m
2026-06-18T02:46:34.2561252Z �[1;32m    494�[0m �[38;5;28;01mfor�[39;00m handler �[38;5;129;01min�[39;00m handlers:
2026-06-18T02:46:34.2562074Z �[1;32m    495�[0m     func �[38;5;241m=�[39m �[38;5;28mgetattr�[39m(handler, meth_name)
2026-06-18T02:46:34.2562819Z �[0;32m--> 496�[0m     result �[38;5;241m=�[39m �[43mfunc�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m)�[49m
2026-06-18T02:46:34.2563593Z �[1;32m    497�[0m     �[38;5;28;01mif�[39;00m result �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T02:46:34.2564160Z �[1;32m    498�[0m         �[38;5;28;01mreturn�[39;00m result
2026-06-18T02:46:34.2564394Z 
2026-06-18T02:46:34.2565113Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:643�[0m, in �[0;36mHTTPDefaultErrorHandler.http_error_default�[0;34m(self, req, fp, code, msg, hdrs)�[0m
2026-06-18T02:46:34.2566232Z �[1;32m    642�[0m �[38;5;28;01mdef�[39;00m�[38;5;250m �[39m�[38;5;21mhttp_error_default�[39m(�[38;5;28mself�[39m, req, fp, code, msg, hdrs):
2026-06-18T02:46:34.2567001Z �[0;32m--> 643�[0m     �[38;5;28;01mraise�[39;00m HTTPError(req�[38;5;241m.�[39mfull_url, code, msg, hdrs, fp)
2026-06-18T02:46:34.2567362Z 
2026-06-18T02:46:34.2567523Z �[0;31mHTTPError�[0m: HTTP Error 404: Not Found
2026-06-18T02:46:34.2567727Z 
2026-06-18T02:46:34.4683189Z ##[error]Process completed with exit code 1.

tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb

2026-06-18T02:44:47.8041836Z Executing tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb
2026-06-18T02:44:48.7462606Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T02:45:10.4584530Z tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb failed quality control.
2026-06-18T02:45:10.4585211Z An error occurred while executing the following cell:
2026-06-18T02:45:10.4585550Z ------------------
2026-06-18T02:45:10.4585965Z # @markdown Download BigGAN (a generative model) and a few standard image datasets
2026-06-18T02:45:10.4586319Z 
2026-06-18T02:45:10.4586433Z ## Initially was downloaded directly
2026-06-18T02:45:10.4586790Z # biggan_model = BigGAN.from_pretrained('biggan-deep-256')
2026-06-18T02:45:10.4587412Z 
2026-06-18T02:45:10.4587550Z url = "https://osf.io/3yvhw/download"
2026-06-18T02:45:10.4587859Z fname = "biggan_deep_256"
2026-06-18T02:45:10.4588143Z r = requests.get(url, allow_redirects=True)
2026-06-18T02:45:10.4588474Z with open(fname, 'wb') as fd:
2026-06-18T02:45:10.4588744Z   fd.write(r.content)
2026-06-18T02:45:10.4588893Z 
2026-06-18T02:45:10.4589006Z biggan_model = torch.load(fname)
2026-06-18T02:45:10.4589280Z ------------------
2026-06-18T02:45:10.4589421Z 
2026-06-18T02:45:10.4589426Z 
2026-06-18T02:45:10.4589888Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T02:45:10.4590519Z �[0;31mUnpicklingError�[0m                           Traceback (most recent call last)
2026-06-18T02:45:10.4591007Z Cell �[0;32mIn[14], line 12�[0m
2026-06-18T02:45:10.4591711Z �[1;32m      9�[0m �[38;5;28;01mwith�[39;00m �[38;5;28mopen�[39m(fname, �[38;5;124m'�[39m�[38;5;124mwb�[39m�[38;5;124m'�[39m) �[38;5;28;01mas�[39;00m fd:
2026-06-18T02:45:10.4592454Z �[1;32m     10�[0m   fd�[38;5;241m.�[39mwrite(r�[38;5;241m.�[39mcontent)
2026-06-18T02:45:10.4593501Z �[0;32m---> 12�[0m biggan_model �[38;5;241m=�[39m �[43mtorch�[49m�[38;5;241;43m.�[39;49m�[43mload�[49m�[43m(�[49m�[43mfname�[49m�[43m)�[49m
2026-06-18T02:45:10.4594435Z 
2026-06-18T02:45:10.4595889Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/serialization.py:1578�[0m, in �[0;36mload�[0;34m(f, map_location, pickle_module, weights_only, mmap, **pickle_load_args)�[0m
2026-06-18T02:45:10.4597055Z �[1;32m   1570�[0m                 �[38;5;28;01mreturn�[39;00m _load(
2026-06-18T02:45:10.4597518Z �[1;32m   1571�[0m                     opened_zipfile,
2026-06-18T02:45:10.4597929Z �[1;32m   1572�[0m                     map_location,
2026-06-18T02:45:10.4598280Z �[0;32m   (...)�[0m
2026-06-18T02:45:10.4598684Z �[1;32m   1575�[0m                     �[38;5;241m*�[39m�[38;5;241m*�[39mpickle_load_args,
2026-06-18T02:45:10.4599131Z �[1;32m   1576�[0m                 )
2026-06-18T02:45:10.4599682Z �[1;32m   1577�[0m             �[38;5;28;01mexcept�[39;00m pickle�[38;5;241m.�[39mUnpicklingError �[38;5;28;01mas�[39;00m e:
2026-06-18T02:45:10.4600742Z �[0;32m-> 1578�[0m                 �[38;5;28;01mraise�[39;00m pickle�[38;5;241m.�[39mUnpicklingError(_get_wo_message(�[38;5;28mstr�[39m(e))) �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T02:45:10.4601544Z �[1;32m   1579�[0m         �[38;5;28;01mreturn�[39;00m _load(
2026-06-18T02:45:10.4601919Z �[1;32m   1580�[0m             opened_zipfile,
2026-06-18T02:45:10.4602259Z �[1;32m   1581�[0m             map_location,
2026-06-18T02:45:10.4602550Z �[0;32m   (...)�[0m
2026-06-18T02:45:10.4602906Z �[1;32m   1584�[0m             �[38;5;241m*�[39m�[38;5;241m*�[39mpickle_load_args,
2026-06-18T02:45:10.4603581Z �[1;32m   1585�[0m         )
2026-06-18T02:45:10.4603894Z �[1;32m   1586�[0m �[38;5;28;01mif�[39;00m mmap:
2026-06-18T02:45:10.4604100Z 
2026-06-18T02:45:10.4604789Z �[0;31mUnpicklingError�[0m: Weights only load failed. This file can still be loaded, to do so you have two options, �[1mdo those steps only if you trust the source of the checkpoint�[0m. 
2026-06-18T02:45:10.4606371Z 	(1) In PyTorch 2.6, we changed the default value of the `weights_only` argument in `torch.load` from `False` to `True`. Re-running `torch.load` with `weights_only` set to `False` will likely succeed, but it can result in arbitrary code execution. Do it only if you got the file from a trusted source.
2026-06-18T02:45:10.4607734Z 	(2) Alternatively, to load with `weights_only=True` please check the recommended steps in the following error message.
2026-06-18T02:45:10.4609620Z 	WeightsUnpickler error: Unsupported global: GLOBAL pytorch_pretrained_biggan.model.BigGAN was not an allowed global by default. Please use `torch.serialization.add_safe_globals([pytorch_pretrained_biggan.model.BigGAN])` or the `torch.serialization.safe_globals([pytorch_pretrained_biggan.model.BigGAN])` context manager to allowlist this global if you trust this class/function.
2026-06-18T02:45:10.4610978Z 
2026-06-18T02:45:10.4611481Z Check the documentation of torch.load to learn more about types accepted by default with weights_only https://pytorch.org/docs/stable/generated/torch.load.html.
2026-06-18T02:45:10.4612073Z 
2026-06-18T02:45:10.4612214Z ============================== Failure ==============================
2026-06-18T02:45:10.7015844Z ##[error]Process completed with exit code 1.

tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial1.ipynb

2026-06-18T02:44:22.5007190Z Executing tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial1.ipynb
2026-06-18T02:44:23.6509095Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T02:44:36.4855335Z 
2026-06-18T02:44:36.4855935Z Read 0M words
2026-06-18T02:44:36.4856313Z Number of words:  8626
2026-06-18T02:44:45.9783795Z Number of labels: 0
2026-06-18T02:44:45.9784114Z 
2026-06-18T02:44:45.9784486Z Progress: 100.0% words/sec/thread:  293017 lr:  0.000000 avg.loss:  2.406399 ETA:   0h 0m 0s
2026-06-18T02:44:48.8237490Z tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial1.ipynb failed quality control.
2026-06-18T02:44:48.8238446Z An error occurred while executing the following cell:
2026-06-18T02:44:48.8239475Z ------------------
2026-06-18T02:44:48.8239970Z # Get closest words to the keys and get clusters of these words
2026-06-18T02:44:48.8240610Z embeddings_en_2d, word_clusters = get_cluster_embeddings(keys)
2026-06-18T02:44:48.8241137Z # tSNE plot of similar words to keys
2026-06-18T02:44:48.8241870Z tsne_plot_similar_words(title='Similar words from Brown Corpus',
2026-06-18T02:44:48.8242414Z                         labels=keys,
2026-06-18T02:44:48.8242864Z                         embedding_clusters=embeddings_en_2d,
2026-06-18T02:44:48.8243363Z                         word_clusters=word_clusters,
2026-06-18T02:44:48.8243792Z                         opacity=0.7,
2026-06-18T02:44:48.8244225Z                         filename='similar_words.png')
2026-06-18T02:44:48.8244644Z ------------------
2026-06-18T02:44:48.8244828Z 
2026-06-18T02:44:48.8244833Z 
2026-06-18T02:44:48.8245448Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T02:44:48.8246262Z �[0;31mTypeError�[0m                                 Traceback (most recent call last)
2026-06-18T02:44:48.8246880Z Cell �[0;32mIn[23], line 2�[0m
2026-06-18T02:44:48.8247591Z �[1;32m      1�[0m �[38;5;66;03m# Get closest words to the keys and get clusters of these words�[39;00m
2026-06-18T02:44:48.8248746Z �[0;32m----> 2�[0m embeddings_en_2d, word_clusters �[38;5;241m=�[39m �[43mget_cluster_embeddings�[49m�[43m(�[49m�[43mkeys�[49m�[43m)�[49m
2026-06-18T02:44:48.8249710Z �[1;32m      3�[0m �[38;5;66;03m# tSNE plot of similar words to keys�[39;00m
2026-06-18T02:44:48.8250743Z �[1;32m      4�[0m tsne_plot_similar_words(title�[38;5;241m=�[39m�[38;5;124m'�[39m�[38;5;124mSimilar words from Brown Corpus�[39m�[38;5;124m'�[39m,
2026-06-18T02:44:48.8251999Z �[1;32m      5�[0m                         labels�[38;5;241m=�[39mkeys,
2026-06-18T02:44:48.8252687Z �[1;32m      6�[0m                         embedding_clusters�[38;5;241m=�[39membeddings_en_2d,
2026-06-18T02:44:48.8253662Z �[1;32m      7�[0m                         word_clusters�[38;5;241m=�[39mword_clusters,
2026-06-18T02:44:48.8254320Z �[1;32m      8�[0m                         opacity�[38;5;241m=�[39m�[38;5;241m0.7�[39m,
2026-06-18T02:44:48.8255206Z �[1;32m      9�[0m                         filename�[38;5;241m=�[39m�[38;5;124m'�[39m�[38;5;124msimilar_words.png�[39m�[38;5;124m'�[39m)
2026-06-18T02:44:48.8255755Z 
2026-06-18T02:44:48.8256153Z Cell �[0;32mIn[22], line 30�[0m, in �[0;36mget_cluster_embeddings�[0;34m(keys)�[0m
2026-06-18T02:44:48.8257031Z �[1;32m     28�[0m embedding_clusters �[38;5;241m=�[39m np�[38;5;241m.�[39marray(embedding_clusters)
2026-06-18T02:44:48.8257700Z ============================== Failure ==============================
2026-06-18T02:44:48.8258601Z �[1;32m     29�[0m n, m, k �[38;5;241m=�[39m embedding_clusters�[38;5;241m.�[39mshape
2026-06-18T02:44:48.8262097Z �[0;32m---> 30�[0m tsne_model_en_2d �[38;5;241m=�[39m �[43mTSNE�[49m�[43m(�[49m�[43mperplexity�[49m�[38;5;241;43m=�[39;49m�[38;5;241;43m10�[39;49m�[43m,�[49m�[43m �[49m�[43mn_components�[49m�[38;5;241;43m=�[39;49m�[38;5;241;43m2�[39;49m�[43m,�[49m�[43m �[49m�[43minit�[49m�[38;5;241;43m=�[39;49m�[38;5;124;43m'�[39;49m�[38;5;124;43mpca�[39;49m�[38;5;124;43m'�[39;49m�[43m,�[49m�[43m �[49m�[43mn_iter�[49m�[38;5;241;43m=�[39;49m�[38;5;241;43m3500�[39;49m�[43m,�[49m�[43m �[49m�[43mrandom_state�[49m�[38;5;241;43m=�[39;49m�[38;5;241;43m32�[39;49m�[43m)�[49m
2026-06-18T02:44:48.8265450Z �[1;32m     31�[0m embeddings_en_2d �[38;5;241m=�[39m np�[38;5;241m.�[39marray(tsne_model_en_2d�[38;5;241m.�[39mfit_transform(embedding_clusters�[38;5;241m.�[39mreshape(n �[38;5;241m*�[39m m, k)))�[38;5;241m.�[39mreshape(n, m, �[38;5;241m2�[39m)
2026-06-18T02:44:48.8266846Z �[1;32m     32�[0m �[38;5;28;01mreturn�[39;00m embeddings_en_2d, word_clusters
2026-06-18T02:44:48.8267238Z 
2026-06-18T02:44:48.8267619Z �[0;31mTypeError�[0m: TSNE.__init__() got an unexpected keyword argument 'n_iter'
2026-06-18T02:44:48.8268062Z 
2026-06-18T02:44:49.1498978Z ##[error]Process completed with exit code 1.

tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial2.ipynb

2026-06-18T02:45:10.9541326Z An error occurred while executing the following cell:
2026-06-18T02:45:10.9541938Z ------------------
2026-06-18T02:45:10.9542411Z # Unlike _some_ code-generator models on the market, we'll limit our training data by license :)
2026-06-18T02:45:10.9542925Z dataset = load_dataset(
2026-06-18T02:45:10.9543588Z     "codeparrot/github-code",
2026-06-18T02:45:10.9543858Z     streaming=True,
2026-06-18T02:45:10.9544086Z     split="train",
2026-06-18T02:45:10.9544315Z     languages=["JavaScript"],
2026-06-18T02:45:10.9544587Z     licenses=["mit", "isc", "apache-2.0"],
2026-06-18T02:45:10.9544887Z     trust_remote_code=True,
2026-06-18T02:45:10.9545130Z )
2026-06-18T02:45:10.9545405Z # Print the schema of the first example from the training set:
2026-06-18T02:45:10.9545814Z print({k: type(v) for k, v in next(iter(dataset)).items()})
2026-06-18T02:45:10.9546136Z ------------------
2026-06-18T02:45:10.9546275Z 
2026-06-18T02:45:10.9546365Z ----- stderr -----
2026-06-18T02:45:10.9546620Z `trust_remote_code` is not supported anymore.
2026-06-18T02:45:10.9547214Z Please check that the Hugging Face dataset 'codeparrot/github-code' isn't based on a loading script and remove `trust_remote_code`.
2026-06-18T02:45:10.9548067Z If the dataset is based on a loading script, please ask the dataset author to remove it and convert it to a standard format like Parquet.
2026-06-18T02:45:10.9548618Z ------------------
2026-06-18T02:45:10.9548757Z 
2026-06-18T02:45:10.9549248Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T02:45:10.9549798Z �[0;31mRuntimeError�[0m                              Traceback (most recent call last)
2026-06-18T02:45:10.9550222Z Cell �[0;32mIn[43], line 2�[0m
2026-06-18T02:45:10.9550841Z �[1;32m      1�[0m �[38;5;66;03m# Unlike _some_ code-generator models on the market, we'll limit our training data by license :)�[39;00m
2026-06-18T02:45:10.9551520Z �[0;32m----> 2�[0m dataset �[38;5;241m=�[39m �[43mload_dataset�[49m�[43m(�[49m
2026-06-18T02:45:10.9552409Z �[1;32m      3�[0m �[43m    �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mcodeparrot/github-code�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m
2026-06-18T02:45:10.9553140Z �[1;32m      4�[0m �[43m    �[49m�[43mstreaming�[49m�[38;5;241;43m=�[39;49m�[38;5;28;43;01mTrue�[39;49;00m�[43m,�[49m
2026-06-18T02:45:10.9554109Z �[1;32m      5�[0m �[43m    �[49m�[43msplit�[49m�[38;5;241;43m=�[39;49m�[38;5;124;43m"�[39;49m�[38;5;124;43mtrain�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m
2026-06-18T02:45:10.9555053Z �[1;32m      6�[0m �[43m    �[49m�[43mlanguages�[49m�[38;5;241;43m=�[39;49m�[43m[�[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mJavaScript�[39;49m�[38;5;124;43m"�[39;49m�[43m]�[49m�[43m,�[49m
2026-06-18T02:45:10.9555688Z ============================== Failure ==============================
2026-06-18T02:45:10.9557729Z �[1;32m      7�[0m �[43m    �[49m�[43mlicenses�[49m�[38;5;241;43m=�[39;49m�[43m[�[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mmit�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m�[43m �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43misc�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m�[43m �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mapache-2.0�[39;49m�[38;5;124;43m"�[39;49m�[43m]�[49m�[43m,�[49m
2026-06-18T02:45:10.9559871Z �[1;32m      8�[0m �[43m    �[49m�[43mtrust_remote_code�[49m�[38;5;241;43m=�[39;49m�[38;5;28;43;01mTrue�[39;49;00m�[43m,�[49m
2026-06-18T02:45:10.9560679Z �[1;32m      9�[0m �[43m)�[49m
2026-06-18T02:45:10.9561430Z �[1;32m     10�[0m �[38;5;66;03m# Print the schema of the first example from the training set:�[39;00m
2026-06-18T02:45:10.9563076Z �[1;32m     11�[0m �[38;5;28mprint�[39m({k: �[38;5;28mtype�[39m(v) �[38;5;28;01mfor�[39;00m k, v �[38;5;129;01min�[39;00m �[38;5;28mnext�[39m(�[38;5;28miter�[39m(dataset))�[38;5;241m.�[39mitems()})
2026-06-18T02:45:10.9563916Z 
2026-06-18T02:45:10.9565250Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1698�[0m, in �[0;36mload_dataset�[0;34m(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, verification_mode, keep_in_memory, save_infos, revision, token, streaming, num_proc, storage_options, **config_kwargs)�[0m
2026-06-18T02:45:10.9566603Z �[1;32m   1693�[0m verification_mode �[38;5;241m=�[39m VerificationMode(
2026-06-18T02:45:10.9567834Z �[1;32m   1694�[0m     (verification_mode �[38;5;129;01mor�[39;00m VerificationMode�[38;5;241m.�[39mBASIC_CHECKS) �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m save_infos �[38;5;28;01melse�[39;00m VerificationMode�[38;5;241m.�[39mALL_CHECKS
2026-06-18T02:45:10.9568642Z �[1;32m   1695�[0m )
2026-06-18T02:45:10.9568996Z �[1;32m   1697�[0m �[38;5;66;03m# Create a dataset builder�[39;00m
2026-06-18T02:45:10.9569535Z �[0;32m-> 1698�[0m builder_instance �[38;5;241m=�[39m �[43mload_dataset_builder�[49m�[43m(�[49m
2026-06-18T02:45:10.9570122Z �[1;32m   1699�[0m �[43m    �[49m�[43mpath�[49m�[38;5;241;43m=�[39;49m�[43mpath�[49m�[43m,�[49m
2026-06-18T02:45:10.9570656Z �[1;32m   1700�[0m �[43m    �[49m�[43mname�[49m�[38;5;241;43m=�[39;49m�[43mname�[49m�[43m,�[49m
2026-06-18T02:45:10.9571216Z �[1;32m   1701�[0m �[43m    �[49m�[43mdata_dir�[49m�[38;5;241;43m=�[39;49m�[43mdata_dir�[49m�[43m,�[49m
2026-06-18T02:45:10.9572104Z �[1;32m   1702�[0m �[43m    �[49m�[43mdata_files�[49m�[38;5;241;43m=�[39;49m�[43mdata_files�[49m�[43m,�[49m
2026-06-18T02:45:10.9572742Z �[1;32m   1703�[0m �[43m    �[49m�[43mcache_dir�[49m�[38;5;241;43m=�[39;49m�[43mcache_dir�[49m�[43m,�[49m
2026-06-18T02:45:10.9573349Z �[1;32m   1704�[0m �[43m    �[49m�[43mfeatures�[49m�[38;5;241;43m=�[39;49m�[43mfeatures�[49m�[43m,�[49m
2026-06-18T02:45:10.9573993Z �[1;32m   1705�[0m �[43m    �[49m�[43mdownload_config�[49m�[38;5;241;43m=�[39;49m�[43mdownload_config�[49m�[43m,�[49m
2026-06-18T02:45:10.9574673Z �[1;32m   1706�[0m �[43m    �[49m�[43mdownload_mode�[49m�[38;5;241;43m=�[39;49m�[43mdownload_mode�[49m�[43m,�[49m
2026-06-18T02:45:10.9575309Z �[1;32m   1707�[0m �[43m    �[49m�[43mrevision�[49m�[38;5;241;43m=�[39;49m�[43mrevision�[49m�[43m,�[49m
2026-06-18T02:45:10.9575893Z �[1;32m   1708�[0m �[43m    �[49m�[43mtoken�[49m�[38;5;241;43m=�[39;49m�[43mtoken�[49m�[43m,�[49m
2026-06-18T02:45:10.9576526Z �[1;32m   1709�[0m �[43m    �[49m�[43mstorage_options�[49m�[38;5;241;43m=�[39;49m�[43mstorage_options�[49m�[43m,�[49m
2026-06-18T02:45:10.9577348Z �[1;32m   1710�[0m �[43m    �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mconfig_kwargs�[49m�[43m,�[49m
2026-06-18T02:45:10.9577804Z �[1;32m   1711�[0m �[43m�[49m�[43m)�[49m
2026-06-18T02:45:10.9578245Z �[1;32m   1713�[0m �[38;5;66;03m# Return iterable dataset in case of streaming�[39;00m
2026-06-18T02:45:10.9578693Z �[1;32m   1714�[0m �[38;5;28;01mif�[39;00m streaming:
2026-06-18T02:45:10.9578898Z 
2026-06-18T02:45:10.9579933Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1325�[0m, in �[0;36mload_dataset_builder�[0;34m(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, token, storage_options, **config_kwargs)�[0m
2026-06-18T02:45:10.9581220Z �[1;32m   1323�[0m �[38;5;28;01mif�[39;00m features �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T02:45:10.9582236Z �[1;32m   1324�[0m     features �[38;5;241m=�[39m _fix_for_backward_compatible_features(features)
2026-06-18T02:45:10.9582876Z �[0;32m-> 1325�[0m dataset_module �[38;5;241m=�[39m �[43mdataset_module_factory�[49m�[43m(�[49m
2026-06-18T02:45:10.9583376Z �[1;32m   1326�[0m �[43m    �[49m�[43mpath�[49m�[43m,�[49m
2026-06-18T02:45:10.9583901Z �[1;32m   1327�[0m �[43m    �[49m�[43mrevision�[49m�[38;5;241;43m=�[39;49m�[43mrevision�[49m�[43m,�[49m
2026-06-18T02:45:10.9584568Z �[1;32m   1328�[0m �[43m    �[49m�[43mdownload_config�[49m�[38;5;241;43m=�[39;49m�[43mdownload_config�[49m�[43m,�[49m
2026-06-18T02:45:10.9585245Z �[1;32m   1329�[0m �[43m    �[49m�[43mdownload_mode�[49m�[38;5;241;43m=�[39;49m�[43mdownload_mode�[49m�[43m,�[49m
2026-06-18T02:45:10.9585875Z �[1;32m   1330�[0m �[43m    �[49m�[43mdata_dir�[49m�[38;5;241;43m=�[39;49m�[43mdata_dir�[49m�[43m,�[49m
2026-06-18T02:45:10.9586478Z �[1;32m   1331�[0m �[43m    �[49m�[43mdata_files�[49m�[38;5;241;43m=�[39;49m�[43mdata_files�[49m�[43m,�[49m
2026-06-18T02:45:10.9587094Z �[1;32m   1332�[0m �[43m    �[49m�[43mcache_dir�[49m�[38;5;241;43m=�[39;49m�[43mcache_dir�[49m�[43m,�[49m
2026-06-18T02:45:10.9587545Z �[1;32m   1333�[0m �[43m�[49m�[43m)�[49m
2026-06-18T02:45:10.9588074Z �[1;32m   1334�[0m �[38;5;66;03m# Get dataset builder class�[39;00m
2026-06-18T02:45:10.9588608Z �[1;32m   1335�[0m builder_kwargs �[38;5;241m=�[39m dataset_module�[38;5;241m.�[39mbuilder_kwargs
2026-06-18T02:45:10.9588921Z 
2026-06-18T02:45:10.9589834Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1217�[0m, in �[0;36mdataset_module_factory�[0;34m(path, revision, download_config, download_mode, data_dir, data_files, cache_dir, **download_kwargs)�[0m
2026-06-18T02:45:10.9591031Z �[1;32m   1212�[0m             �[38;5;28;01mif�[39;00m �[38;5;28misinstance�[39m(e1, �[38;5;167;01mFileNotFoundError�[39;00m):
2026-06-18T02:45:10.9591866Z �[1;32m   1213�[0m                 �[38;5;28;01mraise�[39;00m �[38;5;167;01mFileNotFoundError�[39;00m(
2026-06-18T02:45:10.9592942Z �[1;32m   1214�[0m                     �[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find any data file at �[39m�[38;5;132;01m{�[39;00mrelative_to_absolute_path(path)�[38;5;132;01m}�[39;00m�[38;5;124m. �[39m�[38;5;124m"�[39m
2026-06-18T02:45:10.9594861Z �[1;32m   1215�[0m                     �[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find �[39m�[38;5;124m'�[39m�[38;5;132;01m{�[39;00mpath�[38;5;132;01m}�[39;00m�[38;5;124m'�[39m�[38;5;124m on the Hugging Face Hub either: �[39m�[38;5;132;01m{�[39;00m�[38;5;28mtype�[39m(e1)�[38;5;241m.�[39m�[38;5;18m__name__�[39m�[38;5;132;01m}�[39;00m�[38;5;124m: �[39m�[38;5;132;01m{�[39;00me1�[38;5;132;01m}�[39;00m�[38;5;124m"�[39m
2026-06-18T02:45:10.9596155Z �[1;32m   1216�[0m                 ) �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T02:45:10.9596797Z �[0;32m-> 1217�[0m             �[38;5;28;01mraise�[39;00m e1 �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T02:45:10.9597442Z �[1;32m   1218�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T02:45:10.9598583Z �[1;32m   1219�[0m     �[38;5;28;01mraise�[39;00m �[38;5;167;01mFileNotFoundError�[39;00m(�[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find any data file at �[39m�[38;5;132;01m{�[39;00mrelative_to_absolute_path(path)�[38;5;132;01m}�[39;00m�[38;5;124m.�[39m�[38;5;124m"�[39m)
2026-06-18T02:45:10.9599430Z 
2026-06-18T02:45:10.9600352Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1177�[0m, in �[0;36mdataset_module_factory�[0;34m(path, revision, download_config, download_mode, data_dir, data_files, cache_dir, **download_kwargs)�[0m
2026-06-18T02:45:10.9601307Z �[1;32m   1169�[0m �[38;5;28;01mtry�[39;00m:
2026-06-18T02:45:10.9601952Z �[1;32m   1170�[0m     api�[38;5;241m.�[39mhf_hub_download(
2026-06-18T02:45:10.9602364Z �[1;32m   1171�[0m         repo_id�[38;5;241m=�[39mpath,
2026-06-18T02:45:10.9602756Z �[1;32m   1172�[0m         filename�[38;5;241m=�[39mfilename,
2026-06-18T02:45:10.9603099Z �[0;32m   (...)�[0m
2026-06-18T02:45:10.9603496Z �[1;32m   1175�[0m         proxies�[38;5;241m=�[39mdownload_config�[38;5;241m.�[39mproxies,
2026-06-18T02:45:10.9603911Z �[1;32m   1176�[0m     )
2026-06-18T02:45:10.9604831Z �[0;32m-> 1177�[0m     �[38;5;28;01mraise�[39;00m �[38;5;167;01mRuntimeError�[39;00m(�[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mDataset scripts are no longer supported, but found �[39m�[38;5;132;01m{�[39;00mfilename�[38;5;132;01m}�[39;00m�[38;5;124m"�[39m)
2026-06-18T02:45:10.9605720Z �[1;32m   1178�[0m �[38;5;28;01mexcept�[39;00m EntryNotFoundError:
2026-06-18T02:45:10.9606283Z �[1;32m   1179�[0m     �[38;5;66;03m# Use the infos from the parquet export except in some cases:�[39;00m
2026-06-18T02:45:10.9607312Z �[1;32m   1180�[0m     �[38;5;28;01mif�[39;00m data_dir �[38;5;129;01mor�[39;00m data_files �[38;5;129;01mor�[39;00m (revision �[38;5;129;01mand�[39;00m revision �[38;5;241m!=�[39m �[38;5;124m"�[39m�[38;5;124mmain�[39m�[38;5;124m"�[39m):
2026-06-18T02:45:10.9607936Z 
2026-06-18T02:45:10.9608397Z �[0;31mRuntimeError�[0m: Dataset scripts are no longer supported, but found github-code.py
2026-06-18T02:45:10.9608739Z 
2026-06-18T02:45:11.1515085Z ##[error]Process completed with exit code 1.

tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb

2026-06-18T02:44:20.6404607Z Executing tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb
2026-06-18T02:44:21.5838267Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T02:45:27.2683441Z tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb failed quality control.
2026-06-18T02:45:27.2684018Z An error occurred while executing the following cell:
2026-06-18T02:45:27.2684350Z ------------------
2026-06-18T02:45:27.2685246Z # @title Bonus 1.4: Sentiment binary-classification with likelihood of positive and negative extensions of the review 👍👎
2026-06-18T02:45:27.2685733Z 
2026-06-18T02:45:27.2685835Z # @markdown ---
2026-06-18T02:45:27.2686166Z model_name = "gpt2"  # @param ["gpt2", "gpt2-medium", "xlnet-base-cased"]
2026-06-18T02:45:27.2687132Z model = AutoModelForCausalLM.from_pretrained(model_name)
2026-06-18T02:45:27.2687474Z model.eval()
2026-06-18T02:45:27.2688071Z tokenizer = AutoTokenizer.from_pretrained(model_name)
2026-06-18T02:45:27.2688832Z # @markdown **Select a pre-trained language model to score the likelihood of extended review**
2026-06-18T02:45:27.2689374Z 
2026-06-18T02:45:27.2689631Z # @markdown *(might take some time to download the pre-trained weights for the first time)*
2026-06-18T02:45:27.2690046Z 
2026-06-18T02:45:27.2690178Z # @markdown ---
2026-06-18T02:45:27.2690755Z custom_positive_extension = "I would definitely recommend this!"  # @param {type:"string"}
2026-06-18T02:45:27.2691666Z custom_negative_extension = "I would not recommend this!"  # @param {type:"string"}
2026-06-18T02:45:27.2692694Z # @markdown **Provide custom positive and negative extensions to the review ✍️**
2026-06-18T02:45:27.2693219Z 
2026-06-18T02:45:27.2693534Z texts = [context, custom_positive_extension, custom_negative_extension]
2026-06-18T02:45:27.2694141Z encodings = tokenizer(texts)
2026-06-18T02:45:27.2694417Z 
2026-06-18T02:45:27.2694823Z positive_input_ids = torch.tensor(encodings["input_ids"][0] + encodings["input_ids"][1])
2026-06-18T02:45:27.2695457Z positive_attention_mask = torch.tensor(encodings["attention_mask"][0] + encodings["attention_mask"][1])
2026-06-18T02:45:27.2696124Z positive_label_ids = torch.tensor([-100]*len(encodings["input_ids"][0]) + encodings["input_ids"][1])
2026-06-18T02:45:27.2696600Z outputs = model(input_ids=positive_input_ids,
2026-06-18T02:45:27.2696942Z                 attention_mask=positive_attention_mask,
2026-06-18T02:45:27.2697262Z                 labels=positive_label_ids)
2026-06-18T02:45:27.2697792Z positive_extension_likelihood = -1*outputs.loss
2026-06-18T02:45:27.2698283Z print("\nLog-likelihood of positive extension = ", positive_extension_likelihood.item())
2026-06-18T02:45:27.2698858Z 
2026-06-18T02:45:27.2699104Z negative_input_ids = torch.tensor(encodings["input_ids"][0] + encodings["input_ids"][2])
2026-06-18T02:45:27.2699721Z negative_attention_mask = torch.tensor(encodings["attention_mask"][0] + encodings["attention_mask"][2])
2026-06-18T02:45:27.2700366Z negative_label_ids = torch.tensor([-100]*len(encodings["input_ids"][0]) + encodings["input_ids"][2])
2026-06-18T02:45:27.2700850Z outputs = model(input_ids=negative_input_ids,
2026-06-18T02:45:27.2701182Z                 attention_mask=negative_attention_mask,
2026-06-18T02:45:27.2701494Z                 labels=negative_label_ids)
2026-06-18T02:45:27.2701806Z negative_extension_likelihood = -1*outputs.loss
2026-06-18T02:45:27.2702257Z print("\nLog-likelihood of negative extension = ", negative_extension_likelihood.item())
2026-06-18T02:45:27.2702584Z 
2026-06-18T02:45:27.2702820Z if (positive_extension_likelihood.item() > negative_extension_likelihood.item()):
2026-06-18T02:45:27.2703350Z     print("\nPositive text-extension has greater likelihood probabilities!")
2026-06-18T02:45:27.2703792Z ============================== Failure ==============================
2026-06-18T02:45:27.2704295Z     print("The given review can be predicted to be POSITIVE 👍")
2026-06-18T02:45:27.2704629Z else:
2026-06-18T02:45:27.2704951Z     print("\nNegative text-extension has greater likelihood probabilities!")
2026-06-18T02:45:27.2705457Z     print("The given review can be predicted to be NEGATIVE 👎")
2026-06-18T02:45:27.2705907Z # @markdown **NOTE:** *Run this cell after setting all the fields appropriately!*
2026-06-18T02:45:27.2706195Z 
2026-06-18T02:45:27.2706419Z # @markdown **NOTE:** *Some pre-trained models might not work well with longer texts!*
2026-06-18T02:45:27.2706815Z ------------------
2026-06-18T02:45:27.2706948Z 
2026-06-18T02:45:27.2706953Z 
2026-06-18T02:45:27.2707214Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T02:45:27.2707928Z �[0;31mIndexError�[0m                                Traceback (most recent call last)
2026-06-18T02:45:27.2708361Z Cell �[0;32mIn[17], line 23�[0m
2026-06-18T02:45:27.2709731Z �[1;32m     21�[0m positive_attention_mask �[38;5;241m=�[39m torch�[38;5;241m.�[39mtensor(encodings[�[38;5;124m"�[39m�[38;5;124mattention_mask�[39m�[38;5;124m"�[39m][�[38;5;241m0�[39m] �[38;5;241m+�[39m encodings[�[38;5;124m"�[39m�[38;5;124mattention_mask�[39m�[38;5;124m"�[39m][�[38;5;241m1�[39m])
2026-06-18T02:45:27.2711658Z �[1;32m     22�[0m positive_label_ids �[38;5;241m=�[39m torch�[38;5;241m.�[39mtensor([�[38;5;241m-�[39m�[38;5;241m100�[39m]�[38;5;241m*�[39m�[38;5;28mlen�[39m(encodings[�[38;5;124m"�[39m�[38;5;124minput_ids�[39m�[38;5;124m"�[39m][�[38;5;241m0�[39m]) �[38;5;241m+�[39m encodings[�[38;5;124m"�[39m�[38;5;124minput_ids�[39m�[38;5;124m"�[39m][�[38;5;241m1�[39m])
2026-06-18T02:45:27.2713030Z �[0;32m---> 23�[0m outputs �[38;5;241m=�[39m �[43mmodel�[49m�[43m(�[49m�[43minput_ids�[49m�[38;5;241;43m=�[39;49m�[43mpositive_input_ids�[49m�[43m,�[49m
2026-06-18T02:45:27.2713881Z �[1;32m     24�[0m �[43m                �[49m�[43mattention_mask�[49m�[38;5;241;43m=�[39;49m�[43mpositive_attention_mask�[49m�[43m,�[49m
2026-06-18T02:45:27.2714610Z �[1;32m     25�[0m �[43m                �[49m�[43mlabels�[49m�[38;5;241;43m=�[39;49m�[43mpositive_label_ids�[49m�[43m)�[49m
2026-06-18T02:45:27.2715395Z �[1;32m     26�[0m positive_extension_likelihood �[38;5;241m=�[39m �[38;5;241m-�[39m�[38;5;241m1�[39m�[38;5;241m*�[39moutputs�[38;5;241m.�[39mloss
2026-06-18T02:45:27.2716471Z �[1;32m     27�[0m �[38;5;28mprint�[39m(�[38;5;124m"�[39m�[38;5;130;01m\n�[39;00m�[38;5;124mLog-likelihood of positive extension = �[39m�[38;5;124m"�[39m, positive_extension_likelihood�[38;5;241m.�[39mitem())
2026-06-18T02:45:27.2717051Z 
2026-06-18T02:45:27.2717985Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/nn/modules/module.py:1778�[0m, in �[0;36mModule._wrapped_call_impl�[0;34m(self, *args, **kwargs)�[0m
2026-06-18T02:45:27.2719424Z �[1;32m   1776�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_compiled_call_impl(�[38;5;241m*�[39margs, �[38;5;241m*�[39m�[38;5;241m*�[39mkwargs)  �[38;5;66;03m# type: ignore[misc]�[39;00m
2026-06-18T02:45:27.2720153Z �[1;32m   1777�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T02:45:27.2721122Z �[0;32m-> 1778�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43m_call_impl�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m,�[49m�[43m �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mkwargs�[49m�[43m)�[49m
2026-06-18T02:45:27.2721780Z 
2026-06-18T02:45:27.2722432Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/nn/modules/module.py:1789�[0m, in �[0;36mModule._call_impl�[0;34m(self, *args, **kwargs)�[0m
2026-06-18T02:45:27.2723378Z �[1;32m   1784�[0m �[38;5;66;03m# If we don't have any hooks, we want to skip the rest of the logic in�[39;00m
2026-06-18T02:45:27.2723961Z �[1;32m   1785�[0m �[38;5;66;03m# this function, and just call forward.�[39;00m
2026-06-18T02:45:27.2725314Z �[1;32m   1786�[0m �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m (�[38;5;28mself�[39m�[38;5;241m.�[39m_backward_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_backward_pre_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_forward_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_forward_pre_hooks
2026-06-18T02:45:27.2726581Z �[1;32m   1787�[0m         �[38;5;129;01mor�[39;00m _global_backward_pre_hooks �[38;5;129;01mor�[39;00m _global_backward_hooks
2026-06-18T02:45:27.2727326Z �[1;32m   1788�[0m         �[38;5;129;01mor�[39;00m _global_forward_hooks �[38;5;129;01mor�[39;00m _global_forward_pre_hooks):
2026-06-18T02:45:27.2728516Z �[0;32m-> 1789�[0m     �[38;5;28;01mreturn�[39;00m �[43mforward_call�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m,�[49m�[43m �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mkwargs�[49m�[43m)�[49m
2026-06-18T02:45:27.2729303Z �[1;32m   1791�[0m result �[38;5;241m=�[39m �[38;5;28;01mNone�[39;00m
2026-06-18T02:45:27.2729807Z �[1;32m   1792�[0m called_always_called_hooks �[38;5;241m=�[39m �[38;5;28mset�[39m()
2026-06-18T02:45:27.2730255Z 
2026-06-18T02:45:27.2731930Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/transformers/models/gpt2/modeling_gpt2.py:1092�[0m, in �[0;36mGPT2LMHeadModel.forward�[0;34m(self, input_ids, past_key_values, cache_position, attention_mask, token_type_ids, position_ids, head_mask, inputs_embeds, encoder_hidden_states, encoder_attention_mask, labels, use_cache, output_attentions, output_hidden_states, return_dict, logits_to_keep, **kwargs)�[0m
2026-06-18T02:45:27.2733906Z �[1;32m   1089�[0m     hidden_states �[38;5;241m=�[39m hidden_states�[38;5;241m.�[39mto(�[38;5;28mself�[39m�[38;5;241m.�[39mlm_head�[38;5;241m.�[39mweight�[38;5;241m.�[39mdevice)
2026-06-18T02:45:27.2735238Z �[1;32m   1091�[0m slice_indices �[38;5;241m=�[39m �[38;5;28mslice�[39m(�[38;5;241m-�[39mlogits_to_keep, �[38;5;28;01mNone�[39;00m) �[38;5;28;01mif�[39;00m �[38;5;28misinstance�[39m(logits_to_keep, �[38;5;28mint�[39m) �[38;5;28;01melse�[39;00m logits_to_keep
2026-06-18T02:45:27.2736635Z �[0;32m-> 1092�[0m logits �[38;5;241m=�[39m �[38;5;28mself�[39m�[38;5;241m.�[39mlm_head(�[43mhidden_states�[49m�[43m[�[49m�[43m:�[49m�[43m,�[49m�[43m �[49m�[43mslice_indices�[49m�[43m,�[49m�[43m �[49m�[43m:�[49m�[43m]�[49m)
2026-06-18T02:45:27.2737450Z �[1;32m   1094�[0m loss �[38;5;241m=�[39m �[38;5;28;01mNone�[39;00m
2026-06-18T02:45:27.2738262Z �[1;32m   1095�[0m �[38;5;28;01mif�[39;00m labels �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T02:45:27.2738828Z �[1;32m   1096�[0m     �[38;5;66;03m# Flatten the tokens�[39;00m
2026-06-18T02:45:27.2739063Z 
2026-06-18T02:45:27.2739293Z �[0;31mIndexError�[0m: too many indices for tensor of dimension 2
2026-06-18T02:45:27.2739549Z 
2026-06-18T02:45:27.5313034Z ##[error]Process completed with exit code 1.

@github-actions

Copy link
Copy Markdown

Notebook Processing Failure Context

tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb

2026-06-18T05:12:19.6273212Z Executing tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb
2026-06-18T05:12:20.4506664Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T05:12:29.7255642Z tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb failed quality control.
2026-06-18T05:12:29.7256290Z An error occurred while executing the following cell:
2026-06-18T05:12:29.7256655Z ------------------
2026-06-18T05:12:29.7256957Z # Visualize the output of your function
2026-06-18T05:12:29.7257335Z from IPython.display import display as IPydisplay
2026-06-18T05:12:29.7257593Z 
2026-06-18T05:12:29.7257843Z with open("images/chicago_skyline_shrunk_v2.bmp", 'rb') as skyline_image_file:
2026-06-18T05:12:29.7258350Z   img_skyline_orig = Image.open(skyline_image_file)
2026-06-18T05:12:29.7258735Z   img_skyline_mat = np.asarray(img_skyline_orig)
2026-06-18T05:12:29.7259794Z   kernel_ver = np.array([[-1, 0, 1], [-2, 0, 2], [-1, 0, 1]])
2026-06-18T05:12:29.7260250Z   kernel_hor = np.array([[-1, 0, 1], [-2, 0, 2], [-1, 0, 1]]).T
2026-06-18T05:12:29.7260727Z   img_processed_mat_ver = convolution2d(img_skyline_mat, kernel_ver)
2026-06-18T05:12:29.7261235Z   img_processed_mat_hor = convolution2d(img_skyline_mat, kernel_hor)
2026-06-18T05:12:29.7261731Z   img_processed_mat = np.sqrt(np.multiply(img_processed_mat_ver,
2026-06-18T05:12:29.7262162Z                                           img_processed_mat_ver) + \
2026-06-18T05:12:29.7262564Z                               np.multiply(img_processed_mat_hor,
2026-06-18T05:12:29.7262941Z                                           img_processed_mat_hor))
2026-06-18T05:12:29.7263184Z 
2026-06-18T05:12:29.7263333Z   img_processed_mat *= 255.0/img_processed_mat.max()
2026-06-18T05:12:29.7263753Z   img_processed_mat = img_processed_mat.astype(np.uint8)
2026-06-18T05:12:29.7264184Z   img_processed = Image.fromarray(img_processed_mat, 'L')
2026-06-18T05:12:29.7264711Z   width, height = img_skyline_orig.size
2026-06-18T05:12:29.7265011Z   scale = 0.6
2026-06-18T05:12:29.7265386Z   IPydisplay(img_skyline_orig.resize((int(width*scale), int(height*scale))),
2026-06-18T05:12:29.7265834Z              Image.NEAREST)
2026-06-18T05:12:29.7266234Z   IPydisplay(img_processed.resize((int(width*scale), int(height*scale))),
2026-06-18T05:12:29.7266669Z              Image.NEAREST)
2026-06-18T05:12:29.7266902Z ------------------
2026-06-18T05:12:29.7267035Z 
2026-06-18T05:12:29.7267040Z 
2026-06-18T05:12:29.7267474Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T05:12:29.7268072Z �[0;31mUnidentifiedImageError�[0m                    Traceback (most recent call last)
2026-06-18T05:12:29.7268577Z Cell �[0;32mIn[30], line 5�[0m
2026-06-18T05:12:29.7269862Z �[1;32m      2�[0m �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;21;01mIPython�[39;00m�[38;5;21;01m.�[39;00m�[38;5;21;01mdisplay�[39;00m�[38;5;250m �[39m�[38;5;28;01mimport�[39;00m display �[38;5;28;01mas�[39;00m IPydisplay
2026-06-18T05:12:29.7271329Z �[1;32m      4�[0m �[38;5;28;01mwith�[39;00m �[38;5;28mopen�[39m(�[38;5;124m"�[39m�[38;5;124mimages/chicago_skyline_shrunk_v2.bmp�[39m�[38;5;124m"�[39m, �[38;5;124m'�[39m�[38;5;124mrb�[39m�[38;5;124m'�[39m) �[38;5;28;01mas�[39;00m skyline_image_file:
2026-06-18T05:12:29.7272546Z �[0;32m----> 5�[0m   img_skyline_orig �[38;5;241m=�[39m �[43mImage�[49m�[38;5;241;43m.�[39;49m�[43mopen�[49m�[43m(�[49m�[43mskyline_image_file�[49m�[43m)�[49m
2026-06-18T05:12:29.7273337Z �[1;32m      6�[0m   img_skyline_mat �[38;5;241m=�[39m np�[38;5;241m.�[39masarray(img_skyline_orig)
2026-06-18T05:12:29.7274533Z �[1;32m      7�[0m   kernel_ver �[38;5;241m=�[39m np�[38;5;241m.�[39marray([[�[38;5;241m-�[39m�[38;5;241m1�[39m, �[38;5;241m0�[39m, �[38;5;241m1�[39m], [�[38;5;241m-�[39m�[38;5;241m2�[39m, �[38;5;241m0�[39m, �[38;5;241m2�[39m], [�[38;5;241m-�[39m�[38;5;241m1�[39m, �[38;5;241m0�[39m, �[38;5;241m1�[39m]])
2026-06-18T05:12:29.7275306Z 
2026-06-18T05:12:29.7275879Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/PIL/Image.py:3711�[0m, in �[0;36mopen�[0;34m(fp, mode, formats)�[0m
2026-06-18T05:12:29.7276614Z �[1;32m   3709�[0m     warnings�[38;5;241m.�[39mwarn(message)
2026-06-18T05:12:29.7277573Z �[1;32m   3710�[0m msg �[38;5;241m=�[39m �[38;5;124m"�[39m�[38;5;124mcannot identify image file �[39m�[38;5;132;01m%r�[39;00m�[38;5;124m"�[39m �[38;5;241m%�[39m (filename �[38;5;28;01mif�[39;00m filename �[38;5;28;01melse�[39;00m fp)
2026-06-18T05:12:29.7278454Z �[0;32m-> 3711�[0m �[38;5;28;01mraise�[39;00m UnidentifiedImageError(msg)
2026-06-18T05:12:29.7278724Z 
2026-06-18T05:12:29.7279473Z �[0;31mUnidentifiedImageError�[0m: cannot identify image file <_io.BufferedReader name='images/chicago_skyline_shrunk_v2.bmp'>
2026-06-18T05:12:29.7279972Z 
2026-06-18T05:12:29.7280115Z ============================== Failure ==============================
2026-06-18T05:12:29.8940331Z ##[error]Process completed with exit code 1.

tutorials/W2D2_Convnets/W2D2_Tutorial3.ipynb

2026-06-18T05:13:46.9620990Z 
2026-06-18T05:13:46.9621148Z  91%|█████████▏| 213M/233M [00:04<00:00, 54.6MB/s]
2026-06-18T05:13:46.9621437Z ----- stderr -----
2026-06-18T05:13:46.9621557Z 
2026-06-18T05:13:46.9621713Z  94%|█████████▎| 218M/233M [00:04<00:00, 54.6MB/s]
2026-06-18T05:13:46.9621989Z ----- stderr -----
2026-06-18T05:13:46.9622391Z 
2026-06-18T05:13:46.9622572Z  96%|█████████▌| 224M/233M [00:04<00:00, 54.4MB/s]
2026-06-18T05:13:46.9622849Z ----- stderr -----
2026-06-18T05:13:46.9622977Z 
2026-06-18T05:13:46.9623128Z  98%|█████████▊| 229M/233M [00:04<00:00, 54.2MB/s]
2026-06-18T05:13:46.9623402Z ----- stderr -----
2026-06-18T05:13:46.9623526Z 
2026-06-18T05:13:46.9623680Z 100%|██████████| 233M/233M [00:05<00:00, 48.2MB/s]
2026-06-18T05:13:46.9624227Z ----- stderr -----
2026-06-18T05:13:46.9624358Z 
2026-06-18T05:13:46.9624438Z ------------------
2026-06-18T05:13:46.9624561Z 
2026-06-18T05:13:46.9624827Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T05:13:46.9625396Z �[0;31mAttributeError�[0m                            Traceback (most recent call last)
2026-06-18T05:13:46.9625847Z Cell �[0;32mIn[15], line 12�[0m
2026-06-18T05:13:46.9627014Z �[1;32m     11�[0m url, filename �[38;5;241m=�[39m (�[38;5;124m"�[39m�[38;5;124mhttps://raw.githubusercontent.com/NeuromatchAcademy/course-content-dl/main/tutorials/W2D2_Convnets/static/dog.jpg�[39m�[38;5;124m"�[39m, �[38;5;124m"�[39m�[38;5;124mdog.jpg�[39m�[38;5;124m"�[39m)
2026-06-18T05:13:46.9628318Z �[0;32m---> 12�[0m �[38;5;28;01mtry�[39;00m: urllib�[38;5;241m.�[39mURLopener()�[38;5;241m.�[39mretrieve(url, filename)
2026-06-18T05:13:46.9629079Z �[1;32m     13�[0m �[38;5;28;01mexcept�[39;00m: urllib�[38;5;241m.�[39mrequest�[38;5;241m.�[39murlretrieve(url, filename)
2026-06-18T05:13:46.9629480Z 
2026-06-18T05:13:46.9629739Z �[0;31mAttributeError�[0m: module 'urllib' has no attribute 'URLopener'
2026-06-18T05:13:46.9630036Z 
2026-06-18T05:13:46.9630229Z During handling of the above exception, another exception occurred:
2026-06-18T05:13:46.9630513Z 
2026-06-18T05:13:46.9630756Z �[0;31mHTTPError�[0m                                 Traceback (most recent call last)
2026-06-18T05:13:46.9631183Z Cell �[0;32mIn[15], line 13�[0m
2026-06-18T05:13:46.9632551Z �[1;32m     11�[0m url, filename �[38;5;241m=�[39m (�[38;5;124m"�[39m�[38;5;124mhttps://raw.githubusercontent.com/NeuromatchAcademy/course-content-dl/main/tutorials/W2D2_Convnets/static/dog.jpg�[39m�[38;5;124m"�[39m, �[38;5;124m"�[39m�[38;5;124mdog.jpg�[39m�[38;5;124m"�[39m)
2026-06-18T05:13:46.9633813Z �[1;32m     12�[0m �[38;5;28;01mtry�[39;00m: urllib�[38;5;241m.�[39mURLopener()�[38;5;241m.�[39mretrieve(url, filename)
2026-06-18T05:13:46.9634564Z �[0;32m---> 13�[0m �[38;5;28;01mexcept�[39;00m: urllib�[38;5;241m.�[39mrequest�[38;5;241m.�[39murlretrieve(url, filename)
2026-06-18T05:13:46.9635219Z �[1;32m     15�[0m input_image �[38;5;241m=�[39m Image�[38;5;241m.�[39mopen(filename)
2026-06-18T05:13:46.9635775Z �[1;32m     16�[0m preprocess �[38;5;241m=�[39m transforms�[38;5;241m.�[39mCompose([
2026-06-18T05:13:46.9636482Z �[1;32m     17�[0m                                  transforms�[38;5;241m.�[39mResize(�[38;5;241m256�[39m),
2026-06-18T05:13:46.9637105Z �[1;32m     18�[0m                                  transforms�[38;5;241m.�[39mCenterCrop(�[38;5;241m224�[39m),
2026-06-18T05:13:46.9637532Z �[0;32m   (...)�[0m
2026-06-18T05:13:46.9638072Z �[1;32m     21�[0m                                                       std�[38;5;241m=�[39m[�[38;5;241m0.229�[39m, �[38;5;241m0.224�[39m, �[38;5;241m0.225�[39m]),
2026-06-18T05:13:46.9638636Z �[1;32m     22�[0m                                  ])
2026-06-18T05:13:46.9638845Z 
2026-06-18T05:13:46.9639429Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:241�[0m, in �[0;36murlretrieve�[0;34m(url, filename, reporthook, data)�[0m
2026-06-18T05:13:46.9640192Z �[1;32m    224�[0m �[38;5;250m�[39m�[38;5;124;03m"""�[39;00m
2026-06-18T05:13:46.9640707Z �[1;32m    225�[0m �[38;5;124;03mRetrieve a URL into a temporary location on disk.�[39;00m
2026-06-18T05:13:46.9641132Z �[1;32m    226�[0m 
2026-06-18T05:13:46.9641365Z �[0;32m   (...)�[0m
2026-06-18T05:13:46.9641787Z �[1;32m    237�[0m �[38;5;124;03mdata file as well as the resulting HTTPMessage object.�[39;00m
2026-06-18T05:13:46.9642519Z �[1;32m    238�[0m �[38;5;124;03m"""�[39;00m
2026-06-18T05:13:46.9642945Z �[1;32m    239�[0m url_type, path �[38;5;241m=�[39m _splittype(url)
2026-06-18T05:13:46.9643863Z �[0;32m--> 241�[0m �[38;5;28;01mwith�[39;00m contextlib�[38;5;241m.�[39mclosing(�[43murlopen�[49m�[43m(�[49m�[43murl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m)�[49m) �[38;5;28;01mas�[39;00m fp:
2026-06-18T05:13:46.9644705Z �[1;32m    242�[0m     headers �[38;5;241m=�[39m fp�[38;5;241m.�[39minfo()
2026-06-18T05:13:46.9645437Z �[1;32m    244�[0m     �[38;5;66;03m# Just return the local path and the "headers" for file://�[39;00m
2026-06-18T05:13:46.9646086Z �[1;32m    245�[0m     �[38;5;66;03m# URLs. No sense in performing a copy unless requested.�[39;00m
2026-06-18T05:13:46.9646423Z 
2026-06-18T05:13:46.9647091Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:216�[0m, in �[0;36murlopen�[0;34m(url, data, timeout, cafile, capath, cadefault, context)�[0m
2026-06-18T05:13:46.9647860Z �[1;32m    214�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T05:13:46.9648229Z �[1;32m    215�[0m     opener �[38;5;241m=�[39m _opener
2026-06-18T05:13:46.9649108Z �[0;32m--> 216�[0m �[38;5;28;01mreturn�[39;00m �[43mopener�[49m�[38;5;241;43m.�[39;49m�[43mopen�[49m�[43m(�[49m�[43murl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m,�[49m�[43m �[49m�[43mtimeout�[49m�[43m)�[49m
2026-06-18T05:13:46.9649726Z 
2026-06-18T05:13:46.9650363Z File �[0;32m~/.ipython/profile_default/startup/00-stub-widgets.py:154�[0m, in �[0;36m_install_resilient_opener.<locals>._open_with_retry�[0;34m(fullurl, data, timeout)�[0m
2026-06-18T05:13:46.9651441Z �[1;32m    152�[0m �[38;5;28;01mfor�[39;00m attempt �[38;5;129;01min�[39;00m �[38;5;28mrange�[39m(_MAX_RETRIES �[38;5;241m+�[39m �[38;5;241m1�[39m):
2026-06-18T05:13:46.9652281Z �[1;32m    153�[0m     �[38;5;28;01mtry�[39;00m:
2026-06-18T05:13:46.9653116Z �[0;32m--> 154�[0m         �[38;5;28;01mreturn�[39;00m �[43m_inner_open�[49m�[43m(�[49m�[43mfullurl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m,�[49m�[43m �[49m�[43mtimeout�[49m�[43m)�[49m
2026-06-18T05:13:46.9654104Z �[1;32m    155�[0m     �[38;5;28;01mexcept�[39;00m urllib�[38;5;241m.�[39merror�[38;5;241m.�[39mHTTPError �[38;5;28;01mas�[39;00m e:
2026-06-18T05:13:46.9655168Z �[1;32m    156�[0m         �[38;5;28;01mif�[39;00m e�[38;5;241m.�[39mcode �[38;5;129;01mnot�[39;00m �[38;5;129;01min�[39;00m _RETRY_STATUSES �[38;5;129;01mor�[39;00m attempt �[38;5;241m==�[39m _MAX_RETRIES:
2026-06-18T05:13:46.9655771Z 
2026-06-18T05:13:46.9656382Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:525�[0m, in �[0;36mOpenerDirector.open�[0;34m(self, fullurl, data, timeout)�[0m
2026-06-18T05:13:46.9657503Z �[1;32m    523�[0m �[38;5;28;01mfor�[39;00m processor �[38;5;129;01min�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39mprocess_response�[38;5;241m.�[39mget(protocol, []):
2026-06-18T05:13:46.9658409Z �[1;32m    524�[0m     meth �[38;5;241m=�[39m �[38;5;28mgetattr�[39m(processor, meth_name)
2026-06-18T05:13:46.9659164Z �[0;32m--> 525�[0m     response �[38;5;241m=�[39m �[43mmeth�[49m�[43m(�[49m�[43mreq�[49m�[43m,�[49m�[43m �[49m�[43mresponse�[49m�[43m)�[49m
2026-06-18T05:13:46.9659773Z �[1;32m    527�[0m �[38;5;28;01mreturn�[39;00m response
2026-06-18T05:13:46.9659992Z 
2026-06-18T05:13:46.9660630Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:634�[0m, in �[0;36mHTTPErrorProcessor.http_response�[0;34m(self, request, response)�[0m
2026-06-18T05:13:46.9661584Z �[1;32m    631�[0m �[38;5;66;03m# According to RFC 2616, "2xx" code indicates that the client's�[39;00m
2026-06-18T05:13:46.9662648Z �[1;32m    632�[0m �[38;5;66;03m# request was successfully received, understood, and accepted.�[39;00m
2026-06-18T05:13:46.9663556Z �[1;32m    633�[0m �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m (�[38;5;241m200�[39m �[38;5;241m<�[39m�[38;5;241m=�[39m code �[38;5;241m<�[39m �[38;5;241m300�[39m):
2026-06-18T05:13:46.9664564Z �[0;32m--> 634�[0m     response �[38;5;241m=�[39m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43mparent�[49m�[38;5;241;43m.�[39;49m�[43merror�[49m�[43m(�[49m
2026-06-18T05:13:46.9665979Z �[1;32m    635�[0m �[43m        �[49m�[38;5;124;43m'�[39;49m�[38;5;124;43mhttp�[39;49m�[38;5;124;43m'�[39;49m�[43m,�[49m�[43m �[49m�[43mrequest�[49m�[43m,�[49m�[43m �[49m�[43mresponse�[49m�[43m,�[49m�[43m �[49m�[43mcode�[49m�[43m,�[49m�[43m �[49m�[43mmsg�[49m�[43m,�[49m�[43m �[49m�[43mhdrs�[49m�[43m)�[49m
2026-06-18T05:13:46.9667143Z �[1;32m    637�[0m �[38;5;28;01mreturn�[39;00m response
2026-06-18T05:13:46.9667380Z 
2026-06-18T05:13:46.9667965Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:563�[0m, in �[0;36mOpenerDirector.error�[0;34m(self, proto, *args)�[0m
2026-06-18T05:13:46.9668693Z �[1;32m    561�[0m �[38;5;28;01mif�[39;00m http_err:
2026-06-18T05:13:46.9669604Z �[1;32m    562�[0m     args �[38;5;241m=�[39m (�[38;5;28mdict�[39m, �[38;5;124m'�[39m�[38;5;124mdefault�[39m�[38;5;124m'�[39m, �[38;5;124m'�[39m�[38;5;124mhttp_error_default�[39m�[38;5;124m'�[39m) �[38;5;241m+�[39m orig_args
2026-06-18T05:13:46.9670815Z �[0;32m--> 563�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43m_call_chain�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m)�[49m
2026-06-18T05:13:46.9671342Z 
2026-06-18T05:13:46.9672221Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:496�[0m, in �[0;36mOpenerDirector._call_chain�[0;34m(self, chain, kind, meth_name, *args)�[0m
2026-06-18T05:13:46.9673188Z �[1;32m    494�[0m �[38;5;28;01mfor�[39;00m handler �[38;5;129;01min�[39;00m handlers:
2026-06-18T05:13:46.9673740Z �[1;32m    495�[0m     func �[38;5;241m=�[39m �[38;5;28mgetattr�[39m(handler, meth_name)
2026-06-18T05:13:46.9674392Z �[0;32m--> 496�[0m     result �[38;5;241m=�[39m �[43mfunc�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m)�[49m
2026-06-18T05:13:46.9675175Z �[1;32m    497�[0m     �[38;5;28;01mif�[39;00m result �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T05:13:46.9675760Z �[1;32m    498�[0m         �[38;5;28;01mreturn�[39;00m result
2026-06-18T05:13:46.9675994Z 
2026-06-18T05:13:46.9676708Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:643�[0m, in �[0;36mHTTPDefaultErrorHandler.http_error_default�[0;34m(self, req, fp, code, msg, hdrs)�[0m
2026-06-18T05:13:46.9677839Z �[1;32m    642�[0m �[38;5;28;01mdef�[39;00m�[38;5;250m �[39m�[38;5;21mhttp_error_default�[39m(�[38;5;28mself�[39m, req, fp, code, msg, hdrs):
2026-06-18T05:13:46.9678630Z �[0;32m--> 643�[0m     �[38;5;28;01mraise�[39;00m HTTPError(req�[38;5;241m.�[39mfull_url, code, msg, hdrs, fp)
2026-06-18T05:13:46.9678999Z 
2026-06-18T05:13:46.9679165Z �[0;31mHTTPError�[0m: HTTP Error 404: Not Found
2026-06-18T05:13:46.9679382Z 
2026-06-18T05:13:47.1210117Z ##[error]Process completed with exit code 1.

tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb

2026-06-18T05:11:53.5955858Z Executing tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb
2026-06-18T05:11:54.6160390Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T05:12:10.6243159Z tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb failed quality control.
2026-06-18T05:12:10.6243849Z An error occurred while executing the following cell:
2026-06-18T05:12:10.6244182Z ------------------
2026-06-18T05:12:10.6244593Z # @markdown Download BigGAN (a generative model) and a few standard image datasets
2026-06-18T05:12:10.6244950Z 
2026-06-18T05:12:10.6245064Z ## Initially was downloaded directly
2026-06-18T05:12:10.6246275Z # biggan_model = BigGAN.from_pretrained('biggan-deep-256')
2026-06-18T05:12:10.6246721Z 
2026-06-18T05:12:10.6246906Z url = "https://osf.io/3yvhw/download"
2026-06-18T05:12:10.6247226Z fname = "biggan_deep_256"
2026-06-18T05:12:10.6247512Z r = requests.get(url, allow_redirects=True)
2026-06-18T05:12:10.6247824Z with open(fname, 'wb') as fd:
2026-06-18T05:12:10.6248099Z   fd.write(r.content)
2026-06-18T05:12:10.6248244Z 
2026-06-18T05:12:10.6248347Z biggan_model = torch.load(fname)
2026-06-18T05:12:10.6248613Z ------------------
2026-06-18T05:12:10.6248743Z 
2026-06-18T05:12:10.6248747Z 
2026-06-18T05:12:10.6249181Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T05:12:10.6249768Z �[0;31mUnpicklingError�[0m                           Traceback (most recent call last)
2026-06-18T05:12:10.6250229Z Cell �[0;32mIn[14], line 12�[0m
2026-06-18T05:12:10.6250888Z �[1;32m      9�[0m �[38;5;28;01mwith�[39;00m �[38;5;28mopen�[39m(fname, �[38;5;124m'�[39m�[38;5;124mwb�[39m�[38;5;124m'�[39m) �[38;5;28;01mas�[39;00m fd:
2026-06-18T05:12:10.6251583Z �[1;32m     10�[0m   fd�[38;5;241m.�[39mwrite(r�[38;5;241m.�[39mcontent)
2026-06-18T05:12:10.6252294Z �[0;32m---> 12�[0m biggan_model �[38;5;241m=�[39m �[43mtorch�[49m�[38;5;241;43m.�[39;49m�[43mload�[49m�[43m(�[49m�[43mfname�[49m�[43m)�[49m
2026-06-18T05:12:10.6252760Z 
2026-06-18T05:12:10.6253596Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/serialization.py:1578�[0m, in �[0;36mload�[0;34m(f, map_location, pickle_module, weights_only, mmap, **pickle_load_args)�[0m
2026-06-18T05:12:10.6254594Z �[1;32m   1570�[0m                 �[38;5;28;01mreturn�[39;00m _load(
2026-06-18T05:12:10.6255008Z �[1;32m   1571�[0m                     opened_zipfile,
2026-06-18T05:12:10.6255719Z �[1;32m   1572�[0m                     map_location,
2026-06-18T05:12:10.6256043Z �[0;32m   (...)�[0m
2026-06-18T05:12:10.6256452Z �[1;32m   1575�[0m                     �[38;5;241m*�[39m�[38;5;241m*�[39mpickle_load_args,
2026-06-18T05:12:10.6256878Z �[1;32m   1576�[0m                 )
2026-06-18T05:12:10.6257445Z �[1;32m   1577�[0m             �[38;5;28;01mexcept�[39;00m pickle�[38;5;241m.�[39mUnpicklingError �[38;5;28;01mas�[39;00m e:
2026-06-18T05:12:10.6258176Z ============================== Failure ==============================
2026-06-18T05:12:10.6259115Z �[0;32m-> 1578�[0m                 �[38;5;28;01mraise�[39;00m pickle�[38;5;241m.�[39mUnpicklingError(_get_wo_message(�[38;5;28mstr�[39m(e))) �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T05:12:10.6259884Z �[1;32m   1579�[0m         �[38;5;28;01mreturn�[39;00m _load(
2026-06-18T05:12:10.6260253Z �[1;32m   1580�[0m             opened_zipfile,
2026-06-18T05:12:10.6260580Z �[1;32m   1581�[0m             map_location,
2026-06-18T05:12:10.6260867Z �[0;32m   (...)�[0m
2026-06-18T05:12:10.6261215Z �[1;32m   1584�[0m             �[38;5;241m*�[39m�[38;5;241m*�[39mpickle_load_args,
2026-06-18T05:12:10.6261583Z �[1;32m   1585�[0m         )
2026-06-18T05:12:10.6261882Z �[1;32m   1586�[0m �[38;5;28;01mif�[39;00m mmap:
2026-06-18T05:12:10.6262076Z 
2026-06-18T05:12:10.6262743Z �[0;31mUnpicklingError�[0m: Weights only load failed. This file can still be loaded, to do so you have two options, �[1mdo those steps only if you trust the source of the checkpoint�[0m. 
2026-06-18T05:12:10.6264301Z 	(1) In PyTorch 2.6, we changed the default value of the `weights_only` argument in `torch.load` from `False` to `True`. Re-running `torch.load` with `weights_only` set to `False` will likely succeed, but it can result in arbitrary code execution. Do it only if you got the file from a trusted source.
2026-06-18T05:12:10.6265910Z 	(2) Alternatively, to load with `weights_only=True` please check the recommended steps in the following error message.
2026-06-18T05:12:10.6267763Z 	WeightsUnpickler error: Unsupported global: GLOBAL pytorch_pretrained_biggan.model.BigGAN was not an allowed global by default. Please use `torch.serialization.add_safe_globals([pytorch_pretrained_biggan.model.BigGAN])` or the `torch.serialization.safe_globals([pytorch_pretrained_biggan.model.BigGAN])` context manager to allowlist this global if you trust this class/function.
2026-06-18T05:12:10.6269123Z 
2026-06-18T05:12:10.6269632Z Check the documentation of torch.load to learn more about types accepted by default with weights_only https://pytorch.org/docs/stable/generated/torch.load.html.
2026-06-18T05:12:10.6270222Z 
2026-06-18T05:12:10.7940411Z ##[error]Process completed with exit code 1.

tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial2.ipynb

2026-06-18T05:13:12.9905096Z ============================== Failure ==============================
2026-06-18T05:13:12.9905731Z An error occurred while executing the following cell:
2026-06-18T05:13:12.9906213Z ------------------
2026-06-18T05:13:12.9907294Z # Unlike _some_ code-generator models on the market, we'll limit our training data by license :)
2026-06-18T05:13:12.9908076Z dataset = load_dataset(
2026-06-18T05:13:12.9908459Z     "codeparrot/github-code",
2026-06-18T05:13:12.9908832Z     streaming=True,
2026-06-18T05:13:12.9909403Z     split="train",
2026-06-18T05:13:12.9909735Z     languages=["JavaScript"],
2026-06-18T05:13:12.9910141Z     licenses=["mit", "isc", "apache-2.0"],
2026-06-18T05:13:12.9910607Z     trust_remote_code=True,
2026-06-18T05:13:12.9910961Z )
2026-06-18T05:13:12.9911366Z # Print the schema of the first example from the training set:
2026-06-18T05:13:12.9912012Z print({k: type(v) for k, v in next(iter(dataset)).items()})
2026-06-18T05:13:12.9912481Z ------------------
2026-06-18T05:13:12.9912669Z 
2026-06-18T05:13:12.9912790Z ----- stderr -----
2026-06-18T05:13:12.9913168Z `trust_remote_code` is not supported anymore.
2026-06-18T05:13:12.9914136Z Please check that the Hugging Face dataset 'codeparrot/github-code' isn't based on a loading script and remove `trust_remote_code`.
2026-06-18T05:13:12.9915518Z If the dataset is based on a loading script, please ask the dataset author to remove it and convert it to a standard format like Parquet.
2026-06-18T05:13:12.9916399Z ------------------
2026-06-18T05:13:12.9916604Z 
2026-06-18T05:13:12.9917182Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T05:13:12.9918032Z �[0;31mRuntimeError�[0m                              Traceback (most recent call last)
2026-06-18T05:13:12.9919142Z Cell �[0;32mIn[43], line 2�[0m
2026-06-18T05:13:12.9920121Z �[1;32m      1�[0m �[38;5;66;03m# Unlike _some_ code-generator models on the market, we'll limit our training data by license :)�[39;00m
2026-06-18T05:13:12.9921221Z �[0;32m----> 2�[0m dataset �[38;5;241m=�[39m �[43mload_dataset�[49m�[43m(�[49m
2026-06-18T05:13:12.9922295Z �[1;32m      3�[0m �[43m    �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mcodeparrot/github-code�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m
2026-06-18T05:13:12.9923479Z �[1;32m      4�[0m �[43m    �[49m�[43mstreaming�[49m�[38;5;241;43m=�[39;49m�[38;5;28;43;01mTrue�[39;49;00m�[43m,�[49m
2026-06-18T05:13:12.9924708Z �[1;32m      5�[0m �[43m    �[49m�[43msplit�[49m�[38;5;241;43m=�[39;49m�[38;5;124;43m"�[39;49m�[38;5;124;43mtrain�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m
2026-06-18T05:13:12.9926224Z �[1;32m      6�[0m �[43m    �[49m�[43mlanguages�[49m�[38;5;241;43m=�[39;49m�[43m[�[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mJavaScript�[39;49m�[38;5;124;43m"�[39;49m�[43m]�[49m�[43m,�[49m
2026-06-18T05:13:12.9928707Z �[1;32m      7�[0m �[43m    �[49m�[43mlicenses�[49m�[38;5;241;43m=�[39;49m�[43m[�[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mmit�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m�[43m �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43misc�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m�[43m �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mapache-2.0�[39;49m�[38;5;124;43m"�[39;49m�[43m]�[49m�[43m,�[49m
2026-06-18T05:13:12.9931005Z �[1;32m      8�[0m �[43m    �[49m�[43mtrust_remote_code�[49m�[38;5;241;43m=�[39;49m�[38;5;28;43;01mTrue�[39;49;00m�[43m,�[49m
2026-06-18T05:13:12.9931779Z �[1;32m      9�[0m �[43m)�[49m
2026-06-18T05:13:12.9932489Z �[1;32m     10�[0m �[38;5;66;03m# Print the schema of the first example from the training set:�[39;00m
2026-06-18T05:13:12.9933988Z �[1;32m     11�[0m �[38;5;28mprint�[39m({k: �[38;5;28mtype�[39m(v) �[38;5;28;01mfor�[39;00m k, v �[38;5;129;01min�[39;00m �[38;5;28mnext�[39m(�[38;5;28miter�[39m(dataset))�[38;5;241m.�[39mitems()})
2026-06-18T05:13:12.9934925Z 
2026-06-18T05:13:12.9937054Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1698�[0m, in �[0;36mload_dataset�[0;34m(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, verification_mode, keep_in_memory, save_infos, revision, token, streaming, num_proc, storage_options, **config_kwargs)�[0m
2026-06-18T05:13:12.9939456Z �[1;32m   1693�[0m verification_mode �[38;5;241m=�[39m VerificationMode(
2026-06-18T05:13:12.9941341Z �[1;32m   1694�[0m     (verification_mode �[38;5;129;01mor�[39;00m VerificationMode�[38;5;241m.�[39mBASIC_CHECKS) �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m save_infos �[38;5;28;01melse�[39;00m VerificationMode�[38;5;241m.�[39mALL_CHECKS
2026-06-18T05:13:12.9942669Z �[1;32m   1695�[0m )
2026-06-18T05:13:12.9943165Z �[1;32m   1697�[0m �[38;5;66;03m# Create a dataset builder�[39;00m
2026-06-18T05:13:12.9943977Z �[0;32m-> 1698�[0m builder_instance �[38;5;241m=�[39m �[43mload_dataset_builder�[49m�[43m(�[49m
2026-06-18T05:13:12.9944883Z �[1;32m   1699�[0m �[43m    �[49m�[43mpath�[49m�[38;5;241;43m=�[39;49m�[43mpath�[49m�[43m,�[49m
2026-06-18T05:13:12.9945733Z �[1;32m   1700�[0m �[43m    �[49m�[43mname�[49m�[38;5;241;43m=�[39;49m�[43mname�[49m�[43m,�[49m
2026-06-18T05:13:12.9946644Z �[1;32m   1701�[0m �[43m    �[49m�[43mdata_dir�[49m�[38;5;241;43m=�[39;49m�[43mdata_dir�[49m�[43m,�[49m
2026-06-18T05:13:12.9947652Z �[1;32m   1702�[0m �[43m    �[49m�[43mdata_files�[49m�[38;5;241;43m=�[39;49m�[43mdata_files�[49m�[43m,�[49m
2026-06-18T05:13:12.9948670Z �[1;32m   1703�[0m �[43m    �[49m�[43mcache_dir�[49m�[38;5;241;43m=�[39;49m�[43mcache_dir�[49m�[43m,�[49m
2026-06-18T05:13:12.9949873Z �[1;32m   1704�[0m �[43m    �[49m�[43mfeatures�[49m�[38;5;241;43m=�[39;49m�[43mfeatures�[49m�[43m,�[49m
2026-06-18T05:13:12.9950976Z �[1;32m   1705�[0m �[43m    �[49m�[43mdownload_config�[49m�[38;5;241;43m=�[39;49m�[43mdownload_config�[49m�[43m,�[49m
2026-06-18T05:13:12.9952277Z �[1;32m   1706�[0m �[43m    �[49m�[43mdownload_mode�[49m�[38;5;241;43m=�[39;49m�[43mdownload_mode�[49m�[43m,�[49m
2026-06-18T05:13:12.9953302Z �[1;32m   1707�[0m �[43m    �[49m�[43mrevision�[49m�[38;5;241;43m=�[39;49m�[43mrevision�[49m�[43m,�[49m
2026-06-18T05:13:12.9954238Z �[1;32m   1708�[0m �[43m    �[49m�[43mtoken�[49m�[38;5;241;43m=�[39;49m�[43mtoken�[49m�[43m,�[49m
2026-06-18T05:13:12.9955234Z �[1;32m   1709�[0m �[43m    �[49m�[43mstorage_options�[49m�[38;5;241;43m=�[39;49m�[43mstorage_options�[49m�[43m,�[49m
2026-06-18T05:13:12.9956287Z �[1;32m   1710�[0m �[43m    �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mconfig_kwargs�[49m�[43m,�[49m
2026-06-18T05:13:12.9956996Z �[1;32m   1711�[0m �[43m�[49m�[43m)�[49m
2026-06-18T05:13:12.9957636Z �[1;32m   1713�[0m �[38;5;66;03m# Return iterable dataset in case of streaming�[39;00m
2026-06-18T05:13:12.9958337Z �[1;32m   1714�[0m �[38;5;28;01mif�[39;00m streaming:
2026-06-18T05:13:12.9958645Z 
2026-06-18T05:13:12.9960499Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1325�[0m, in �[0;36mload_dataset_builder�[0;34m(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, token, storage_options, **config_kwargs)�[0m
2026-06-18T05:13:12.9962620Z �[1;32m   1323�[0m �[38;5;28;01mif�[39;00m features �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T05:13:12.9963666Z �[1;32m   1324�[0m     features �[38;5;241m=�[39m _fix_for_backward_compatible_features(features)
2026-06-18T05:13:12.9964668Z �[0;32m-> 1325�[0m dataset_module �[38;5;241m=�[39m �[43mdataset_module_factory�[49m�[43m(�[49m
2026-06-18T05:13:12.9965447Z �[1;32m   1326�[0m �[43m    �[49m�[43mpath�[49m�[43m,�[49m
2026-06-18T05:13:12.9966297Z �[1;32m   1327�[0m �[43m    �[49m�[43mrevision�[49m�[38;5;241;43m=�[39;49m�[43mrevision�[49m�[43m,�[49m
2026-06-18T05:13:12.9967374Z �[1;32m   1328�[0m �[43m    �[49m�[43mdownload_config�[49m�[38;5;241;43m=�[39;49m�[43mdownload_config�[49m�[43m,�[49m
2026-06-18T05:13:12.9968472Z �[1;32m   1329�[0m �[43m    �[49m�[43mdownload_mode�[49m�[38;5;241;43m=�[39;49m�[43mdownload_mode�[49m�[43m,�[49m
2026-06-18T05:13:12.9969670Z �[1;32m   1330�[0m �[43m    �[49m�[43mdata_dir�[49m�[38;5;241;43m=�[39;49m�[43mdata_dir�[49m�[43m,�[49m
2026-06-18T05:13:12.9970646Z �[1;32m   1331�[0m �[43m    �[49m�[43mdata_files�[49m�[38;5;241;43m=�[39;49m�[43mdata_files�[49m�[43m,�[49m
2026-06-18T05:13:12.9971610Z �[1;32m   1332�[0m �[43m    �[49m�[43mcache_dir�[49m�[38;5;241;43m=�[39;49m�[43mcache_dir�[49m�[43m,�[49m
2026-06-18T05:13:12.9972289Z �[1;32m   1333�[0m �[43m�[49m�[43m)�[49m
2026-06-18T05:13:12.9973052Z �[1;32m   1334�[0m �[38;5;66;03m# Get dataset builder class�[39;00m
2026-06-18T05:13:12.9973891Z �[1;32m   1335�[0m builder_kwargs �[38;5;241m=�[39m dataset_module�[38;5;241m.�[39mbuilder_kwargs
2026-06-18T05:13:12.9974407Z 
2026-06-18T05:13:12.9975875Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1217�[0m, in �[0;36mdataset_module_factory�[0;34m(path, revision, download_config, download_mode, data_dir, data_files, cache_dir, **download_kwargs)�[0m
2026-06-18T05:13:12.9977835Z �[1;32m   1212�[0m             �[38;5;28;01mif�[39;00m �[38;5;28misinstance�[39m(e1, �[38;5;167;01mFileNotFoundError�[39;00m):
2026-06-18T05:13:12.9978878Z �[1;32m   1213�[0m                 �[38;5;28;01mraise�[39;00m �[38;5;167;01mFileNotFoundError�[39;00m(
2026-06-18T05:13:12.9980953Z �[1;32m   1214�[0m                     �[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find any data file at �[39m�[38;5;132;01m{�[39;00mrelative_to_absolute_path(path)�[38;5;132;01m}�[39;00m�[38;5;124m. �[39m�[38;5;124m"�[39m
2026-06-18T05:13:12.9984199Z �[1;32m   1215�[0m                     �[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find �[39m�[38;5;124m'�[39m�[38;5;132;01m{�[39;00mpath�[38;5;132;01m}�[39;00m�[38;5;124m'�[39m�[38;5;124m on the Hugging Face Hub either: �[39m�[38;5;132;01m{�[39;00m�[38;5;28mtype�[39m(e1)�[38;5;241m.�[39m�[38;5;18m__name__�[39m�[38;5;132;01m}�[39;00m�[38;5;124m: �[39m�[38;5;132;01m{�[39;00me1�[38;5;132;01m}�[39;00m�[38;5;124m"�[39m
2026-06-18T05:13:12.9986706Z �[1;32m   1216�[0m                 ) �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T05:13:12.9987759Z �[0;32m-> 1217�[0m             �[38;5;28;01mraise�[39;00m e1 �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T05:13:12.9988629Z �[1;32m   1218�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T05:13:12.9990826Z �[1;32m   1219�[0m     �[38;5;28;01mraise�[39;00m �[38;5;167;01mFileNotFoundError�[39;00m(�[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find any data file at �[39m�[38;5;132;01m{�[39;00mrelative_to_absolute_path(path)�[38;5;132;01m}�[39;00m�[38;5;124m.�[39m�[38;5;124m"�[39m)
2026-06-18T05:13:12.9992226Z 
2026-06-18T05:13:12.9993692Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1177�[0m, in �[0;36mdataset_module_factory�[0;34m(path, revision, download_config, download_mode, data_dir, data_files, cache_dir, **download_kwargs)�[0m
2026-06-18T05:13:12.9995268Z �[1;32m   1169�[0m �[38;5;28;01mtry�[39;00m:
2026-06-18T05:13:12.9995833Z �[1;32m   1170�[0m     api�[38;5;241m.�[39mhf_hub_download(
2026-06-18T05:13:12.9996431Z �[1;32m   1171�[0m         repo_id�[38;5;241m=�[39mpath,
2026-06-18T05:13:12.9997054Z �[1;32m   1172�[0m         filename�[38;5;241m=�[39mfilename,
2026-06-18T05:13:12.9997550Z �[0;32m   (...)�[0m
2026-06-18T05:13:12.9998148Z �[1;32m   1175�[0m         proxies�[38;5;241m=�[39mdownload_config�[38;5;241m.�[39mproxies,
2026-06-18T05:13:12.9998805Z �[1;32m   1176�[0m     )
2026-06-18T05:13:13.0000599Z �[0;32m-> 1177�[0m     �[38;5;28;01mraise�[39;00m �[38;5;167;01mRuntimeError�[39;00m(�[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mDataset scripts are no longer supported, but found �[39m�[38;5;132;01m{�[39;00mfilename�[38;5;132;01m}�[39;00m�[38;5;124m"�[39m)
2026-06-18T05:13:13.0002157Z �[1;32m   1178�[0m �[38;5;28;01mexcept�[39;00m EntryNotFoundError:
2026-06-18T05:13:13.0003065Z �[1;32m   1179�[0m     �[38;5;66;03m# Use the infos from the parquet export except in some cases:�[39;00m
2026-06-18T05:13:13.0004780Z �[1;32m   1180�[0m     �[38;5;28;01mif�[39;00m data_dir �[38;5;129;01mor�[39;00m data_files �[38;5;129;01mor�[39;00m (revision �[38;5;129;01mand�[39;00m revision �[38;5;241m!=�[39m �[38;5;124m"�[39m�[38;5;124mmain�[39m�[38;5;124m"�[39m):
2026-06-18T05:13:13.0005844Z 
2026-06-18T05:13:13.0006522Z �[0;31mRuntimeError�[0m: Dataset scripts are no longer supported, but found github-code.py
2026-06-18T05:13:13.0007081Z 
2026-06-18T05:13:13.1527022Z ##[error]Process completed with exit code 1.

tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb

2026-06-18T05:35:44.0905643Z Executing tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb
2026-06-18T05:35:45.4695685Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T05:37:00.0093215Z tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb failed quality control.
2026-06-18T05:37:00.0094363Z An error occurred while executing the following cell:
2026-06-18T05:37:00.0095012Z ------------------
2026-06-18T05:37:00.0096243Z # @title Bonus 1.4: Sentiment binary-classification with likelihood of positive and negative extensions of the review 👍👎
2026-06-18T05:37:00.0096900Z 
2026-06-18T05:37:00.0097018Z # @markdown ---
2026-06-18T05:37:00.0097430Z model_name = "gpt2"  # @param ["gpt2", "gpt2-medium", "xlnet-base-cased"]
2026-06-18T05:37:00.0098394Z model = AutoModelForCausalLM.from_pretrained(model_name)
2026-06-18T05:37:00.0098850Z model.eval()
2026-06-18T05:37:00.0099194Z tokenizer = AutoTokenizer.from_pretrained(model_name)
2026-06-18T05:37:00.0099872Z # @markdown **Select a pre-trained language model to score the likelihood of extended review**
2026-06-18T05:37:00.0100320Z 
2026-06-18T05:37:00.0100594Z # @markdown *(might take some time to download the pre-trained weights for the first time)*
2026-06-18T05:37:00.0100974Z 
2026-06-18T05:37:00.0101426Z # @markdown ---
2026-06-18T05:37:00.0102141Z custom_positive_extension = "I would definitely recommend this!"  # @param {type:"string"}
2026-06-18T05:37:00.0102929Z custom_negative_extension = "I would not recommend this!"  # @param {type:"string"}
2026-06-18T05:37:00.0103619Z # @markdown **Provide custom positive and negative extensions to the review ✍️**
2026-06-18T05:37:00.0103971Z 
2026-06-18T05:37:00.0104182Z texts = [context, custom_positive_extension, custom_negative_extension]
2026-06-18T05:37:00.0104815Z encodings = tokenizer(texts)
2026-06-18T05:37:00.0104995Z 
2026-06-18T05:37:00.0105276Z positive_input_ids = torch.tensor(encodings["input_ids"][0] + encodings["input_ids"][1])
2026-06-18T05:37:00.0105982Z positive_attention_mask = torch.tensor(encodings["attention_mask"][0] + encodings["attention_mask"][1])
2026-06-18T05:37:00.0106711Z positive_label_ids = torch.tensor([-100]*len(encodings["input_ids"][0]) + encodings["input_ids"][1])
2026-06-18T05:37:00.0107247Z outputs = model(input_ids=positive_input_ids,
2026-06-18T05:37:00.0107600Z                 attention_mask=positive_attention_mask,
2026-06-18T05:37:00.0107941Z                 labels=positive_label_ids)
2026-06-18T05:37:00.0108292Z positive_extension_likelihood = -1*outputs.loss
2026-06-18T05:37:00.0108801Z print("\nLog-likelihood of positive extension = ", positive_extension_likelihood.item())
2026-06-18T05:37:00.0109188Z 
2026-06-18T05:37:00.0109461Z negative_input_ids = torch.tensor(encodings["input_ids"][0] + encodings["input_ids"][2])
2026-06-18T05:37:00.0110150Z negative_attention_mask = torch.tensor(encodings["attention_mask"][0] + encodings["attention_mask"][2])
2026-06-18T05:37:00.0110871Z negative_label_ids = torch.tensor([-100]*len(encodings["input_ids"][0]) + encodings["input_ids"][2])
2026-06-18T05:37:00.0111665Z outputs = model(input_ids=negative_input_ids,
2026-06-18T05:37:00.0112014Z                 attention_mask=negative_attention_mask,
2026-06-18T05:37:00.0112331Z                 labels=negative_label_ids)
2026-06-18T05:37:00.0112649Z negative_extension_likelihood = -1*outputs.loss
2026-06-18T05:37:00.0113111Z print("\nLog-likelihood of negative extension = ", negative_extension_likelihood.item())
2026-06-18T05:37:00.0113461Z 
2026-06-18T05:37:00.0113696Z if (positive_extension_likelihood.item() > negative_extension_likelihood.item()):
2026-06-18T05:37:00.0114234Z     print("\nPositive text-extension has greater likelihood probabilities!")
2026-06-18T05:37:00.0114777Z     print("The given review can be predicted to be POSITIVE 👍")
2026-06-18T05:37:00.0115125Z else:
2026-06-18T05:37:00.0115435Z     print("\nNegative text-extension has greater likelihood probabilities!")
2026-06-18T05:37:00.0115943Z     print("The given review can be predicted to be NEGATIVE 👎")
2026-06-18T05:37:00.0116401Z # @markdown **NOTE:** *Run this cell after setting all the fields appropriately!*
2026-06-18T05:37:00.0116707Z 
2026-06-18T05:37:00.0116932Z # @markdown **NOTE:** *Some pre-trained models might not work well with longer texts!*
2026-06-18T05:37:00.0117338Z ------------------
2026-06-18T05:37:00.0117467Z 
2026-06-18T05:37:00.0117472Z 
2026-06-18T05:37:00.0117720Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T05:37:00.0118243Z �[0;31mIndexError�[0m                                Traceback (most recent call last)
2026-06-18T05:37:00.0118668Z Cell �[0;32mIn[17], line 23�[0m
2026-06-18T05:37:00.0119980Z �[1;32m     21�[0m positive_attention_mask �[38;5;241m=�[39m torch�[38;5;241m.�[39mtensor(encodings[�[38;5;124m"�[39m�[38;5;124mattention_mask�[39m�[38;5;124m"�[39m][�[38;5;241m0�[39m] �[38;5;241m+�[39m encodings[�[38;5;124m"�[39m�[38;5;124mattention_mask�[39m�[38;5;124m"�[39m][�[38;5;241m1�[39m])
2026-06-18T05:37:00.0122476Z �[1;32m     22�[0m positive_label_ids �[38;5;241m=�[39m torch�[38;5;241m.�[39mtensor([�[38;5;241m-�[39m�[38;5;241m100�[39m]�[38;5;241m*�[39m�[38;5;28mlen�[39m(encodings[�[38;5;124m"�[39m�[38;5;124minput_ids�[39m�[38;5;124m"�[39m][�[38;5;241m0�[39m]) �[38;5;241m+�[39m encodings[�[38;5;124m"�[39m�[38;5;124minput_ids�[39m�[38;5;124m"�[39m][�[38;5;241m1�[39m])
2026-06-18T05:37:00.0123950Z �[0;32m---> 23�[0m outputs �[38;5;241m=�[39m �[43mmodel�[49m�[43m(�[49m�[43minput_ids�[49m�[38;5;241;43m=�[39;49m�[43mpositive_input_ids�[49m�[43m,�[49m
2026-06-18T05:37:00.0124823Z �[1;32m     24�[0m �[43m                �[49m�[43mattention_mask�[49m�[38;5;241;43m=�[39;49m�[43mpositive_attention_mask�[49m�[43m,�[49m
2026-06-18T05:37:00.0125577Z �[1;32m     25�[0m �[43m                �[49m�[43mlabels�[49m�[38;5;241;43m=�[39;49m�[43mpositive_label_ids�[49m�[43m)�[49m
2026-06-18T05:37:00.0126557Z �[1;32m     26�[0m positive_extension_likelihood �[38;5;241m=�[39m �[38;5;241m-�[39m�[38;5;241m1�[39m�[38;5;241m*�[39moutputs�[38;5;241m.�[39mloss
2026-06-18T05:37:00.0127686Z �[1;32m     27�[0m �[38;5;28mprint�[39m(�[38;5;124m"�[39m�[38;5;130;01m\n�[39;00m�[38;5;124mLog-likelihood of positive extension = �[39m�[38;5;124m"�[39m, positive_extension_likelihood�[38;5;241m.�[39mitem())
2026-06-18T05:37:00.0128323Z 
2026-06-18T05:37:00.0129016Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/nn/modules/module.py:1778�[0m, in �[0;36mModule._wrapped_call_impl�[0;34m(self, *args, **kwargs)�[0m
2026-06-18T05:37:00.0130368Z �[1;32m   1776�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_compiled_call_impl(�[38;5;241m*�[39margs, �[38;5;241m*�[39m�[38;5;241m*�[39mkwargs)  �[38;5;66;03m# type: ignore[misc]�[39;00m
2026-06-18T05:37:00.0131430Z �[1;32m   1777�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T05:37:00.0132431Z �[0;32m-> 1778�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43m_call_impl�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m,�[49m�[43m �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mkwargs�[49m�[43m)�[49m
2026-06-18T05:37:00.0133128Z 
2026-06-18T05:37:00.0133795Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/nn/modules/module.py:1789�[0m, in �[0;36mModule._call_impl�[0;34m(self, *args, **kwargs)�[0m
2026-06-18T05:37:00.0134773Z �[1;32m   1784�[0m �[38;5;66;03m# If we don't have any hooks, we want to skip the rest of the logic in�[39;00m
2026-06-18T05:37:00.0135373Z �[1;32m   1785�[0m �[38;5;66;03m# this function, and just call forward.�[39;00m
2026-06-18T05:37:00.0136766Z �[1;32m   1786�[0m �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m (�[38;5;28mself�[39m�[38;5;241m.�[39m_backward_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_backward_pre_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_forward_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_forward_pre_hooks
2026-06-18T05:37:00.0138131Z �[1;32m   1787�[0m         �[38;5;129;01mor�[39;00m _global_backward_pre_hooks �[38;5;129;01mor�[39;00m _global_backward_hooks
2026-06-18T05:37:00.0138901Z �[1;32m   1788�[0m         �[38;5;129;01mor�[39;00m _global_forward_hooks �[38;5;129;01mor�[39;00m _global_forward_pre_hooks):
2026-06-18T05:37:00.0139943Z �[0;32m-> 1789�[0m     �[38;5;28;01mreturn�[39;00m �[43mforward_call�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m,�[49m�[43m �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mkwargs�[49m�[43m)�[49m
2026-06-18T05:37:00.0140747Z �[1;32m   1791�[0m result �[38;5;241m=�[39m �[38;5;28;01mNone�[39;00m
2026-06-18T05:37:00.0141501Z �[1;32m   1792�[0m called_always_called_hooks �[38;5;241m=�[39m �[38;5;28mset�[39m()
2026-06-18T05:37:00.0141821Z 
2026-06-18T05:37:00.0143705Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/transformers/models/gpt2/modeling_gpt2.py:1092�[0m, in �[0;36mGPT2LMHeadModel.forward�[0;34m(self, input_ids, past_key_values, cache_position, attention_mask, token_type_ids, position_ids, head_mask, inputs_embeds, encoder_hidden_states, encoder_attention_mask, labels, use_cache, output_attentions, output_hidden_states, return_dict, logits_to_keep, **kwargs)�[0m
2026-06-18T05:37:00.0145846Z �[1;32m   1089�[0m     hidden_states �[38;5;241m=�[39m hidden_states�[38;5;241m.�[39mto(�[38;5;28mself�[39m�[38;5;241m.�[39mlm_head�[38;5;241m.�[39mweight�[38;5;241m.�[39mdevice)
2026-06-18T05:37:00.0147209Z �[1;32m   1091�[0m slice_indices �[38;5;241m=�[39m �[38;5;28mslice�[39m(�[38;5;241m-�[39mlogits_to_keep, �[38;5;28;01mNone�[39;00m) �[38;5;28;01mif�[39;00m �[38;5;28misinstance�[39m(logits_to_keep, �[38;5;28mint�[39m) �[38;5;28;01melse�[39;00m logits_to_keep
2026-06-18T05:37:00.0148663Z �[0;32m-> 1092�[0m logits �[38;5;241m=�[39m �[38;5;28mself�[39m�[38;5;241m.�[39mlm_head(�[43mhidden_states�[49m�[43m[�[49m�[43m:�[49m�[43m,�[49m�[43m �[49m�[43mslice_indices�[49m�[43m,�[49m�[43m �[49m�[43m:�[49m�[43m]�[49m)
2026-06-18T05:37:00.0149631Z �[1;32m   1094�[0m loss �[38;5;241m=�[39m �[38;5;28;01mNone�[39;00m
2026-06-18T05:37:00.0150253Z �[1;32m   1095�[0m �[38;5;28;01mif�[39;00m labels �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T05:37:00.0150826Z �[1;32m   1096�[0m     �[38;5;66;03m# Flatten the tokens�[39;00m
2026-06-18T05:37:00.0151338Z 
2026-06-18T05:37:00.0151588Z �[0;31mIndexError�[0m: too many indices for tensor of dimension 2
2026-06-18T05:37:00.0151857Z 
2026-06-18T05:37:00.0151991Z ============================== Failure ==============================
2026-06-18T05:37:00.1997023Z ##[error]Process completed with exit code 1.

@github-actions

Copy link
Copy Markdown

Notebook Processing Failure Context

tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb

2026-06-18T06:35:44.0283177Z Executing tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb
2026-06-18T06:35:44.9607991Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T06:35:55.1692441Z tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb failed quality control.
2026-06-18T06:35:55.1693200Z An error occurred while executing the following cell:
2026-06-18T06:35:55.1693703Z ------------------
2026-06-18T06:35:55.1694106Z # Visualize the output of your function
2026-06-18T06:35:55.1694642Z from IPython.display import display as IPydisplay
2026-06-18T06:35:55.1694991Z 
2026-06-18T06:35:55.1695341Z with open("images/chicago_skyline_shrunk_v2.bmp", 'rb') as skyline_image_file:
2026-06-18T06:35:55.1696045Z   img_skyline_orig = Image.open(skyline_image_file)
2026-06-18T06:35:55.1696581Z   img_skyline_mat = np.asarray(img_skyline_orig)
2026-06-18T06:35:55.1697566Z   kernel_ver = np.array([[-1, 0, 1], [-2, 0, 2], [-1, 0, 1]])
2026-06-18T06:35:55.1698188Z   kernel_hor = np.array([[-1, 0, 1], [-2, 0, 2], [-1, 0, 1]]).T
2026-06-18T06:35:55.1699063Z   img_processed_mat_ver = convolution2d(img_skyline_mat, kernel_ver)
2026-06-18T06:35:55.1699738Z   img_processed_mat_hor = convolution2d(img_skyline_mat, kernel_hor)
2026-06-18T06:35:55.1700436Z   img_processed_mat = np.sqrt(np.multiply(img_processed_mat_ver,
2026-06-18T06:35:55.1701039Z                                           img_processed_mat_ver) + \
2026-06-18T06:35:55.1701573Z                               np.multiply(img_processed_mat_hor,
2026-06-18T06:35:55.1702320Z                                           img_processed_mat_hor))
2026-06-18T06:35:55.1702642Z 
2026-06-18T06:35:55.1702850Z   img_processed_mat *= 255.0/img_processed_mat.max()
2026-06-18T06:35:55.1703402Z   img_processed_mat = img_processed_mat.astype(np.uint8)
2026-06-18T06:35:55.1703987Z   img_processed = Image.fromarray(img_processed_mat, 'L')
2026-06-18T06:35:55.1704523Z   width, height = img_skyline_orig.size
2026-06-18T06:35:55.1704938Z   scale = 0.6
2026-06-18T06:35:55.1705438Z   IPydisplay(img_skyline_orig.resize((int(width*scale), int(height*scale))),
2026-06-18T06:35:55.1706050Z              Image.NEAREST)
2026-06-18T06:35:55.1706582Z   IPydisplay(img_processed.resize((int(width*scale), int(height*scale))),
2026-06-18T06:35:55.1707171Z              Image.NEAREST)
2026-06-18T06:35:55.1707511Z ------------------
2026-06-18T06:35:55.1707710Z 
2026-06-18T06:35:55.1707716Z 
2026-06-18T06:35:55.1708332Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T06:35:55.1709265Z �[0;31mUnidentifiedImageError�[0m                    Traceback (most recent call last)
2026-06-18T06:35:55.1709997Z Cell �[0;32mIn[30], line 5�[0m
2026-06-18T06:35:55.1711356Z �[1;32m      2�[0m �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;21;01mIPython�[39;00m�[38;5;21;01m.�[39;00m�[38;5;21;01mdisplay�[39;00m�[38;5;250m �[39m�[38;5;28;01mimport�[39;00m display �[38;5;28;01mas�[39;00m IPydisplay
2026-06-18T06:35:55.1713795Z �[1;32m      4�[0m �[38;5;28;01mwith�[39;00m �[38;5;28mopen�[39m(�[38;5;124m"�[39m�[38;5;124mimages/chicago_skyline_shrunk_v2.bmp�[39m�[38;5;124m"�[39m, �[38;5;124m'�[39m�[38;5;124mrb�[39m�[38;5;124m'�[39m) �[38;5;28;01mas�[39;00m skyline_image_file:
2026-06-18T06:35:55.1715677Z �[0;32m----> 5�[0m   img_skyline_orig �[38;5;241m=�[39m �[43mImage�[49m�[38;5;241;43m.�[39;49m�[43mopen�[49m�[43m(�[49m�[43mskyline_image_file�[49m�[43m)�[49m
2026-06-18T06:35:55.1716894Z �[1;32m      6�[0m   img_skyline_mat �[38;5;241m=�[39m np�[38;5;241m.�[39masarray(img_skyline_orig)
2026-06-18T06:35:55.1718760Z �[1;32m      7�[0m   kernel_ver �[38;5;241m=�[39m np�[38;5;241m.�[39marray([[�[38;5;241m-�[39m�[38;5;241m1�[39m, �[38;5;241m0�[39m, �[38;5;241m1�[39m], [�[38;5;241m-�[39m�[38;5;241m2�[39m, �[38;5;241m0�[39m, �[38;5;241m2�[39m], [�[38;5;241m-�[39m�[38;5;241m1�[39m, �[38;5;241m0�[39m, �[38;5;241m1�[39m]])
2026-06-18T06:35:55.1719942Z 
2026-06-18T06:35:55.1720814Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/PIL/Image.py:3711�[0m, in �[0;36mopen�[0;34m(fp, mode, formats)�[0m
2026-06-18T06:35:55.1722149Z �[1;32m   3709�[0m     warnings�[38;5;241m.�[39mwarn(message)
2026-06-18T06:35:55.1723747Z �[1;32m   3710�[0m msg �[38;5;241m=�[39m �[38;5;124m"�[39m�[38;5;124mcannot identify image file �[39m�[38;5;132;01m%r�[39;00m�[38;5;124m"�[39m �[38;5;241m%�[39m (filename �[38;5;28;01mif�[39;00m filename �[38;5;28;01melse�[39;00m fp)
2026-06-18T06:35:55.1725176Z �[0;32m-> 3711�[0m �[38;5;28;01mraise�[39;00m UnidentifiedImageError(msg)
2026-06-18T06:35:55.1725575Z 
2026-06-18T06:35:55.1726340Z �[0;31mUnidentifiedImageError�[0m: cannot identify image file <_io.BufferedReader name='images/chicago_skyline_shrunk_v2.bmp'>
2026-06-18T06:35:55.1727070Z 
2026-06-18T06:35:55.1727275Z ============================== Failure ==============================
2026-06-18T06:35:55.3630022Z ##[error]Process completed with exit code 1.

tutorials/W2D2_Convnets/W2D2_Tutorial3.ipynb

2026-06-18T06:36:31.9717590Z 
2026-06-18T06:36:31.9717867Z  67%|██████▋   | 156M/233M [00:00<00:00, 223MB/s]
2026-06-18T06:36:31.9718219Z ----- stderr -----
2026-06-18T06:36:31.9718347Z 
2026-06-18T06:36:31.9718504Z  77%|███████▋  | 179M/233M [00:00<00:00, 229MB/s]
2026-06-18T06:36:31.9718777Z ----- stderr -----
2026-06-18T06:36:31.9718891Z 
2026-06-18T06:36:31.9719042Z  86%|████████▋ | 201M/233M [00:01<00:00, 229MB/s]
2026-06-18T06:36:31.9719315Z ----- stderr -----
2026-06-18T06:36:31.9719435Z 
2026-06-18T06:36:31.9719586Z  96%|█████████▌| 223M/233M [00:01<00:00, 230MB/s]
2026-06-18T06:36:31.9719851Z ----- stderr -----
2026-06-18T06:36:31.9719972Z 
2026-06-18T06:36:31.9720416Z 100%|██████████| 233M/233M [00:01<00:00, 213MB/s]
2026-06-18T06:36:31.9720713Z ----- stderr -----
2026-06-18T06:36:31.9720847Z 
2026-06-18T06:36:31.9720924Z ------------------
2026-06-18T06:36:31.9721042Z 
2026-06-18T06:36:31.9721307Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T06:36:31.9721863Z �[0;31mAttributeError�[0m                            Traceback (most recent call last)
2026-06-18T06:36:31.9722279Z Cell �[0;32mIn[15], line 12�[0m
2026-06-18T06:36:31.9723425Z �[1;32m     11�[0m url, filename �[38;5;241m=�[39m (�[38;5;124m"�[39m�[38;5;124mhttps://raw.githubusercontent.com/NeuromatchAcademy/course-content-dl/main/tutorials/W2D2_Convnets/static/dog.jpg�[39m�[38;5;124m"�[39m, �[38;5;124m"�[39m�[38;5;124mdog.jpg�[39m�[38;5;124m"�[39m)
2026-06-18T06:36:31.9725038Z �[0;32m---> 12�[0m �[38;5;28;01mtry�[39;00m: urllib�[38;5;241m.�[39mURLopener()�[38;5;241m.�[39mretrieve(url, filename)
2026-06-18T06:36:31.9725876Z �[1;32m     13�[0m �[38;5;28;01mexcept�[39;00m: urllib�[38;5;241m.�[39mrequest�[38;5;241m.�[39murlretrieve(url, filename)
2026-06-18T06:36:31.9726269Z 
2026-06-18T06:36:31.9726521Z �[0;31mAttributeError�[0m: module 'urllib' has no attribute 'URLopener'
2026-06-18T06:36:31.9726818Z 
2026-06-18T06:36:31.9727008Z During handling of the above exception, another exception occurred:
2026-06-18T06:36:31.9727284Z 
2026-06-18T06:36:31.9727528Z �[0;31mHTTPError�[0m                                 Traceback (most recent call last)
2026-06-18T06:36:31.9727935Z Cell �[0;32mIn[15], line 13�[0m
2026-06-18T06:36:31.9729069Z �[1;32m     11�[0m url, filename �[38;5;241m=�[39m (�[38;5;124m"�[39m�[38;5;124mhttps://raw.githubusercontent.com/NeuromatchAcademy/course-content-dl/main/tutorials/W2D2_Convnets/static/dog.jpg�[39m�[38;5;124m"�[39m, �[38;5;124m"�[39m�[38;5;124mdog.jpg�[39m�[38;5;124m"�[39m)
2026-06-18T06:36:31.9730294Z �[1;32m     12�[0m �[38;5;28;01mtry�[39;00m: urllib�[38;5;241m.�[39mURLopener()�[38;5;241m.�[39mretrieve(url, filename)
2026-06-18T06:36:31.9731042Z �[0;32m---> 13�[0m �[38;5;28;01mexcept�[39;00m: urllib�[38;5;241m.�[39mrequest�[38;5;241m.�[39murlretrieve(url, filename)
2026-06-18T06:36:31.9731858Z �[1;32m     15�[0m input_image �[38;5;241m=�[39m Image�[38;5;241m.�[39mopen(filename)
2026-06-18T06:36:31.9732391Z �[1;32m     16�[0m preprocess �[38;5;241m=�[39m transforms�[38;5;241m.�[39mCompose([
2026-06-18T06:36:31.9732964Z �[1;32m     17�[0m                                  transforms�[38;5;241m.�[39mResize(�[38;5;241m256�[39m),
2026-06-18T06:36:31.9733555Z �[1;32m     18�[0m                                  transforms�[38;5;241m.�[39mCenterCrop(�[38;5;241m224�[39m),
2026-06-18T06:36:31.9733975Z �[0;32m   (...)�[0m
2026-06-18T06:36:31.9734501Z �[1;32m     21�[0m                                                       std�[38;5;241m=�[39m[�[38;5;241m0.229�[39m, �[38;5;241m0.224�[39m, �[38;5;241m0.225�[39m]),
2026-06-18T06:36:31.9735356Z �[1;32m     22�[0m                                  ])
2026-06-18T06:36:31.9735567Z 
2026-06-18T06:36:31.9736155Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:241�[0m, in �[0;36murlretrieve�[0;34m(url, filename, reporthook, data)�[0m
2026-06-18T06:36:31.9736901Z �[1;32m    224�[0m �[38;5;250m�[39m�[38;5;124;03m"""�[39;00m
2026-06-18T06:36:31.9737403Z �[1;32m    225�[0m �[38;5;124;03mRetrieve a URL into a temporary location on disk.�[39;00m
2026-06-18T06:36:31.9737818Z �[1;32m    226�[0m 
2026-06-18T06:36:31.9738038Z �[0;32m   (...)�[0m
2026-06-18T06:36:31.9738453Z �[1;32m    237�[0m �[38;5;124;03mdata file as well as the resulting HTTPMessage object.�[39;00m
2026-06-18T06:36:31.9738914Z �[1;32m    238�[0m �[38;5;124;03m"""�[39;00m
2026-06-18T06:36:31.9739326Z �[1;32m    239�[0m url_type, path �[38;5;241m=�[39m _splittype(url)
2026-06-18T06:36:31.9740215Z �[0;32m--> 241�[0m �[38;5;28;01mwith�[39;00m contextlib�[38;5;241m.�[39mclosing(�[43murlopen�[49m�[43m(�[49m�[43murl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m)�[49m) �[38;5;28;01mas�[39;00m fp:
2026-06-18T06:36:31.9741153Z �[1;32m    242�[0m     headers �[38;5;241m=�[39m fp�[38;5;241m.�[39minfo()
2026-06-18T06:36:31.9741772Z �[1;32m    244�[0m     �[38;5;66;03m# Just return the local path and the "headers" for file://�[39;00m
2026-06-18T06:36:31.9742429Z �[1;32m    245�[0m     �[38;5;66;03m# URLs. No sense in performing a copy unless requested.�[39;00m
2026-06-18T06:36:31.9742765Z 
2026-06-18T06:36:31.9743409Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:216�[0m, in �[0;36murlopen�[0;34m(url, data, timeout, cafile, capath, cadefault, context)�[0m
2026-06-18T06:36:31.9744165Z �[1;32m    214�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T06:36:31.9744523Z �[1;32m    215�[0m     opener �[38;5;241m=�[39m _opener
2026-06-18T06:36:31.9745695Z �[0;32m--> 216�[0m �[38;5;28;01mreturn�[39;00m �[43mopener�[49m�[38;5;241;43m.�[39;49m�[43mopen�[49m�[43m(�[49m�[43murl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m,�[49m�[43m �[49m�[43mtimeout�[49m�[43m)�[49m
2026-06-18T06:36:31.9746300Z 
2026-06-18T06:36:31.9746941Z File �[0;32m~/.ipython/profile_default/startup/00-stub-widgets.py:154�[0m, in �[0;36m_install_resilient_opener.<locals>._open_with_retry�[0;34m(fullurl, data, timeout)�[0m
2026-06-18T06:36:31.9748010Z �[1;32m    152�[0m �[38;5;28;01mfor�[39;00m attempt �[38;5;129;01min�[39;00m �[38;5;28mrange�[39m(_MAX_RETRIES �[38;5;241m+�[39m �[38;5;241m1�[39m):
2026-06-18T06:36:31.9748610Z �[1;32m    153�[0m     �[38;5;28;01mtry�[39;00m:
2026-06-18T06:36:31.9749395Z �[0;32m--> 154�[0m         �[38;5;28;01mreturn�[39;00m �[43m_inner_open�[49m�[43m(�[49m�[43mfullurl�[49m�[43m,�[49m�[43m �[49m�[43mdata�[49m�[43m,�[49m�[43m �[49m�[43mtimeout�[49m�[43m)�[49m
2026-06-18T06:36:31.9750359Z �[1;32m    155�[0m     �[38;5;28;01mexcept�[39;00m urllib�[38;5;241m.�[39merror�[38;5;241m.�[39mHTTPError �[38;5;28;01mas�[39;00m e:
2026-06-18T06:36:31.9751391Z �[1;32m    156�[0m         �[38;5;28;01mif�[39;00m e�[38;5;241m.�[39mcode �[38;5;129;01mnot�[39;00m �[38;5;129;01min�[39;00m _RETRY_STATUSES �[38;5;129;01mor�[39;00m attempt �[38;5;241m==�[39m _MAX_RETRIES:
2026-06-18T06:36:31.9751981Z 
2026-06-18T06:36:31.9752587Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:525�[0m, in �[0;36mOpenerDirector.open�[0;34m(self, fullurl, data, timeout)�[0m
2026-06-18T06:36:31.9753861Z �[1;32m    523�[0m �[38;5;28;01mfor�[39;00m processor �[38;5;129;01min�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39mprocess_response�[38;5;241m.�[39mget(protocol, []):
2026-06-18T06:36:31.9754875Z �[1;32m    524�[0m     meth �[38;5;241m=�[39m �[38;5;28mgetattr�[39m(processor, meth_name)
2026-06-18T06:36:31.9755640Z �[0;32m--> 525�[0m     response �[38;5;241m=�[39m �[43mmeth�[49m�[43m(�[49m�[43mreq�[49m�[43m,�[49m�[43m �[49m�[43mresponse�[49m�[43m)�[49m
2026-06-18T06:36:31.9756238Z �[1;32m    527�[0m �[38;5;28;01mreturn�[39;00m response
2026-06-18T06:36:31.9756456Z 
2026-06-18T06:36:31.9757103Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:634�[0m, in �[0;36mHTTPErrorProcessor.http_response�[0;34m(self, request, response)�[0m
2026-06-18T06:36:31.9758042Z �[1;32m    631�[0m �[38;5;66;03m# According to RFC 2616, "2xx" code indicates that the client's�[39;00m
2026-06-18T06:36:31.9758717Z �[1;32m    632�[0m �[38;5;66;03m# request was successfully received, understood, and accepted.�[39;00m
2026-06-18T06:36:31.9759564Z �[1;32m    633�[0m �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m (�[38;5;241m200�[39m �[38;5;241m<�[39m�[38;5;241m=�[39m code �[38;5;241m<�[39m �[38;5;241m300�[39m):
2026-06-18T06:36:31.9760533Z �[0;32m--> 634�[0m     response �[38;5;241m=�[39m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43mparent�[49m�[38;5;241;43m.�[39;49m�[43merror�[49m�[43m(�[49m
2026-06-18T06:36:31.9761924Z �[1;32m    635�[0m �[43m        �[49m�[38;5;124;43m'�[39;49m�[38;5;124;43mhttp�[39;49m�[38;5;124;43m'�[39;49m�[43m,�[49m�[43m �[49m�[43mrequest�[49m�[43m,�[49m�[43m �[49m�[43mresponse�[49m�[43m,�[49m�[43m �[49m�[43mcode�[49m�[43m,�[49m�[43m �[49m�[43mmsg�[49m�[43m,�[49m�[43m �[49m�[43mhdrs�[49m�[43m)�[49m
2026-06-18T06:36:31.9763056Z �[1;32m    637�[0m �[38;5;28;01mreturn�[39;00m response
2026-06-18T06:36:31.9763283Z 
2026-06-18T06:36:31.9763852Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:563�[0m, in �[0;36mOpenerDirector.error�[0;34m(self, proto, *args)�[0m
2026-06-18T06:36:31.9764555Z �[1;32m    561�[0m �[38;5;28;01mif�[39;00m http_err:
2026-06-18T06:36:31.9765750Z �[1;32m    562�[0m     args �[38;5;241m=�[39m (�[38;5;28mdict�[39m, �[38;5;124m'�[39m�[38;5;124mdefault�[39m�[38;5;124m'�[39m, �[38;5;124m'�[39m�[38;5;124mhttp_error_default�[39m�[38;5;124m'�[39m) �[38;5;241m+�[39m orig_args
2026-06-18T06:36:31.9766924Z �[0;32m--> 563�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43m_call_chain�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m)�[49m
2026-06-18T06:36:31.9767443Z 
2026-06-18T06:36:31.9768091Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:496�[0m, in �[0;36mOpenerDirector._call_chain�[0;34m(self, chain, kind, meth_name, *args)�[0m
2026-06-18T06:36:31.9768945Z �[1;32m    494�[0m �[38;5;28;01mfor�[39;00m handler �[38;5;129;01min�[39;00m handlers:
2026-06-18T06:36:31.9769488Z �[1;32m    495�[0m     func �[38;5;241m=�[39m �[38;5;28mgetattr�[39m(handler, meth_name)
2026-06-18T06:36:31.9770125Z �[0;32m--> 496�[0m     result �[38;5;241m=�[39m �[43mfunc�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m)�[49m
2026-06-18T06:36:31.9770880Z �[1;32m    497�[0m     �[38;5;28;01mif�[39;00m result �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T06:36:31.9771452Z �[1;32m    498�[0m         �[38;5;28;01mreturn�[39;00m result
2026-06-18T06:36:31.9771681Z 
2026-06-18T06:36:31.9772382Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/urllib/request.py:643�[0m, in �[0;36mHTTPDefaultErrorHandler.http_error_default�[0;34m(self, req, fp, code, msg, hdrs)�[0m
2026-06-18T06:36:31.9773487Z �[1;32m    642�[0m �[38;5;28;01mdef�[39;00m�[38;5;250m �[39m�[38;5;21mhttp_error_default�[39m(�[38;5;28mself�[39m, req, fp, code, msg, hdrs):
2026-06-18T06:36:31.9774409Z �[0;32m--> 643�[0m     �[38;5;28;01mraise�[39;00m HTTPError(req�[38;5;241m.�[39mfull_url, code, msg, hdrs, fp)
2026-06-18T06:36:31.9775015Z 
2026-06-18T06:36:31.9775197Z �[0;31mHTTPError�[0m: HTTP Error 404: Not Found
2026-06-18T06:36:31.9775409Z 
2026-06-18T06:36:32.2510602Z ##[error]Process completed with exit code 1.

tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb

2026-06-18T06:35:48.2484797Z Executing tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb
2026-06-18T06:35:49.2762140Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T06:36:13.8331777Z tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb failed quality control.
2026-06-18T06:36:13.8332614Z ============================== Failure ==============================
2026-06-18T06:36:13.8333213Z An error occurred while executing the following cell:
2026-06-18T06:36:13.8333684Z ------------------
2026-06-18T06:36:13.8334239Z # @markdown Download BigGAN (a generative model) and a few standard image datasets
2026-06-18T06:36:13.8335063Z 
2026-06-18T06:36:13.8335541Z ## Initially was downloaded directly
2026-06-18T06:36:13.8336081Z # biggan_model = BigGAN.from_pretrained('biggan-deep-256')
2026-06-18T06:36:13.8336775Z 
2026-06-18T06:36:13.8337061Z url = "https://osf.io/3yvhw/download"
2026-06-18T06:36:13.8337443Z fname = "biggan_deep_256"
2026-06-18T06:36:13.8337845Z r = requests.get(url, allow_redirects=True)
2026-06-18T06:36:13.8338234Z with open(fname, 'wb') as fd:
2026-06-18T06:36:13.8338614Z   fd.write(r.content)
2026-06-18T06:36:13.8338832Z 
2026-06-18T06:36:13.8339075Z biggan_model = torch.load(fname)
2026-06-18T06:36:13.8339404Z ------------------
2026-06-18T06:36:13.8339621Z 
2026-06-18T06:36:13.8339626Z 
2026-06-18T06:36:13.8340240Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T06:36:13.8340936Z �[0;31mUnpicklingError�[0m                           Traceback (most recent call last)
2026-06-18T06:36:13.8341511Z Cell �[0;32mIn[14], line 12�[0m
2026-06-18T06:36:13.8342275Z �[1;32m      9�[0m �[38;5;28;01mwith�[39;00m �[38;5;28mopen�[39m(fname, �[38;5;124m'�[39m�[38;5;124mwb�[39m�[38;5;124m'�[39m) �[38;5;28;01mas�[39;00m fd:
2026-06-18T06:36:13.8343074Z �[1;32m     10�[0m   fd�[38;5;241m.�[39mwrite(r�[38;5;241m.�[39mcontent)
2026-06-18T06:36:13.8343890Z �[0;32m---> 12�[0m biggan_model �[38;5;241m=�[39m �[43mtorch�[49m�[38;5;241;43m.�[39;49m�[43mload�[49m�[43m(�[49m�[43mfname�[49m�[43m)�[49m
2026-06-18T06:36:13.8344451Z 
2026-06-18T06:36:13.8345474Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/serialization.py:1578�[0m, in �[0;36mload�[0;34m(f, map_location, pickle_module, weights_only, mmap, **pickle_load_args)�[0m
2026-06-18T06:36:13.8347060Z �[1;32m   1570�[0m                 �[38;5;28;01mreturn�[39;00m _load(
2026-06-18T06:36:13.8347722Z �[1;32m   1571�[0m                     opened_zipfile,
2026-06-18T06:36:13.8348338Z �[1;32m   1572�[0m                     map_location,
2026-06-18T06:36:13.8348910Z �[0;32m   (...)�[0m
2026-06-18T06:36:13.8349524Z �[1;32m   1575�[0m                     �[38;5;241m*�[39m�[38;5;241m*�[39mpickle_load_args,
2026-06-18T06:36:13.8349981Z �[1;32m   1576�[0m                 )
2026-06-18T06:36:13.8350596Z �[1;32m   1577�[0m             �[38;5;28;01mexcept�[39;00m pickle�[38;5;241m.�[39mUnpicklingError �[38;5;28;01mas�[39;00m e:
2026-06-18T06:36:13.8351664Z �[0;32m-> 1578�[0m                 �[38;5;28;01mraise�[39;00m pickle�[38;5;241m.�[39mUnpicklingError(_get_wo_message(�[38;5;28mstr�[39m(e))) �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T06:36:13.8352472Z �[1;32m   1579�[0m         �[38;5;28;01mreturn�[39;00m _load(
2026-06-18T06:36:13.8352849Z �[1;32m   1580�[0m             opened_zipfile,
2026-06-18T06:36:13.8353189Z �[1;32m   1581�[0m             map_location,
2026-06-18T06:36:13.8353482Z �[0;32m   (...)�[0m
2026-06-18T06:36:13.8353831Z �[1;32m   1584�[0m             �[38;5;241m*�[39m�[38;5;241m*�[39mpickle_load_args,
2026-06-18T06:36:13.8354221Z �[1;32m   1585�[0m         )
2026-06-18T06:36:13.8354519Z �[1;32m   1586�[0m �[38;5;28;01mif�[39;00m mmap:
2026-06-18T06:36:13.8354719Z 
2026-06-18T06:36:13.8355398Z �[0;31mUnpicklingError�[0m: Weights only load failed. This file can still be loaded, to do so you have two options, �[1mdo those steps only if you trust the source of the checkpoint�[0m. 
2026-06-18T06:36:13.8357260Z 	(1) In PyTorch 2.6, we changed the default value of the `weights_only` argument in `torch.load` from `False` to `True`. Re-running `torch.load` with `weights_only` set to `False` will likely succeed, but it can result in arbitrary code execution. Do it only if you got the file from a trusted source.
2026-06-18T06:36:13.8358646Z 	(2) Alternatively, to load with `weights_only=True` please check the recommended steps in the following error message.
2026-06-18T06:36:13.8360620Z 	WeightsUnpickler error: Unsupported global: GLOBAL pytorch_pretrained_biggan.model.BigGAN was not an allowed global by default. Please use `torch.serialization.add_safe_globals([pytorch_pretrained_biggan.model.BigGAN])` or the `torch.serialization.safe_globals([pytorch_pretrained_biggan.model.BigGAN])` context manager to allowlist this global if you trust this class/function.
2026-06-18T06:36:13.8362128Z 
2026-06-18T06:36:13.8362636Z Check the documentation of torch.load to learn more about types accepted by default with weights_only https://pytorch.org/docs/stable/generated/torch.load.html.
2026-06-18T06:36:13.8363257Z 
2026-06-18T06:36:14.0012567Z ##[error]Process completed with exit code 1.

tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial2.ipynb

2026-06-18T06:36:57.3920764Z ============================== Failure ==============================
2026-06-18T06:36:57.3921552Z An error occurred while executing the following cell:
2026-06-18T06:36:57.3922414Z ------------------
2026-06-18T06:36:57.3923436Z # Unlike _some_ code-generator models on the market, we'll limit our training data by license :)
2026-06-18T06:36:57.3924248Z dataset = load_dataset(
2026-06-18T06:36:57.3924570Z     "codeparrot/github-code",
2026-06-18T06:36:57.3924872Z     streaming=True,
2026-06-18T06:36:57.3925125Z     split="train",
2026-06-18T06:36:57.3925382Z     languages=["JavaScript"],
2026-06-18T06:36:57.3925698Z     licenses=["mit", "isc", "apache-2.0"],
2026-06-18T06:36:57.3926042Z     trust_remote_code=True,
2026-06-18T06:36:57.3926319Z )
2026-06-18T06:36:57.3926632Z # Print the schema of the first example from the training set:
2026-06-18T06:36:57.3927138Z print({k: type(v) for k, v in next(iter(dataset)).items()})
2026-06-18T06:36:57.3927527Z ------------------
2026-06-18T06:36:57.3927682Z 
2026-06-18T06:36:57.3927783Z ----- stderr -----
2026-06-18T06:36:57.3928079Z `trust_remote_code` is not supported anymore.
2026-06-18T06:36:57.3928826Z Please check that the Hugging Face dataset 'codeparrot/github-code' isn't based on a loading script and remove `trust_remote_code`.
2026-06-18T06:36:57.3929933Z If the dataset is based on a loading script, please ask the dataset author to remove it and convert it to a standard format like Parquet.
2026-06-18T06:36:57.3930646Z ------------------
2026-06-18T06:36:57.3930799Z 
2026-06-18T06:36:57.3931300Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T06:36:57.3932280Z �[0;31mRuntimeError�[0m                              Traceback (most recent call last)
2026-06-18T06:36:57.3932810Z Cell �[0;32mIn[43], line 2�[0m
2026-06-18T06:36:57.3933568Z �[1;32m      1�[0m �[38;5;66;03m# Unlike _some_ code-generator models on the market, we'll limit our training data by license :)�[39;00m
2026-06-18T06:36:57.3934407Z �[0;32m----> 2�[0m dataset �[38;5;241m=�[39m �[43mload_dataset�[49m�[43m(�[49m
2026-06-18T06:36:57.3935103Z �[1;32m      3�[0m �[43m    �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mcodeparrot/github-code�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m
2026-06-18T06:36:57.3935870Z �[1;32m      4�[0m �[43m    �[49m�[43mstreaming�[49m�[38;5;241;43m=�[39;49m�[38;5;28;43;01mTrue�[39;49;00m�[43m,�[49m
2026-06-18T06:36:57.3936681Z �[1;32m      5�[0m �[43m    �[49m�[43msplit�[49m�[38;5;241;43m=�[39;49m�[38;5;124;43m"�[39;49m�[38;5;124;43mtrain�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m
2026-06-18T06:36:57.3937695Z �[1;32m      6�[0m �[43m    �[49m�[43mlanguages�[49m�[38;5;241;43m=�[39;49m�[43m[�[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mJavaScript�[39;49m�[38;5;124;43m"�[39;49m�[43m]�[49m�[43m,�[49m
2026-06-18T06:36:57.3939307Z �[1;32m      7�[0m �[43m    �[49m�[43mlicenses�[49m�[38;5;241;43m=�[39;49m�[43m[�[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mmit�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m�[43m �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43misc�[39;49m�[38;5;124;43m"�[39;49m�[43m,�[49m�[43m �[49m�[38;5;124;43m"�[39;49m�[38;5;124;43mapache-2.0�[39;49m�[38;5;124;43m"�[39;49m�[43m]�[49m�[43m,�[49m
2026-06-18T06:36:57.3940646Z �[1;32m      8�[0m �[43m    �[49m�[43mtrust_remote_code�[49m�[38;5;241;43m=�[39;49m�[38;5;28;43;01mTrue�[39;49;00m�[43m,�[49m
2026-06-18T06:36:57.3941158Z �[1;32m      9�[0m �[43m)�[49m
2026-06-18T06:36:57.3941864Z �[1;32m     10�[0m �[38;5;66;03m# Print the schema of the first example from the training set:�[39;00m
2026-06-18T06:36:57.3942866Z �[1;32m     11�[0m �[38;5;28mprint�[39m({k: �[38;5;28mtype�[39m(v) �[38;5;28;01mfor�[39;00m k, v �[38;5;129;01min�[39;00m �[38;5;28mnext�[39m(�[38;5;28miter�[39m(dataset))�[38;5;241m.�[39mitems()})
2026-06-18T06:36:57.3943429Z 
2026-06-18T06:36:57.3944759Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1698�[0m, in �[0;36mload_dataset�[0;34m(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, verification_mode, keep_in_memory, save_infos, revision, token, streaming, num_proc, storage_options, **config_kwargs)�[0m
2026-06-18T06:36:57.3946240Z �[1;32m   1693�[0m verification_mode �[38;5;241m=�[39m VerificationMode(
2026-06-18T06:36:57.3947496Z �[1;32m   1694�[0m     (verification_mode �[38;5;129;01mor�[39;00m VerificationMode�[38;5;241m.�[39mBASIC_CHECKS) �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m save_infos �[38;5;28;01melse�[39;00m VerificationMode�[38;5;241m.�[39mALL_CHECKS
2026-06-18T06:36:57.3948628Z �[1;32m   1695�[0m )
2026-06-18T06:36:57.3948982Z �[1;32m   1697�[0m �[38;5;66;03m# Create a dataset builder�[39;00m
2026-06-18T06:36:57.3949539Z �[0;32m-> 1698�[0m builder_instance �[38;5;241m=�[39m �[43mload_dataset_builder�[49m�[43m(�[49m
2026-06-18T06:36:57.3950167Z �[1;32m   1699�[0m �[43m    �[49m�[43mpath�[49m�[38;5;241;43m=�[39;49m�[43mpath�[49m�[43m,�[49m
2026-06-18T06:36:57.3950737Z �[1;32m   1700�[0m �[43m    �[49m�[43mname�[49m�[38;5;241;43m=�[39;49m�[43mname�[49m�[43m,�[49m
2026-06-18T06:36:57.3951341Z �[1;32m   1701�[0m �[43m    �[49m�[43mdata_dir�[49m�[38;5;241;43m=�[39;49m�[43mdata_dir�[49m�[43m,�[49m
2026-06-18T06:36:57.3952288Z �[1;32m   1702�[0m �[43m    �[49m�[43mdata_files�[49m�[38;5;241;43m=�[39;49m�[43mdata_files�[49m�[43m,�[49m
2026-06-18T06:36:57.3952955Z �[1;32m   1703�[0m �[43m    �[49m�[43mcache_dir�[49m�[38;5;241;43m=�[39;49m�[43mcache_dir�[49m�[43m,�[49m
2026-06-18T06:36:57.3953607Z �[1;32m   1704�[0m �[43m    �[49m�[43mfeatures�[49m�[38;5;241;43m=�[39;49m�[43mfeatures�[49m�[43m,�[49m
2026-06-18T06:36:57.3954293Z �[1;32m   1705�[0m �[43m    �[49m�[43mdownload_config�[49m�[38;5;241;43m=�[39;49m�[43mdownload_config�[49m�[43m,�[49m
2026-06-18T06:36:57.3955007Z �[1;32m   1706�[0m �[43m    �[49m�[43mdownload_mode�[49m�[38;5;241;43m=�[39;49m�[43mdownload_mode�[49m�[43m,�[49m
2026-06-18T06:36:57.3955664Z �[1;32m   1707�[0m �[43m    �[49m�[43mrevision�[49m�[38;5;241;43m=�[39;49m�[43mrevision�[49m�[43m,�[49m
2026-06-18T06:36:57.3956271Z �[1;32m   1708�[0m �[43m    �[49m�[43mtoken�[49m�[38;5;241;43m=�[39;49m�[43mtoken�[49m�[43m,�[49m
2026-06-18T06:36:57.3956939Z �[1;32m   1709�[0m �[43m    �[49m�[43mstorage_options�[49m�[38;5;241;43m=�[39;49m�[43mstorage_options�[49m�[43m,�[49m
2026-06-18T06:36:57.3957643Z �[1;32m   1710�[0m �[43m    �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mconfig_kwargs�[49m�[43m,�[49m
2026-06-18T06:36:57.3958125Z �[1;32m   1711�[0m �[43m�[49m�[43m)�[49m
2026-06-18T06:36:57.3958565Z �[1;32m   1713�[0m �[38;5;66;03m# Return iterable dataset in case of streaming�[39;00m
2026-06-18T06:36:57.3959027Z �[1;32m   1714�[0m �[38;5;28;01mif�[39;00m streaming:
2026-06-18T06:36:57.3959236Z 
2026-06-18T06:36:57.3960308Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1325�[0m, in �[0;36mload_dataset_builder�[0;34m(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, token, storage_options, **config_kwargs)�[0m
2026-06-18T06:36:57.3961958Z �[1;32m   1323�[0m �[38;5;28;01mif�[39;00m features �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T06:36:57.3962692Z �[1;32m   1324�[0m     features �[38;5;241m=�[39m _fix_for_backward_compatible_features(features)
2026-06-18T06:36:57.3963360Z �[0;32m-> 1325�[0m dataset_module �[38;5;241m=�[39m �[43mdataset_module_factory�[49m�[43m(�[49m
2026-06-18T06:36:57.3963902Z �[1;32m   1326�[0m �[43m    �[49m�[43mpath�[49m�[43m,�[49m
2026-06-18T06:36:57.3964428Z �[1;32m   1327�[0m �[43m    �[49m�[43mrevision�[49m�[38;5;241;43m=�[39;49m�[43mrevision�[49m�[43m,�[49m
2026-06-18T06:36:57.3965107Z �[1;32m   1328�[0m �[43m    �[49m�[43mdownload_config�[49m�[38;5;241;43m=�[39;49m�[43mdownload_config�[49m�[43m,�[49m
2026-06-18T06:36:57.3965817Z �[1;32m   1329�[0m �[43m    �[49m�[43mdownload_mode�[49m�[38;5;241;43m=�[39;49m�[43mdownload_mode�[49m�[43m,�[49m
2026-06-18T06:36:57.3966467Z �[1;32m   1330�[0m �[43m    �[49m�[43mdata_dir�[49m�[38;5;241;43m=�[39;49m�[43mdata_dir�[49m�[43m,�[49m
2026-06-18T06:36:57.3967104Z �[1;32m   1331�[0m �[43m    �[49m�[43mdata_files�[49m�[38;5;241;43m=�[39;49m�[43mdata_files�[49m�[43m,�[49m
2026-06-18T06:36:57.3967748Z �[1;32m   1332�[0m �[43m    �[49m�[43mcache_dir�[49m�[38;5;241;43m=�[39;49m�[43mcache_dir�[49m�[43m,�[49m
2026-06-18T06:36:57.3968373Z �[1;32m   1333�[0m �[43m�[49m�[43m)�[49m
2026-06-18T06:36:57.3968777Z �[1;32m   1334�[0m �[38;5;66;03m# Get dataset builder class�[39;00m
2026-06-18T06:36:57.3969445Z �[1;32m   1335�[0m builder_kwargs �[38;5;241m=�[39m dataset_module�[38;5;241m.�[39mbuilder_kwargs
2026-06-18T06:36:57.3969788Z 
2026-06-18T06:36:57.3970733Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1217�[0m, in �[0;36mdataset_module_factory�[0;34m(path, revision, download_config, download_mode, data_dir, data_files, cache_dir, **download_kwargs)�[0m
2026-06-18T06:36:57.3972465Z �[1;32m   1212�[0m             �[38;5;28;01mif�[39;00m �[38;5;28misinstance�[39m(e1, �[38;5;167;01mFileNotFoundError�[39;00m):
2026-06-18T06:36:57.3973167Z �[1;32m   1213�[0m                 �[38;5;28;01mraise�[39;00m �[38;5;167;01mFileNotFoundError�[39;00m(
2026-06-18T06:36:57.3974314Z �[1;32m   1214�[0m                     �[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find any data file at �[39m�[38;5;132;01m{�[39;00mrelative_to_absolute_path(path)�[38;5;132;01m}�[39;00m�[38;5;124m. �[39m�[38;5;124m"�[39m
2026-06-18T06:36:57.3976409Z �[1;32m   1215�[0m                     �[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find �[39m�[38;5;124m'�[39m�[38;5;132;01m{�[39;00mpath�[38;5;132;01m}�[39;00m�[38;5;124m'�[39m�[38;5;124m on the Hugging Face Hub either: �[39m�[38;5;132;01m{�[39;00m�[38;5;28mtype�[39m(e1)�[38;5;241m.�[39m�[38;5;18m__name__�[39m�[38;5;132;01m}�[39;00m�[38;5;124m: �[39m�[38;5;132;01m{�[39;00me1�[38;5;132;01m}�[39;00m�[38;5;124m"�[39m
2026-06-18T06:36:57.3977859Z �[1;32m   1216�[0m                 ) �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T06:36:57.3978544Z �[0;32m-> 1217�[0m             �[38;5;28;01mraise�[39;00m e1 �[38;5;28;01mfrom�[39;00m�[38;5;250m �[39m�[38;5;28;01mNone�[39;00m
2026-06-18T06:36:57.3979079Z �[1;32m   1218�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T06:36:57.3980287Z �[1;32m   1219�[0m     �[38;5;28;01mraise�[39;00m �[38;5;167;01mFileNotFoundError�[39;00m(�[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mCouldn�[39m�[38;5;124m'�[39m�[38;5;124mt find any data file at �[39m�[38;5;132;01m{�[39;00mrelative_to_absolute_path(path)�[38;5;132;01m}�[39;00m�[38;5;124m.�[39m�[38;5;124m"�[39m)
2026-06-18T06:36:57.3981190Z 
2026-06-18T06:36:57.3982418Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/datasets/load.py:1177�[0m, in �[0;36mdataset_module_factory�[0;34m(path, revision, download_config, download_mode, data_dir, data_files, cache_dir, **download_kwargs)�[0m
2026-06-18T06:36:57.3983455Z �[1;32m   1169�[0m �[38;5;28;01mtry�[39;00m:
2026-06-18T06:36:57.3983839Z �[1;32m   1170�[0m     api�[38;5;241m.�[39mhf_hub_download(
2026-06-18T06:36:57.3984235Z �[1;32m   1171�[0m         repo_id�[38;5;241m=�[39mpath,
2026-06-18T06:36:57.3984630Z �[1;32m   1172�[0m         filename�[38;5;241m=�[39mfilename,
2026-06-18T06:36:57.3984965Z �[0;32m   (...)�[0m
2026-06-18T06:36:57.3985358Z �[1;32m   1175�[0m         proxies�[38;5;241m=�[39mdownload_config�[38;5;241m.�[39mproxies,
2026-06-18T06:36:57.3985781Z �[1;32m   1176�[0m     )
2026-06-18T06:36:57.3986757Z �[0;32m-> 1177�[0m     �[38;5;28;01mraise�[39;00m �[38;5;167;01mRuntimeError�[39;00m(�[38;5;124mf�[39m�[38;5;124m"�[39m�[38;5;124mDataset scripts are no longer supported, but found �[39m�[38;5;132;01m{�[39;00mfilename�[38;5;132;01m}�[39;00m�[38;5;124m"�[39m)
2026-06-18T06:36:57.3987722Z �[1;32m   1178�[0m �[38;5;28;01mexcept�[39;00m EntryNotFoundError:
2026-06-18T06:36:57.3988301Z �[1;32m   1179�[0m     �[38;5;66;03m# Use the infos from the parquet export except in some cases:�[39;00m
2026-06-18T06:36:57.3989381Z �[1;32m   1180�[0m     �[38;5;28;01mif�[39;00m data_dir �[38;5;129;01mor�[39;00m data_files �[38;5;129;01mor�[39;00m (revision �[38;5;129;01mand�[39;00m revision �[38;5;241m!=�[39m �[38;5;124m"�[39m�[38;5;124mmain�[39m�[38;5;124m"�[39m):
2026-06-18T06:36:57.3990049Z 
2026-06-18T06:36:57.3990526Z �[0;31mRuntimeError�[0m: Dataset scripts are no longer supported, but found github-code.py
2026-06-18T06:36:57.3990990Z 
2026-06-18T06:36:57.6639885Z ##[error]Process completed with exit code 1.

tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb

2026-06-18T06:35:06.2802615Z Executing tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb
2026-06-18T06:35:07.2006420Z [IPKernelApp] WARNING | Kernel is running over TCP without encryption. All communication (including code and outputs) is sent in plain text and is susceptible to eavesdropping. Use IPC transport or launch with kernel manager-provisioned CurveZMQ keys to enable transport encryption.
2026-06-18T06:36:12.8998481Z tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb failed quality control.
2026-06-18T06:36:12.8999073Z ============================== Failure ==============================
2026-06-18T06:36:12.8999770Z An error occurred while executing the following cell:
2026-06-18T06:36:12.9000471Z ------------------
2026-06-18T06:36:12.9001689Z # @title Bonus 1.4: Sentiment binary-classification with likelihood of positive and negative extensions of the review 👍👎
2026-06-18T06:36:12.9002450Z 
2026-06-18T06:36:12.9002602Z # @markdown ---
2026-06-18T06:36:12.9003731Z model_name = "gpt2"  # @param ["gpt2", "gpt2-medium", "xlnet-base-cased"]
2026-06-18T06:36:12.9004482Z model = AutoModelForCausalLM.from_pretrained(model_name)
2026-06-18T06:36:12.9005023Z model.eval()
2026-06-18T06:36:12.9005432Z tokenizer = AutoTokenizer.from_pretrained(model_name)
2026-06-18T06:36:12.9006236Z # @markdown **Select a pre-trained language model to score the likelihood of extended review**
2026-06-18T06:36:12.9007015Z 
2026-06-18T06:36:12.9007423Z # @markdown *(might take some time to download the pre-trained weights for the first time)*
2026-06-18T06:36:12.9007989Z 
2026-06-18T06:36:12.9008086Z # @markdown ---
2026-06-18T06:36:12.9008492Z custom_positive_extension = "I would definitely recommend this!"  # @param {type:"string"}
2026-06-18T06:36:12.9009076Z custom_negative_extension = "I would not recommend this!"  # @param {type:"string"}
2026-06-18T06:36:12.9009735Z # @markdown **Provide custom positive and negative extensions to the review ✍️**
2026-06-18T06:36:12.9010053Z 
2026-06-18T06:36:12.9010266Z texts = [context, custom_positive_extension, custom_negative_extension]
2026-06-18T06:36:12.9010651Z encodings = tokenizer(texts)
2026-06-18T06:36:12.9010823Z 
2026-06-18T06:36:12.9011080Z positive_input_ids = torch.tensor(encodings["input_ids"][0] + encodings["input_ids"][1])
2026-06-18T06:36:12.9011732Z positive_attention_mask = torch.tensor(encodings["attention_mask"][0] + encodings["attention_mask"][1])
2026-06-18T06:36:12.9012427Z positive_label_ids = torch.tensor([-100]*len(encodings["input_ids"][0]) + encodings["input_ids"][1])
2026-06-18T06:36:12.9012924Z outputs = model(input_ids=positive_input_ids,
2026-06-18T06:36:12.9013287Z                 attention_mask=positive_attention_mask,
2026-06-18T06:36:12.9013819Z                 labels=positive_label_ids)
2026-06-18T06:36:12.9014152Z positive_extension_likelihood = -1*outputs.loss
2026-06-18T06:36:12.9014627Z print("\nLog-likelihood of positive extension = ", positive_extension_likelihood.item())
2026-06-18T06:36:12.9014973Z 
2026-06-18T06:36:12.9015224Z negative_input_ids = torch.tensor(encodings["input_ids"][0] + encodings["input_ids"][2])
2026-06-18T06:36:12.9015865Z negative_attention_mask = torch.tensor(encodings["attention_mask"][0] + encodings["attention_mask"][2])
2026-06-18T06:36:12.9016540Z negative_label_ids = torch.tensor([-100]*len(encodings["input_ids"][0]) + encodings["input_ids"][2])
2026-06-18T06:36:12.9017309Z outputs = model(input_ids=negative_input_ids,
2026-06-18T06:36:12.9017658Z                 attention_mask=negative_attention_mask,
2026-06-18T06:36:12.9017991Z                 labels=negative_label_ids)
2026-06-18T06:36:12.9018317Z negative_extension_likelihood = -1*outputs.loss
2026-06-18T06:36:12.9018800Z print("\nLog-likelihood of negative extension = ", negative_extension_likelihood.item())
2026-06-18T06:36:12.9019153Z 
2026-06-18T06:36:12.9019395Z if (positive_extension_likelihood.item() > negative_extension_likelihood.item()):
2026-06-18T06:36:12.9019936Z     print("\nPositive text-extension has greater likelihood probabilities!")
2026-06-18T06:36:12.9020500Z     print("The given review can be predicted to be POSITIVE 👍")
2026-06-18T06:36:12.9020843Z else:
2026-06-18T06:36:12.9021147Z     print("\nNegative text-extension has greater likelihood probabilities!")
2026-06-18T06:36:12.9021651Z     print("The given review can be predicted to be NEGATIVE 👎")
2026-06-18T06:36:12.9022104Z # @markdown **NOTE:** *Run this cell after setting all the fields appropriately!*
2026-06-18T06:36:12.9022399Z 
2026-06-18T06:36:12.9022629Z # @markdown **NOTE:** *Some pre-trained models might not work well with longer texts!*
2026-06-18T06:36:12.9023032Z ------------------
2026-06-18T06:36:12.9023169Z 
2026-06-18T06:36:12.9023173Z 
2026-06-18T06:36:12.9023443Z �[0;31m---------------------------------------------------------------------------�[0m
2026-06-18T06:36:12.9023972Z �[0;31mIndexError�[0m                                Traceback (most recent call last)
2026-06-18T06:36:12.9024402Z Cell �[0;32mIn[17], line 23�[0m
2026-06-18T06:36:12.9025681Z �[1;32m     21�[0m positive_attention_mask �[38;5;241m=�[39m torch�[38;5;241m.�[39mtensor(encodings[�[38;5;124m"�[39m�[38;5;124mattention_mask�[39m�[38;5;124m"�[39m][�[38;5;241m0�[39m] �[38;5;241m+�[39m encodings[�[38;5;124m"�[39m�[38;5;124mattention_mask�[39m�[38;5;124m"�[39m][�[38;5;241m1�[39m])
2026-06-18T06:36:12.9028009Z �[1;32m     22�[0m positive_label_ids �[38;5;241m=�[39m torch�[38;5;241m.�[39mtensor([�[38;5;241m-�[39m�[38;5;241m100�[39m]�[38;5;241m*�[39m�[38;5;28mlen�[39m(encodings[�[38;5;124m"�[39m�[38;5;124minput_ids�[39m�[38;5;124m"�[39m][�[38;5;241m0�[39m]) �[38;5;241m+�[39m encodings[�[38;5;124m"�[39m�[38;5;124minput_ids�[39m�[38;5;124m"�[39m][�[38;5;241m1�[39m])
2026-06-18T06:36:12.9029443Z �[0;32m---> 23�[0m outputs �[38;5;241m=�[39m �[43mmodel�[49m�[43m(�[49m�[43minput_ids�[49m�[38;5;241;43m=�[39;49m�[43mpositive_input_ids�[49m�[43m,�[49m
2026-06-18T06:36:12.9030325Z �[1;32m     24�[0m �[43m                �[49m�[43mattention_mask�[49m�[38;5;241;43m=�[39;49m�[43mpositive_attention_mask�[49m�[43m,�[49m
2026-06-18T06:36:12.9031051Z �[1;32m     25�[0m �[43m                �[49m�[43mlabels�[49m�[38;5;241;43m=�[39;49m�[43mpositive_label_ids�[49m�[43m)�[49m
2026-06-18T06:36:12.9031856Z �[1;32m     26�[0m positive_extension_likelihood �[38;5;241m=�[39m �[38;5;241m-�[39m�[38;5;241m1�[39m�[38;5;241m*�[39moutputs�[38;5;241m.�[39mloss
2026-06-18T06:36:12.9032977Z �[1;32m     27�[0m �[38;5;28mprint�[39m(�[38;5;124m"�[39m�[38;5;130;01m\n�[39;00m�[38;5;124mLog-likelihood of positive extension = �[39m�[38;5;124m"�[39m, positive_extension_likelihood�[38;5;241m.�[39mitem())
2026-06-18T06:36:12.9033570Z 
2026-06-18T06:36:12.9034276Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/nn/modules/module.py:1778�[0m, in �[0;36mModule._wrapped_call_impl�[0;34m(self, *args, **kwargs)�[0m
2026-06-18T06:36:12.9035742Z �[1;32m   1776�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_compiled_call_impl(�[38;5;241m*�[39margs, �[38;5;241m*�[39m�[38;5;241m*�[39mkwargs)  �[38;5;66;03m# type: ignore[misc]�[39;00m
2026-06-18T06:36:12.9036475Z �[1;32m   1777�[0m �[38;5;28;01melse�[39;00m:
2026-06-18T06:36:12.9037640Z �[0;32m-> 1778�[0m     �[38;5;28;01mreturn�[39;00m �[38;5;28;43mself�[39;49m�[38;5;241;43m.�[39;49m�[43m_call_impl�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m,�[49m�[43m �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mkwargs�[49m�[43m)�[49m
2026-06-18T06:36:12.9038302Z 
2026-06-18T06:36:12.9038966Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/torch/nn/modules/module.py:1789�[0m, in �[0;36mModule._call_impl�[0;34m(self, *args, **kwargs)�[0m
2026-06-18T06:36:12.9039923Z �[1;32m   1784�[0m �[38;5;66;03m# If we don't have any hooks, we want to skip the rest of the logic in�[39;00m
2026-06-18T06:36:12.9040523Z �[1;32m   1785�[0m �[38;5;66;03m# this function, and just call forward.�[39;00m
2026-06-18T06:36:12.9041858Z �[1;32m   1786�[0m �[38;5;28;01mif�[39;00m �[38;5;129;01mnot�[39;00m (�[38;5;28mself�[39m�[38;5;241m.�[39m_backward_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_backward_pre_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_forward_hooks �[38;5;129;01mor�[39;00m �[38;5;28mself�[39m�[38;5;241m.�[39m_forward_pre_hooks
2026-06-18T06:36:12.9043149Z �[1;32m   1787�[0m         �[38;5;129;01mor�[39;00m _global_backward_pre_hooks �[38;5;129;01mor�[39;00m _global_backward_hooks
2026-06-18T06:36:12.9043896Z �[1;32m   1788�[0m         �[38;5;129;01mor�[39;00m _global_forward_hooks �[38;5;129;01mor�[39;00m _global_forward_pre_hooks):
2026-06-18T06:36:12.9044893Z �[0;32m-> 1789�[0m     �[38;5;28;01mreturn�[39;00m �[43mforward_call�[49m�[43m(�[49m�[38;5;241;43m*�[39;49m�[43margs�[49m�[43m,�[49m�[43m �[49m�[38;5;241;43m*�[39;49m�[38;5;241;43m*�[39;49m�[43mkwargs�[49m�[43m)�[49m
2026-06-18T06:36:12.9045667Z �[1;32m   1791�[0m result �[38;5;241m=�[39m �[38;5;28;01mNone�[39;00m
2026-06-18T06:36:12.9046316Z �[1;32m   1792�[0m called_always_called_hooks �[38;5;241m=�[39m �[38;5;28mset�[39m()
2026-06-18T06:36:12.9046764Z 
2026-06-18T06:36:12.9048570Z File �[0;32m/opt/hostedtoolcache/Python/3.10.20/x64/lib/python3.10/site-packages/transformers/models/gpt2/modeling_gpt2.py:1092�[0m, in �[0;36mGPT2LMHeadModel.forward�[0;34m(self, input_ids, past_key_values, cache_position, attention_mask, token_type_ids, position_ids, head_mask, inputs_embeds, encoder_hidden_states, encoder_attention_mask, labels, use_cache, output_attentions, output_hidden_states, return_dict, logits_to_keep, **kwargs)�[0m
2026-06-18T06:36:12.9050596Z �[1;32m   1089�[0m     hidden_states �[38;5;241m=�[39m hidden_states�[38;5;241m.�[39mto(�[38;5;28mself�[39m�[38;5;241m.�[39mlm_head�[38;5;241m.�[39mweight�[38;5;241m.�[39mdevice)
2026-06-18T06:36:12.9051913Z �[1;32m   1091�[0m slice_indices �[38;5;241m=�[39m �[38;5;28mslice�[39m(�[38;5;241m-�[39mlogits_to_keep, �[38;5;28;01mNone�[39;00m) �[38;5;28;01mif�[39;00m �[38;5;28misinstance�[39m(logits_to_keep, �[38;5;28mint�[39m) �[38;5;28;01melse�[39;00m logits_to_keep
2026-06-18T06:36:12.9053289Z �[0;32m-> 1092�[0m logits �[38;5;241m=�[39m �[38;5;28mself�[39m�[38;5;241m.�[39mlm_head(�[43mhidden_states�[49m�[43m[�[49m�[43m:�[49m�[43m,�[49m�[43m �[49m�[43mslice_indices�[49m�[43m,�[49m�[43m �[49m�[43m:�[49m�[43m]�[49m)
2026-06-18T06:36:12.9054107Z �[1;32m   1094�[0m loss �[38;5;241m=�[39m �[38;5;28;01mNone�[39;00m
2026-06-18T06:36:12.9054720Z �[1;32m   1095�[0m �[38;5;28;01mif�[39;00m labels �[38;5;129;01mis�[39;00m �[38;5;129;01mnot�[39;00m �[38;5;28;01mNone�[39;00m:
2026-06-18T06:36:12.9055281Z �[1;32m   1096�[0m     �[38;5;66;03m# Flatten the tokens�[39;00m
2026-06-18T06:36:12.9055512Z 
2026-06-18T06:36:12.9055741Z �[0;31mIndexError�[0m: too many indices for tensor of dimension 2
2026-06-18T06:36:12.9056141Z 
2026-06-18T06:36:13.1232938Z ##[error]Process completed with exit code 1.

@github-actions

Copy link
Copy Markdown

Follow-up PR Created

A follow-up PR has been created for the notebooks that failed to process:

Follow-up PR: #1040
Branch: reprocess-pr1039-20260618072507

The failed notebooks have been reverted to their main branch versions in this PR.
Once this PR is merged, the follow-up PR can be used to reprocess the failed notebooks independently.

@iamzoltan iamzoltan left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@iamzoltan
iamzoltan merged commit 0b4239b into main Jun 18, 2026
iamzoltan added a commit that referenced this pull request Jun 18, 2026
…0618072507

Reprocess: Failed notebooks from PR #1039
cindyhfls pushed a commit to cindyhfls/course-content-dl that referenced this pull request Jun 21, 2026
These notebooks failed to process in the original PR and need reprocessing:
- tutorials/W2D2_Convnets/W2D2_Tutorial1.ipynb
- tutorials/W2D2_Convnets/W2D2_Tutorial3.ipynb
- tutorials/W2D3_GenerativeModelsAndDeepLearningDiscussion1/W2D3_Tutorial1.ipynb
- tutorials/W2D5_TimeSeriesAndNaturalLanguageProcessing/W2D5_Tutorial2.ipynb
- tutorials/W3D1_AttentionAndTransformers/W3D1_Tutorial2.ipynb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants