BlinkDL / RWKV-LM

RWKV is an RNN with transformer-level LLM performance. It can be directly trained like a GPT (parallelizable). So it's combining the best of RNN and transformer - great performance, fast inference, saves VRAM, fast training, "infinite" ctx_len, and free sentence embedding.
Apache License 2.0
12.05k stars 827 forks source link

Loading extension module wkv_512... Fail #169

Closed anonymitynewbie closed 11 months ago

anonymitynewbie commented 11 months ago

I chaged the train.py to my model , and ran "model = RWKV(args)". when "Loading extension module wkv_512...", ImportError: DLL load failed while importing wkv_512: 找不到指定的模块。 Need I download the file ? or where can i find it?

BlinkDL commented 11 months ago

use v4neo/train.py and run in ubuntu first

anonymitynewbie commented 11 months ago

i run it in Windows' Pycharm, i find that it did not generate .pyd file causing "ImportError: DLL load failed while importing wkv: 找不到指定的模块。" how can i solve this ?

BlinkDL commented 11 months ago

How to build in Linux:

export PATH=/usr/local/cuda/bin:$PATH export LD_LIBRARY_PATH=/usr/local/cuda/lib64:$LD_LIBRARY_PATH

How to build in win:

Install VS2022 build tools (https://aka.ms/vs/17/release/vs_BuildTools.exe select Desktop C++). Reinstall CUDA 11.7 (install VC++ extensions). Run train.py in "x64 native tools command prompt".