yzhangcs / parser

:rocket: State-of-the-art parsers for natural language.
https://parser.yzhang.site/
MIT License
827 stars 139 forks source link

torch>=1.7.0 (GPU version) support #62

Closed KoichiYasuoka closed 3 years ago

KoichiYasuoka commented 3 years ago

Avoiding https://github.com/pytorch/pytorch/issues/43227

yzhangcs commented 3 years ago

@KoichiYasuoka Thanks.

KoichiYasuoka commented 3 years ago

Thank you @yzhangcs , and please consider to update PYPI version.

yzhangcs commented 3 years ago

@KoichiYasuoka It's OK now. The version number is modified since +number is not allowed on PYPI. I'm sorry for my delay.

KoichiYasuoka commented 3 years ago

Thank you again @yzhangcs , but well, do you mean supar 1.0.0a1? In PyPI rules 1.0.0a1 is a pre-release of 1.0.0, so 1.0.0a1 is treated as older than 1.0.0. How about to use version 1.0.1 (minor fix) instead?

yzhangcs commented 3 years ago

@KoichiYasuoka Fixed. Thanks.

LouChao98 commented 3 years ago

The change in char_lstm.py should be rechecked. char_mask.device is forced to be cpu, which results in RuntimeError:Tensor for artument #2 'mask' is on CPU, but expected it to be on GPU at line 68.

yzhangcs commented 3 years ago

@LouChao98 Thanks for your reminding.