Hi Folks:
Some of my tests fail. I initially get:
(DeviceArray([[49, 50, 51, 52, 53, 54, 55, 56, 57, 1],
[50, 51, 52, 53, 54, 55, 56, 57, 48, 1]], dtype=int32),
DeviceArray([[49, 50, 51, 52, 53, 54, 55, 56, 57, 1],
[50, 51, 52, 53, 54, 55, 56, 57, 48, 1]], dtype=int32),
DeviceArray([1, 1], dtype=int32))
Expected output
(DeviceArray([[49, 50, 51, 52, 53, 54, 55, 56, 57, 1],
[50, 51, 52, 53, 54, 55, 56, 57, 48, 1]], dtype=int32),
DeviceArray([[49, 50, 51, 52, 53, 54, 55, 56, 57, 1],
[50, 51, 52, 53, 54, 55, 56, 57, 48, 1]], dtype=int32),
DeviceArray([[1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
[1, 1, 1, 1, 1, 1, 1, 1, 1, 1]], dtype=int32))
in the unit tests
Element with index 2 in the output tuple has incorrect shape. It should be (batch_size, max_length).
Expected (2, 10).
Got (2,).
Element with index 2 in the output tuple has incorrect shape. It should be (batch_size, max_length).
Expected [[1 1 1 1 1 1 1 1 1 1]
[1 1 1 1 1 1 1 1 1 1]].
Got [1 1].
I am assuming something went wrong with the third element, the mask_np_arr. However I am
sure what to look out for. I use np.where() to create the mask.For some reason, when
I used (tensor_pad a-condition).astype(int), this gave an error. When I perform the same
on my machine (python 3.8), it works.
Any help would be appreciated.
Cheers,
Drew