I’m trying to run this text classifier (https://github.com/xiayandi/Pytorch_text_classification 2) but I don’t know how to solve this error.  I am not familiar with pytorch.
def _train_loop(train_loader,
                test_loader,
                model,
                criterion,
                optimizer,
                n_epoch,
                print_every,
                eval_every,
                model_file):
    step = 0
    best_result = 0.
    best_step = 0
    best_epoch = 0
    model.train()
    print ("Iteration starts...")
    for epoch in range(1, n_epoch + 1):
        print ("Epoch#{}".format(epoch))
        for btch_dix, batch in enumerate(train_loader, 1):#error on this line

error:
 File "main.py", line 50, in <module>
    eval_every=500)
  File "/home/SharedStorage2/visionClass/baxelrad/Downloads/as4/Pytorch_text_classification/train_classifier.py", line 140, in train
    model_file=model_file)
  File "/home/SharedStorage2/visionClass/baxelrad/Downloads/as4/Pytorch_text_classification/train_classifier.py", line 42, in _train_loop
    for btch_dix, batch in enumerate(train_loader, 1):
  File "/usr/local/lib/python3.5/dist-packages/torch/utils/data/dataloader.py", line 637, in __next__
    return self._process_next_batch(batch)
  File "/usr/local/lib/python3.5/dist-packages/torch/utils/data/dataloader.py", line 658, in _process_next_batch
    raise batch.exc_type(batch.exc_msg)
TypeError: Traceback (most recent call last):
  File "/usr/local/lib/python3.5/dist-packages/torch/utils/data/dataloader.py", line 138, in _worker_loop
    samples = collate_fn([dataset[i] for i in batch_indices])
  File "/usr/local/lib/python3.5/dist-packages/torch/utils/data/dataloader.py", line 232, in default_collate
    return [default_collate(samples) for samples in transposed]
  File "/usr/local/lib/python3.5/dist-packages/torch/utils/data/dataloader.py", line 232, in <listcomp>
    return [default_collate(samples) for samples in transposed]
  File "/usr/local/lib/python3.5/dist-packages/torch/utils/data/dataloader.py", line 234, in default_collate
    raise TypeError((error_msg.format(type(batch[0]))))
TypeError: batch must contain tensors, numbers, dicts or lists; found <class 'h5py._hl.dataset.Dataset'>

Thank you in advance.