Wonder-Griffin commited on
Commit
a895ef9
1 Parent(s): 4c81121

Upload JudgeXL

Browse files
Files changed (2) hide show
  1. judge_xl_model.py +4 -3
  2. model.safetensors +1 -1
judge_xl_model.py CHANGED
@@ -28,9 +28,10 @@ class JudgeXLConfig(PretrainedConfig):
28
  class CustomEmbedding(nn.Module):
29
  def __init__(self, vocab_size, hidden_size):
30
  super(CustomEmbedding, self).__init__()
31
- assert isinstance(vocab_size, int) and isinstance(hidden_size, int)
32
- self.embedding = nn.Embedding(config.vocab_size, config.hidden_size)
33
- print(f"vocab_size: {config.vocab_size}, hidden_size: {config.hidden_size}")
 
34
 
35
  def forward(self, inputs):
36
  return self.embedding(inputs)
 
28
  class CustomEmbedding(nn.Module):
29
  def __init__(self, vocab_size, hidden_size):
30
  super(CustomEmbedding, self).__init__()
31
+ print(f"vocab_size: {vocab_size}, hidden_size: {hidden_size}") # Debugging print
32
+ assert isinstance(vocab_size, int) and isinstance(hidden_size, int), \
33
+ f"Expected integers, but got vocab_size={type(vocab_size)} and hidden_size={type(hidden_size)}"
34
+ self.embedding = nn.Embedding(vocab_size, hidden_size)
35
 
36
  def forward(self, inputs):
37
  return self.embedding(inputs)
model.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:7748f30578453658d57e62715496ea224ec2f5ed4d7a3c3134b509ecc9b895f4
3
  size 1053691936
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ba84e4ba48b14738177199bd52fcc4e25b376f8ce7aa5f91d9d7a304bf3d9b78
3
  size 1053691936