Skip to content

added cosine matching loss#2482

Open
ankitpatnala wants to merge 2 commits into
ecmwf:developfrom
ankitpatnala:ankit_develop_cosine_loss
Open

added cosine matching loss#2482
ankitpatnala wants to merge 2 commits into
ecmwf:developfrom
ankitpatnala:ankit_develop_cosine_loss

Conversation

@ankitpatnala

Copy link
Copy Markdown
Contributor

Description

Added cosine matching loss which is used for constraining cosine similarity between consecutive forecasting latents

Issue Number

Link the Issue number this change addresses:
Closes #2481

@ankitpatnala

Copy link
Copy Markdown
Contributor Author

@SavvasMel

@github-actions github-actions Bot added eval anything related to the model evaluation pipeline model Related to model training or definition (not generic infra) labels Jun 10, 2026
@SavvasMel SavvasMel mentioned this pull request Jun 11, 2026
7 tasks

@clessig clessig left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for the implementation. Can we generalise the PR slightly to have a LossLatent (I think it's a regularisation term since it does not involve targets but this is a minor point), with the cosine being a specific implementation (RMSE or other losses are possible as well). We will also need to best structure the part in the model but let's first to this restructuring.

@MatKbauer : (I don't think so since this uses that target_aux_calculator but double-checking)

@sophie-xhonneux : for me this is more a regularisation term since no target are involved. Any opinion on this?

@github-project-automation github-project-automation Bot moved this to In Progress in WeatherGen-dev Jun 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

eval anything related to the model evaluation pipeline model Related to model training or definition (not generic infra)

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

Task: Introduce cosine matching loss

2 participants