👑 Easy-to-use and powerful NLP and LLM library with 🤗 Awesome model zoo, supporting wide-range of NLP tasks from research to industrial applications, including 🗂Text Classification, 🔍 Neural Search, ❓ Question Answering, ℹ️ Information Extraction, 📄 Document Intelligence, 💌 Sentiment Analysis etc.
报错信息如下:
Traceback (most recent call last): File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/utils/lazy_import.py", line 32, in try_import mod = importlib.import_module(module_name) File "/root/anaconda3/envs/paddle/lib/python3.8/importlib/__init__.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 1014, in _gcd_import File "<frozen importlib._bootstrap>", line 991, in _find_and_load File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlocked ModuleNotFoundError: No module named 'fused_ln'
追踪如下
Traceback (most recent call last): File "run_pretrain.py", line 630, in <module> main() File "run_pretrain.py", line 608, in main train_result = trainer.train(resume_from_checkpoint=checkpoint) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 768, in train return self._inner_training_loop( File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 962, in _inner_training_loop tr_loss_step = self.training_step(model, inputs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 2006, in training_step loss = self.compute_loss(model, inputs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 1950, in compute_loss outputs = model(**inputs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/distributed/fleet/meta_parallel/meta_parallel_base.py", line 37, in forward output = self._layers(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 1820, in forward outputs = self.llama( File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 1582, in forward layer_outputs = decoder_layer( File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 1134, in forward hidden_states = self.input_layernorm(hidden_states) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 413, in forward return rms_norm_fused(hidden_states, self.weight, self.variance_epsilon) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 390, in rms_norm_fused fused_ln = try_import("fused_ln") File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/utils/lazy_import.py", line 41, in try_import raise ImportError(err_msg) ImportError: Failed importing fused_ln. This likely means that some paddle modules require additional dependencies that have to be manually installed (usually withpip install fused_ln).
请提出你的问题
参考了https://paddlenlp.readthedocs.io/zh/latest/llm/pretraining/index.html的教程,执行命令:
python -u -m paddle.distributed.launch --gpus "0,1,2,3,4,5,6,7" run_pretrain.py ./llama/pretrain-llama2_7b-tp2sd4_stage2.json
但产生了下属报错,提示一个叫做fused_ln的东西找不到报错信息如下:
Traceback (most recent call last): File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/utils/lazy_import.py", line 32, in try_import mod = importlib.import_module(module_name) File "/root/anaconda3/envs/paddle/lib/python3.8/importlib/__init__.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 1014, in _gcd_import File "<frozen importlib._bootstrap>", line 991, in _find_and_load File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlocked ModuleNotFoundError: No module named 'fused_ln'
追踪如下
Traceback (most recent call last): File "run_pretrain.py", line 630, in <module> main() File "run_pretrain.py", line 608, in main train_result = trainer.train(resume_from_checkpoint=checkpoint) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 768, in train return self._inner_training_loop( File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 962, in _inner_training_loop tr_loss_step = self.training_step(model, inputs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 2006, in training_step loss = self.compute_loss(model, inputs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/trainer/trainer.py", line 1950, in compute_loss outputs = model(**inputs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/distributed/fleet/meta_parallel/meta_parallel_base.py", line 37, in forward output = self._layers(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 1820, in forward outputs = self.llama( File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 1582, in forward layer_outputs = decoder_layer( File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 1134, in forward hidden_states = self.input_layernorm(hidden_states) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/nn/layer/layers.py", line 1429, in __call__ return self.forward(*inputs, **kwargs) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 413, in forward return rms_norm_fused(hidden_states, self.weight, self.variance_epsilon) File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddlenlp/transformers/llama/modeling.py", line 390, in rms_norm_fused fused_ln = try_import("fused_ln") File "/root/anaconda3/envs/paddle/lib/python3.8/site-packages/paddle/utils/lazy_import.py", line 41, in try_import raise ImportError(err_msg) ImportError: Failed importing fused_ln. This likely means that some paddle modules require additional dependencies that have to be manually installed (usually with
pip install fused_ln).
并且pip安装不上这个东西,看起来是paddle的内部文件?