robinfaro commited on
Commit
0e3ea4b
·
verified ·
1 Parent(s): fecfd8c

Upload modeling.py

Browse files
Files changed (1) hide show
  1. modeling.py +1 -1
modeling.py CHANGED
@@ -418,7 +418,7 @@ class MoEGPTForCausalLM(PreTrainedModel):
418
  else idx[:, -self.config.sequence_length :]
419
  )
420
  # forward the model to get the logits for the index in the sequence
421
- logits = self(idx_cond, date, get_logits=True)["logits"]
422
  # pluck the logits at the final step and scale by desired temperature
423
  logits = logits[:, -1, :] / temperature
424
  # optionally crop the logits to only the top k options
 
418
  else idx[:, -self.config.sequence_length :]
419
  )
420
  # forward the model to get the logits for the index in the sequence
421
+ logits = self(idx_cond, date, get_logits=True).logits
422
  # pluck the logits at the final step and scale by desired temperature
423
  logits = logits[:, -1, :] / temperature
424
  # optionally crop the logits to only the top k options