AttributeError: module 'trax.data' has no attribute 'inputs'

AttributeError Traceback (most recent call last)
in
7
8 # Create training data, mask pad id=35180 for training.
----> 9 train_generator = trax.data.inputs.add_loss_weights(
10 data_generator(batch_size, t_sentences, t_labels, vocab[’’], True),
11 id_to_mask=vocab[’’])

AttributeError: module ‘trax.data’ has no attribute ‘inputs’

Hi vijaya_kumar_eyunni,

My guess would be that there was a problem with your code for the data_generator. I hope you were able to resolve this. If not, let me know and I can have a look at your code.

vijaya_kumar_eyunni,

I encountered the same issue. It’s resolved when I restart the kernel, refresh the page.

I had the same issue and resolved it by rebooting the server (top-right Help menu, “Reboot Server”)