Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
jakep-allenai committed Jan 23, 2025
2 parents eacd044 + 01469af commit aa59d38
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pdelfin/train/loaddataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@ def main():

print("Training dataset........")
print(train_dataset)
print(train_dataset[0])

train_example = train_dataset[0]
print(train_example)
print({(x, y.shape) for x,y in train_example.items()})
print("\nTokens")
print(processor.tokenizer.batch_decode(train_example["input_ids"]))

print("\n\n")

print("Validation dataset........")
Expand Down
1 change: 1 addition & 0 deletions tests/test_molmo.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ def test_molmo_demo(self):
print(inputs)

print("\nShapes")
# {('input_ids', torch.Size([1, 589])), ('images', torch.Size([1, 5, 576, 588])), ('image_masks', torch.Size([1, 5, 576])), ('image_input_idx', torch.Size([1, 5, 144]))}
print({(x, y.shape) for x,y in inputs.items()})

print("\nTokens")
Expand Down

0 comments on commit aa59d38

Please sign in to comment.