# DLS 2 Week 1: All Exercises --\> Bug Report

**URL:** <https://dlai.staged-by-discourse.com/t/dls-2-week-1-all-exercises-bug-report/893002>\
**Category:** Improving Deep Neural Networks: Hyperparameter tun\
**Tags:** week-module-1, coursera-platform\
**Created:** [June 20, 2026, 7:42pm UTC](https://dlai.staged-by-discourse.com/t/dls-2-week-1-all-exercises-bug-report/893002 "2026-06-20T19:42:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sasankalan](https://sea1.discourse-cdn.com/dlaistaging/user_avatar/dlai.staged-by-discourse.com/sasankalan/32/140690_2.png) [@sasankalan](https://dlai.staged-by-discourse.com/u/sasankalan)\
**Post date:** [June 20, 2026, 7:42pm UTC](https://dlai.staged-by-discourse.com/t/dls-2-week-1-all-exercises-bug-report/893002/1 "2026-06-20T19:42:08Z")

</div>

\*\*imp: This bug occurs only when you run the notebook locally.  
\*\*  
file:line: reg\_utils.py:203  
bug: dtype = np.int  
fix: dtype = int  
\*\*  
\*\*  
File …/W1A2/reg\_utils.py:203, in predict(X, y, parameters)  
191 _“”"_  
192 _This function is used to predict the results of a n-layer neural network._  
193  
(…) 199 _p – predictions for the given dataset X_  
200 _“”"_  
202 m = X.shape[1]  
 → [203](https://file+.vscode-resource.vscode-cdn.net/Users/sasanka/Work_OffLine/ML/CourseraDL2/Exercises_2026/W1A2/~/Work_OffLine/ML/CourseraDL2/Exercises_2026/W1A2/reg_utils.py:203) p = np.zeros((1,m), dtype = np.int)  
205 # Forward propagation  
206 a3, caches = forward\_propagation(X, parameters)

---

<div class="post-metadata">

**Author:** ![rmwkwok](https://sea1.discourse-cdn.com/dlaistaging/user_avatar/dlai.staged-by-discourse.com/rmwkwok/32/126977_2.png) [@rmwkwok](https://dlai.staged-by-discourse.com/u/rmwkwok)\
**Post date:** [June 21, 2026, 12:23am UTC](https://dlai.staged-by-discourse.com/t/dls-2-week-1-all-exercises-bug-report/893002/2 "2026-06-21T00:23:34Z")

</div>

Hey @sasankalan,

That should be a deprecation:

 ![image](https://global.discourse-cdn.com/dlaistaging/original/3X/7/f/7f6a7d752bed270b80515edced1dd308557bb3c0.png)

Your fix is exactly the recommended way.

Cheers,  
Raymond

---

<div class="post-metadata">

**Author:** ![paulinpaloalto](https://sea1.discourse-cdn.com/dlaistaging/user_avatar/dlai.staged-by-discourse.com/paulinpaloalto/32/187_2.png) [@paulinpaloalto](https://dlai.staged-by-discourse.com/u/paulinpaloalto)\
**Post date:** [June 22, 2026, 12:32am UTC](https://dlai.staged-by-discourse.com/t/dls-2-week-1-all-exercises-bug-report/893002/3 "2026-06-22T00:32:21Z")

</div>

When you run notebooks locally, there is no guarantee that they will work unless you also make sure that you are running the same versions of the multitude of packages that they use. Most of these courses were republished in Spring of 2021 and there have been lots of changes in the whole python/ML ecosystem since then. There is no easy way to do this, but [here is a thread](http://dlai.staged-by-discourse.com/t/dls-1-my-own-project-in-pycharm/74781/4) to get you started down that long and winding road.

---

<div class="post-metadata">

**Author:** ![paulinpaloalto](https://sea1.discourse-cdn.com/dlaistaging/user_avatar/dlai.staged-by-discourse.com/paulinpaloalto/32/187_2.png) [@paulinpaloalto](https://dlai.staged-by-discourse.com/u/paulinpaloalto)\
**Post date:** [June 22, 2026, 12:36am UTC](https://dlai.staged-by-discourse.com/t/dls-2-week-1-all-exercises-bug-report/893002/4 "2026-06-22T00:36:18Z")

</div>

Here’s [another thread](http://dlai.staged-by-discourse.com/t/running-notebooks-locally-tests-failing-due-to-version-diffs/502862/5) (read forward from that post) that is relevant.

And [here’s yet another.](http://dlai.staged-by-discourse.com/t/tips-to-work-on-a-local-environment/187108)
