Hi there,
I am confused whether mask
is supposed to be boolean or numeric β
The in notebook example, as well as code in rest the assignment (particularly UNQ_C3) implies it should be boolean, but the unit test code for UNQ_C1 supplies a numeric mask:

Please let me know if I have caught a bug, or whether I am misunderstanding the instructions.
Thank you 
Followup:
I am now wondering if the unit tests for UNC_C1 are perhaps outdated.
My function perfectly matches the output in the notebook:
And I now notice that the expected
outputs in the unit tests are a bit too perfect (see image in original post)β¦
I thought attention was supposed to be a weighted sum of the key/value embeddings that βmatchβ the query embeddings.
From this understanding one would expect the output numbers to be less perfect than β1.0β, β2.0β, etc.
Am I missing something here? I would love some clarity, thank you!
FINAL UPDATE:
I ended up passing the assignment with a 90% score!
Turns out ignoring the failing unit test for UNC_C1 had no downstream effects, which leads me to believe the unit tests for that task might be a bit off.
It would be great for the course staff to look into this issue.
Thanks again!
1 Like