`Dream-v0-Base-7B` and `Dream-v0-Instruct-7B` Have Identical Weights
Hi team,
Thank you for sharing and maintaining the excellent Dream models. While checking the two checkpoints on huggingface Dream-org/Dream-v0-Base-7B and Dream-org/Dream-v0-Instruct-7B, I found that their weights appear to be identical.
Reproduction
import torch
from transformers import AutoModel
path_base = "Dream-org/Dream-v0-Base-7B"
path_instruct = "Dream-org/Dream-v0-Instruct-7B"
model_base = AutoModel.from_pretrained(path_base, torch_dtype=torch.bfloat16, trust_remote_code=True)
model_instruct = AutoModel.from_pretrained(path_instruct, torch_dtype=torch.bfloat16, trust_remote_code=True)
diffs = []
for (n1, p1), (n2, p2) in zip(model_base.state_dict().items(), model_instruct.state_dict().items()):
if not torch.allclose(p1, p2, atol=1e-6, rtol=1e-5):
diffs.append(n1)
print(f"Differing parameters: {len(diffs)}") # prints 0
All parameters appear to be identical, with no numerical differences detected across any layer. Could you please confirm whether this is the intended behavior or if it might be an upload issue?
Thank you again for your great work and contribution to the community.
Interesting, I got 339 after running the exact same code multiple times. Not sure if it's related to GPUs, I am using H800.
That's pretty strange. I will try to use another device to rerun this code, I previously used the A100 80G.
I think the problem lies in my machine, I changed to another machine and the problem was solved. Thanks for your help!