Hi,i am new to pytorch from tensorflow.I get a problem when using pytorch.
Below is the init(self, n_visible,n_hidden,dropout_) function.An Auto Encoder
self.fc1 = nn.Linear(n_visible,n_hidden)
self.fc2 = nn.Linear(n_hidden,n_visible)
self.dropout = nn.Dropout(dropout_)

Below is the forward(self,x)  function
print("type:", x.type())
Encoder = F.sigmoid(self.fc1(x))
dropout_hidden = self.dropout(Encoder)
Decoder = F.sigmoid(self.fc2(dropout_hidden))

Below is the trace
type: torch.cuda.FloatTensor
Traceback (most recent call last):
  File "/home/zhanafeng/PycharmProjects/CollaborativeDeepLearning/main.py", line 147, in <module>
    num_items,num_voca,itr,dipen_activation,pretrain_input,args)
  File "/home/zhanafeng/PycharmProjects/CollaborativeDeepLearning/SDAE.py", line 101, in pretrain
    Encoder,Decoder = model(train_loader)
  File "/home/zhanafeng/anaconda3/lib/python3.6/site-packages/torch/nn/modules/module.py", line 477, in __call__
    result = self.forward(*input, **kwargs)
  File "/home/zhanafeng/PycharmProjects/CollaborativeDeepLearning/SDAE.py", line 35, in forward
    print("type:", x.type())
AttributeError: 'DataLoader' object has no attribute 'type'