The batch dimension is missing in your input.
Usually you would iterate over the DataLoader, not the Dataset.
If you still want to use your Dataset (for whatever reasons), you could unsqueeze your data using:
inputs = inputs.unsqueeze(0)
outputs = net(inputs)

However, I would recommend to use the DataLoader to use multiple processes, shuffling, batching etc.:
for i, data in enumerate(train_data_loader):
    ...