I/INFO input tensor: [3118]
I/INFO input tensor shape: [1, 1, 1]
I/INFO input length tensor shape: [1]
I/INFO input tensor test: [3118]
E/AndroidRuntime: FATAL EXCEPTION: Thread-2
Process: com.example.seq2seqnmt, PID: 23035
com.facebook.jni.CppException: Expected batch2_sizes[0] == bs && batch2_sizes[1] == contraction_size to be true, but got false.  (Could this error message be improved?  If so, please report an enhancement request to PyTorch.)
  debug_handle:-1
  
Exception raised from bmm_out_or_baddbmm_ at ../aten/src/ATen/native/LinearAlgebra.cpp:1206 (most recent call first):
(no backtrace available)
    at org.pytorch.LiteNativePeer.forward(Native Method)
    at org.pytorch.Module.forward(Module.java:52)
    at org.pytorch.demo.seq2seqnmt.MainActivity.translate(MainActivity.java:220)
    at org.pytorch.demo.seq2seqnmt.MainActivity.run(MainActivity.java:108)
    at java.lang.Thread.run(Thread.java:764)

D/EGL_emulation: eglMakeCurrent: 0xa88d0fe0: ver 3 0 (tinfo 0x982291e0)
E/SpellCheckerSession: ignoring processOrEnqueueTask due to unexpected mState=TASK_CLOSE scp.mWhat=TASK_CLOSE

Thank you for your reply! This is all the log output I get.