You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
File "/opendelta/utils/model_md5.py", line 26, in gen_parameter_hash
md5.update(x.cpu().numpy().data.tobytes())
TypeError: Got unsupported ScalarType BFloat16
I fixed it locally importing torch and modifying the line to md5.update(x.cpu().to(torch.float32).numpy().data.tobytes()), but there may be other users running into this same issue
The text was updated successfully, but these errors were encountered:
When training MiniCPM (https://huggingface.co/openbmb/MiniCPM-2B-sft-bf16/) using OpenDelta, I ran into a type conversion error when saving the model delta_model.save_finetuned("./delta_model"):
File "/opendelta/utils/model_md5.py", line 26, in gen_parameter_hash
md5.update(x.cpu().numpy().data.tobytes())
TypeError: Got unsupported ScalarType BFloat16
I fixed it locally importing torch and modifying the line to md5.update(x.cpu().to(torch.float32).numpy().data.tobytes()), but there may be other users running into this same issue
The text was updated successfully, but these errors were encountered: