morningmoni / HiLAP

Code for paper "Hierarchical Text Classification with Reinforced Label Assignment" EMNLP 2019
140 stars 34 forks source link

Question about ohcnn-fast\han and table in your paper #2

Closed SannyZhou closed 4 years ago

SannyZhou commented 5 years ago

Thanks for your sharing. I am trying on replicating your experiment on RCV1. However, I meet some problem with base_model of ohcnn-fast and han. The traceback is as follows. OHCNN_fast.py", line 45, in forward x = F.avg_pool1d(x, int(x.size(2) / self.n_pool)).view(x_embed.size(0), self.n_pool * self.Co) # (N,n_pool * Co) RuntimeError: invalid argument 2: size '[32 x 10000]' is invalid for input with 352000 elements at /pytorch/torch/lib/TH/THStorage.c:41 /HAN.py", line 31, in batch_matmul _s = torch.mm(seq[i], weight) RuntimeError: matrix and matrix expected at /pytorch/torch/lib/THC/generic/THCTensorMathBlas.cu:241

What' more, I am also concerned about the performance of HMCN in Table 2 & 3. What is its experiment configure?

morningmoni commented 5 years ago

Sorry for the late reply. I am quite occupied these days...

  1. I can take a look at the code if you haven't fixed it.
  2. For HMCN, we use TFIDF features as input. Other parameters generally follow the original paper.