@Hyer_Chen,
No, I haven’t use the above-mentioned repository. You can report your error in the Issue section of that repository. Maybe the below repository also be interesting for you:

  
      
      GitHub
  
  
    

ebetica/autogradpp 95

autogradpp - Direct C++ Interface to PyTorch


  
  
    
    
  
  


However, I didn’t use that again!
Note that in the near future, maybe the PyTorch team release a PyTorch like C++ Interface. You can visit the below links:
1- https://github.com/pytorch/pytorch/issues/3335 82
2- https://github.com/caffe2/caffe2/issues/2439 28
3- https://github.com/pytorch/pytorch/issues/6032 39