LlamaTokenizer Legacy Behavior and Device Map Error in Transformers
The error message indicates that you are using the legacy behavior of the 'LlamaTokenizer' class from the Transformers library. This behavior does not properly handle tokens that come after special tokens. To resolve this issue, it is recommended to read the related pull request at the provided GitHub link (https://github.com/huggingface/transformers/pull/24565) for more information on how to update your code to the latest behavior.
Additionally, the error also mentions a problem with the 'device_map' and weights being offloaded to the disk. To fix this, you need to provide an 'offload_folder' for the weights or ensure that you have the 'safetensors' library installed if the model you are using offers the weights in that format.
原文地址: https://www.cveoy.top/t/topic/qhLt 著作权归作者所有。请勿转载和采集!