ai-forever / ru-gpts

Russian GPT3 models.
Apache License 2.0
2.08k stars 444 forks source link

Unable to run example code #39

Closed asimaranov closed 3 years ago

asimaranov commented 3 years ago

Unable to run interference. I'm trying to run the example code from readme. This error appears

user@2ae38096b475:/ru-gpts$ python3 gpt_bot.py
Traceback (most recent call last):
  File "gpt_bot.py", line 4, in <module>
    from generation_wrapper import RuGPT3XL
  File "gw/generation_wrapper.py", line 13, in <module>
    import mpu
  File "/ru-gpts/mpu/__init__.py", line 50, in <module>
    from .transformer import BertParallelSelfAttention
  File "/ru-gpts/mpu/transformer.py", line 34, in <module>
    from torch_blocksparse_cpp_utils import make_layout
ModuleNotFoundError: No module named 'torch_blocksparse_cpp_utils'

Deepspeed report:

user@2ae38096b475:/ru-gpts$ ds_report
--------------------------------------------------
DeepSpeed C++/CUDA extension op report
--------------------------------------------------
NOTE: Ops not installed will be just-in-time (JIT) compiled at
      runtime if needed. Op compatibility means that your system
      meet the required dependencies to JIT install the op.
--------------------------------------------------
JIT compiled ops requires ninja
ninja .................. [OKAY]
--------------------------------------------------
op name ................ installed .. compatible
--------------------------------------------------
cpu_adam ............... [YES] ...... [OKAY]
fused_adam ............. [NO] ....... [OKAY]
fused_lamb ............. [NO] ....... [OKAY]
sparse_attn ............ [YES] ...... [OKAY]
transformer ............ [NO] ....... [OKAY]
stochastic_transformer . [NO] ....... [OKAY]
utils .................. [NO] ....... [OKAY]
--------------------------------------------------
DeepSpeed general environment info:
torch install path ............... ['/home/user/miniconda/lib/python3.8/site-packages/torch']
torch version .................... 1.5.0
torch cuda version ............... 10.2
nvcc version ..................... 10.2
deepspeed install path ........... ['/home/user/miniconda/lib/python3.8/site-packages/deepspeed']
deepspeed info ................... 0.3.7, unknown, unknown
deepspeed wheel compiled w. ...... torch 1.5, cuda 10.2

Ubuntu 18.02 in docker

king-menin commented 3 years ago

For xl model run your code from gw directory is source code directory. Or try to use new code. We had just update our code.