- 错误信息及log
G:\JittorLLMs>python api.py chatglm
[i 0723 21:14:57.702000 64 compiler.py:956] Jittor(1.3.8.5) src: d:\veighna_studio\lib\site-packages\jittor
[i 0723 21:14:57.764000 64 compiler.py:957] cl at C:\Users\Administrator.cache\jittor\msvc\VC_____\bin\cl.exe(19.29.30133)
[i 0723 21:14:57.765000 64 compiler.py:958] cache_path: C:\Users\Administrator.cache\jittor\jt1.3.8\cl\py3.10.9\Windows-10-10.x9e\12thGenIntelRCx68\default
[i 0723 21:14:57.769000 64 install_cuda.py:93] cuda_driver_version: [11, 8, 0]
[i 0723 21:14:57.828000 64 __init__.py:411] Found C:\Users\Administrator.cache\jittor\jtcuda\cuda11.2_cudnn8_win\bin\nvcc.exe(11.2.67) at C:\Users\Administrator.cache\jittor\jtcuda\cuda11.2_cudnn8_win\bin\nvcc.exe.
[i 0723 21:14:57.952000 64 compiler.py:1011] cuda key:cu11.2.67
[i 0723 21:14:57.955000 64 __init__.py:227] Total mem: 15.85GB, using 5 procs for compiling.
[i 0723 21:02:50.170000 32 jit_compiler.cc:28] Load cc_path: C:\Users\Administrator.cache\jittor\msvc\VC_____\bin\cl.exe
[i 0723 21:02:50.187000 32 init.cc:62] Found cuda archs: [75,]
D:\veighna_studio\lib\site-packages\numpy_distributor_init.py:30: UserWarning: loaded more than 1 DLL from .libs:
D:\veighna_studio\lib\site-packages\numpy.libs\libopenblas.FB5AE2TYXYH2IJRDKGDGQ3XBKLKTF43H.gfortran-win_amd64.dll
D:\veighna_studio\lib\site-packages\numpy.libs\libopenblas64__v0.3.23-gcc_10_3_0.dll
Explicitly passing arevision
is encouraged when loading a model with custom code to ensure no malicious code has been contributed in a newer revision.
Explicitly passing arevision
is encouraged when loading a configuration with custom code to ensure no malicious code has been contributed in a newer revision.
Explicitly passing arevision
is encouraged when loading a model with custom code to ensure no malicious code has been contributed in a newer revision.
Loading checkpoint shards: 38%|█████████████████████▍ | 3/8 [00:16<00:26, 5.35s/it]
Traceback (most recent call last):
File “G:\JittorLLMs\api.py”, line 47, in
model = models.get_model(args)
File “G:\JittorLLMs\models_init_.py”, line 46, in get_model
return module.get_model(args)
File “G:\JittorLLMs\models\chatglm_init_.py”, line 48, in get_model
return ChatGLMMdoel(args)
File “G:\JittorLLMs\models\chatglm_init_.py”, line 22, in init
self.model = AutoModel.from_pretrained(os.path.dirname(file), trust_remote_code=True)
File “D:\veighna_studio\lib\site-packages\transformers\models\auto\auto_factory.py”, line 459, in from_pretrained
return model_class.from_pretrained(
File “D:\veighna_studio\lib\site-packages\transformers\modeling_utils.py”, line 2478, in from_pretrained
) = cls._load_pretrained_model(
File “D:\veighna_studio\lib\site-packages\transformers\modeling_utils.py”, line 2812, in _load_pretrained_model
error_msgs += load_state_dict_into_model(model_to_load, state_dict, start_prefix)
File “D:\veighna_studio\lib\site-packages\transformers\modeling_utils.py”, line 491, in load_state_dict_into_model
load(model_to_load, state_dict, prefix=start_prefix)
File “D:\veighna_studio\lib\site-packages\transformers\modeling_utils.py”, line 485, in load
module.load_from_state_dict(*args)
File "D:\veighna_studio\lib\site-packages\jittor_init.py", line 1348, in load_from_state_dict
self.load_state_dict(state)
File "D:\veighna_studio\lib\site-packages\jtorch_init.py", line 120, in load_state_dict
return super().load_state_dict(state_dict)
File "D:\veighna_studio\lib\site-packages\jittor_init.py", line 1339, in load_state_dict
self.load_parameters(params)
File "D:\veighna_studio\lib\site-packages\jittor_init.py", line 1604, in load_parameters
v.sync(False, False)
RuntimeError: [f 0723 21:15:18.486000 64 executor.cc:686]
Execute fused operator(3/5) failed.
[JIT Source]: C:\Users\Administrator.cache\jittor\jt1.3.8\cl\py3.10.9\Windows-10-10.x9e\12thGenIntelRCx68\default\cu11.2.67\jit__opkey0_reindex__Tx_float16__XDIM_1__YDIM_2__OVERFLOW_itof_0x0___INDEX0__e0_0____i0__e0_1___hash_31ae4cff793af536_op.cc
[OP TYPE]: fused_op:( reindex,)
[Input]: float16[16777216,], int32[2,],
[Output]: float16[4096,4096,],
[Async Backtrace]: not found, please set env JT_SYNC=1, trace_py_var=3
[Reason]: [f 0723 21:15:18.485000 64 helper_cuda.h:128] CUDA error at d:\veighna_studio\lib\site-packages\jittor\src\mem\allocator\cuda_host_allocator.cc:22 code=2( cudaErrorMemoryAllocation ) cudaMallocHost(&ptr, size)
Async error was detected. To locate the async backtrace and get better error report, please rerun your code with two enviroment variables set:
cmd:
set JT_SYNC=1
set trace_py_var=3
powershell:
$env:JT_SYNC=1
$env:trace_py_var=3
- 描述、
安装完jittor ,下载好chatglm模型,运行python api.py chatglm报以上错误,哪位大佬碰到此问题没,请指教,怎么解决
- 其他必要信息
个人电脑内存16Gb, 显卡内存4g, nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2022 NVIDIA Corporation
Built on Wed_Sep_21_10:41:10_Pacific_Daylight_Time_2022
Cuda compilation tools, release 11.8, V11.8.89
Build cuda_11.8.r11.8/compiler.31833905_0