Skip to content

Initial InfoNCE contrastive experiments (with pos emb bugfix)#77

Merged
sjmielke merged 5 commits intomainfrom
ume-contrastive
May 14, 2025
Merged

Initial InfoNCE contrastive experiments (with pos emb bugfix)#77
sjmielke merged 5 commits intomainfrom
ume-contrastive

Conversation

@sjmielke
Copy link
Collaborator

No description provided.

if attention_mask is None:
attention_mask = torch.ones_like(input_ids)
if position_ids is None and cu_seqlens is not None:
# Generate position ids fresh for every sequence by using cu_seqlens
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a comment describing that otherwise, embeddings depend on the batch composition

Copy link
Collaborator

@karinazad karinazad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@sjmielke sjmielke temporarily deployed to test.pypi.org May 14, 2025 19:06 — with GitHub Actions Inactive
@sjmielke sjmielke temporarily deployed to test.pypi.org May 14, 2025 19:08 — with GitHub Actions Inactive
@sjmielke sjmielke temporarily deployed to test.pypi.org May 14, 2025 19:14 — with GitHub Actions Inactive
@sjmielke sjmielke merged commit 0ef1edd into main May 14, 2025
5 checks passed
@sjmielke sjmielke deleted the ume-contrastive branch May 14, 2025 19:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants